intervalFind.h File Reference

Go to the source code of this file.

Data Structures

struct  Interval
 Interval. More...
struct  SubInterval
 SubInterval. More...

Functions

void intervalFind_addIntervalsToSearchSpace (char *fileName, int source)
 Add intervals to the search space.
Array intervalFind_getAllIntervals (void)
 Retrieve all the intervals that have been added to the search space.
int intervalFind_getNumberOfIntervals (void)
 Get the total number of intervals that have been added to the search space.
Array intervalFind_getOverlappingIntervals (char *chromosome, int start, int end)
 Get the intervals that overlap with the query interval.


Detailed Description

Author:
Lukas Habegger (lukas.habegger@yale.edu)

Definition in file intervalFind.h.


Function Documentation

void intervalFind_addIntervalsToSearchSpace ( char *  fileName,
int  source 
)

Add intervals to the search space.

Parameters:
[in] fileName File name of the file that contains the interval and subintervals to search against. This tab-delimited file must have the following format:
   Column:   Description:
   1         Name of the interval
   2         Chromosome 
   3         Strand
   4         Interval start
   5         Interval end
   6         Number of subintervals
   7         Subinterval starts (comma-delimited)
   8         Subinterval end (comma-delimited)
   

This is an example:

   uc001aaw.1      chr1    +       357521  358460  1       357521  358460
   uc001aax.1      chr1    +       410068  411702  3       410068,410854,411258    410159,411121,411702
   uc001aay.1      chr1    -       552622  554252  3       552622,553203,554161    553066,553466,554252
   uc001aaz.1      chr1    +       556324  557910  1       556324  557910
   uc001aba.1      chr1    +       558011  558705  1       558011  558705
   
Note in this example the intervals represent a transcripts, while the subintervals denote exons.

Parameters:
[in] source An integer that specifies the source. This is useful when multiple files are used.

Definition at line 107 of file intervalFind.c.

Array intervalFind_getAllIntervals ( void   ) 

Retrieve all the intervals that have been added to the search space.

Returns:
An Array of type Interval.
Note:
This function generates a copy of the intervals Array. The user can modify the returned Array.
Precondition:
Intervals were added to the search space using intervalFind_addIntervalsToSearchSpace().

Definition at line 54 of file intervalFind.c.

int intervalFind_getNumberOfIntervals ( void   ) 

Get the total number of intervals that have been added to the search space.

Returns:
The total number of intervals in the search space.
Precondition:
Intervals were added to the search space using intervalFind_addIntervalsToSearchSpace()

Definition at line 40 of file intervalFind.c.

Array intervalFind_getOverlappingIntervals ( char *  chromosome,
int  start,
int  end 
)

Get the intervals that overlap with the query interval.

Parameters:
[in] chromosome Chromosome of the query interval
[in] start Start of the query interval
[in] end End of the query interval
Returns:
An Array of Interval pointers. If no overlapping intervals are found, then an empty Array is returned
Precondition:
Intervals were added to the search space, see intervalFind_addIntervalsToSearchSpace()

Definition at line 252 of file intervalFind.c.


Generated on Fri Aug 7 15:46:43 2009 for BIOS by  doxygen 1.5.7.1