Skip to content

BigBed scores: fetch vs fetch_intervals #29

Answered by nvictus
LeoWelter asked this question in Q&A
Discussion options

You must be logged in to vote

data now contains an array with the relative scores.

Not quite. Unlike bigwig/bedgraph which stores non-overlapping quantitative intervals along the genome, bigbed/bed can contain overlapping intervals with lots of attributes. Therefore, the flat signal obtained from .fetch() for a bigBed file corresponds to the interval coverage (number of intervals in the file overlapping a given base or bin), not the relative scores. This is also what bigBedSummary does.

If you want the scores and any other BED fields, you'll have to read out the actual interval records themselves:

In [1]: import bbi

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by nvictus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #15 on May 27, 2023 21:20.