dasmoth / dalliance

Interactive web-based genome browser.
http://www.biodalliance.org/
BSD 2-Clause "Simplified" License
226 stars 68 forks source link

Threshold can't always be attached to tracks #33

Closed timjph closed 11 years ago

timjph commented 11 years ago

In test.html, tried to attach threshold commands to histogram bw track, but didn't work.

quantLeapThreshold: 40, forceReduction: -1,

No red line displayed

dasmoth commented 11 years ago

Which bigwig were you using?

timjph commented 11 years ago

I was trying to apply it to the spermMethylation.bw example

timjph commented 11 years ago

Also there is something wrong with the application of threashold in test.html to CpG Density. A red line is drawn, but ctrl-left|right-arrow doesn't seem to navigate with respect to peaks about the threashold. If you try to use ctrl-up|down-arrow the red line vanishes.

dasmoth commented 11 years ago

The following config works fine for me:

              ,{name:                 'BWG hist',
               bwgURI:               'http://www.biodalliance.org/datasets/spermMethylation.bw',
               style:     [{type: 'default',
                            style:  {glyph: 'HISTOGRAM', HEIGHT: 50, MIN: 0, MAX: 100}}],
               quantLeapThreshold: 80}

You can also define quantLeapThreshold on a GRADIENT tier, but you don't see a threshold line in that case (because no y-scale for the tier has been defined), and can't adjust the threshold (at least until we have a quantitative track config UI -- one day!). I don't know if this is a Good Thing or not.

CpG density is a DAS track, there's no change of implementing quantitative-leap without a DAS extension and some server-side work. Probably not a high priority! However, I'll disable rendering of the threshold line for tiers where underlying datasource doesn't support quantitative-leap. Should really have done this from the start, but it was waiting on the source-adapters cleanup.

dasmoth commented 11 years ago

Threshold is now only displayed when the FeatureSource defines quantFindNextFeature.