Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BbiHeader ¶
type BbiHeader struct { Magic uint32 // magic bytes at the beginning of file. Must match constant above to be a valid bigWig. Version uint16 // Specifies the wig version. This package was built following specs for bigWig version 4. ZoomLevels uint16 // Number of zoom levels built into the file. ChromosomeTreeOffset uint64 // Offset in file to chromosome B+ tree index. FullDataOffset uint64 // Offset to the main dta. Points to the dataCount. FullIndexOffset uint64 // Offset to R tree index of items. FieldCount uint16 // Number of fields in a BED file. For bigWig, this should always be zero. DefinedFieldCount uint16 // Number of fields that are predefined BED files. this should also be zero for bigWig files. AutoSqlOffset uint64 // From specs: Offset to zero-terminated string with .as spec. Used for bigBed, not used in bigWig. TotalSummaryOffset uint64 // Offset to overall file summary data block. UncompressBufferSize uint32 // Maximum size of decompression buffer needed (nonzero on compressed files). ExtensionOffset uint64 // Offset to header extension 0 if no such extension. }
BbiHeader represents the bbi header of the bigWig data file and contains metadata and offset values for file navigation.
type BigWig ¶
type BigWig struct { BbiHeader BbiHeader // Contains high-level information about file and offsets to various parts of the file. ZoomHeaders []ZoomHeader // One for each zoom level built into the file, as specified in the BbiHeader. TotalSummaryBlock TotalSummaryBlock // Statistical summary of the entire file. }
BigWig represents the data of a BigWig file in a data structure.
type TotalSummaryBlock ¶
type TotalSummaryBlock struct { BasesCovered uint64 // Number of bases for which there is data. MinVal float64 // Minimum value in the file. MaxVal float64 // Maximum value in the file. SumData float64 // Sum of all values in the file. SumSquares float64 // Sum of all squares of values in the file. }
TotalSummaryBlock provides an overall statistical summary of the file contents. Mean and standard deviation values can be quickly calculated from these values.
type ZoomHeader ¶
type ZoomHeader struct { ReductionLevel uint32 // Number of bases summarized in each reduction level. Reserved uint32 // Reserved for future expansion. 0 in bigWig. DataOffset uint64 // Position of zoomed data in file. IndexOffset uint64 // Position of zoomed data index in file. }
ZoomHeader immediately follows the BbiHeader in the file, one for each of the ZoomLevels, as specified in the BbiHeader.
Click to show internal directories.
Click to hide internal directories.