@groovy.util.logging.Log class CoverageGaps extends java.lang.Object
Discovers blocks of low coverage in a file output in BEDTools Coverage format, or alternatively MultiCov output.
Each low coverage block is output as a CoverageBlock object which has statistics about the coverage within the block. As CoverageBlock extends gngs.Region, you can easily turn this into a set of Regions to perform more calculations or statistics.
To use this class, create the object first by passing a file to compute coverage for, then call the calculate method to actually calculate the coverage blocks:
CoverageGaps gaps = new CoverageGaps("test.cov.gz") gaps.calculate() println("There are " + gaps.blocks.size() + " low coverage regions")
Type | Name and description |
---|---|
int |
BUFFER_SIZE_BYTES Use a large buffer for very efficient reading |
CoverageBlock |
block |
int |
blockCount |
java.util.List<CoverageBlock> |
blocks Discovered gaps (the results) are stored here for access after calling calculate |
java.lang.String |
coverageFilePath |
CoverageStats |
coveragePercentiles |
org.apache.commons.math3.stat.descriptive.SummaryStatistics |
coverageStats |
RegulatingActor<CoverageBlock> |
gapProcessor |
int |
lineCount |
int |
minRegionWidth Only include gaps that are at least this size |
int |
offset |
java.lang.String |
region |
Regions |
regions |
int |
threshold |
int |
totalBP |
Constructor and description |
---|
CoverageGaps
() |
CoverageGaps
(java.lang.String coverageFilePath) |
Type Params | Return Type | Name and description |
---|---|---|
|
java.lang.Object |
asType(java.lang.Class clazz) |
|
void |
calculate() |
|
void |
calculateFromBEDTools(java.io.Reader reader) |
|
void |
calculateFromMultiCov(java.io.Reader reader) |
|
void |
calculateMultiCov() |
|
void |
outputBlock(int endPos) |
|
void |
processLine(java.lang.String chr, int start, int pos, int cov, java.lang.String id) |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Use a large buffer for very efficient reading
Discovered gaps (the results) are stored here for access after calling calculate
Only include gaps that are at least this size
Groovy Documentation