Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Share y-scale and show only one axis in overlaid tracks #399

Open
sehilyi opened this issue Jun 5, 2021 · 3 comments
Open

Share y-scale and show only one axis in overlaid tracks #399

sehilyi opened this issue Jun 5, 2021 · 3 comments
Labels
bug🐛 Something isn't working

Comments

@sehilyi
Copy link
Member

sehilyi commented Jun 5, 2021

image

This happens when multiple tracks w/ different data are overlaid. This is not handled properly. Currently, only the tracks with the same data share the y axis.

Spec with an issue:

{
  "title": "HBM395.NRTL.659 Bulk ATAC-seq Data Raw",
  "subtitle": "Narrow Peaks and Summits",
  "views": [
    {
     "layout": "linear",
     "width": 800,
     "height": 180,
     "alignment": "overlay", 
     "tracks": [
      {
       "data": {
        "url": "https://gist.githubusercontent.com/ngehlenborg/9af4c34c65c9b820edda366a7af8d04d/raw/f8017ea25d9a735bb998e438763f2f993df5bde8/NA_peaks.narrowPeak",
        "type": "csv",
        "separator": "\t",
        "headerNames": ["chr", "start", "end", "name", "score", "strand", "signalValue", "pValue", "qValue", "peak" ],
        "chromosomeField": "chr",
        "genomicFields": ["start", "end"]

      },
      "mark": "bar",
      "x": {"field": "start", "type": "genomic"},
      "xe": {"field": "end", "type": "genomic"},
      "color":{ "value": "darkblue"},
      "stroke":{ "value": "darkblue"},
      "strokeWidth": {"value": 0.5},
      "y": {"field": "score", "type": "quantitative"}
    },
    {
     "data": {
      "url": "https://gist.githubusercontent.com/ngehlenborg/9af4c34c65c9b820edda366a7af8d04d/raw/f8017ea25d9a735bb998e438763f2f993df5bde8/NA_summits.bed",
      "type": "csv",
      "separator": "\t",
      "headerNames": ["chr", "start", "end", "name", "score"],
      "chromosomeField": "chr",
      "genomicFields": ["start", "end"]

    },
    "mark": "bar",
    "x": {"field": "start", "type": "genomic"},
    "xe": {"field": "end", "type": "genomic"},
    "stroke":{ "value": "lightblue"},
    "color":{ "value": "lightblue"},
    "strokeWidth": {"value": 1},
    "y": {"field": "score", "type": "quantitative"}
  }  
]
   }
 ]
}
@sehilyi sehilyi added bug🐛 Something isn't working P5 labels Jun 7, 2021
@sehilyi
Copy link
Member Author

sehilyi commented Jun 7, 2021

To fix this issue, we need to fix #401 in advance

@sehilyi
Copy link
Member Author

sehilyi commented Jun 7, 2021

For now, let's show the second axis on the other side (#402):

Screen Shot 2021-06-07 at 12 32 37 PM

@mwittep
Copy link

mwittep commented Apr 11, 2024

Hi, is there any plan of including this feature? I would like to overlay two tracks visualizing bigwig files, and the users should be able to compare them using the absolute values at every position.

Just as an example of the problem I am having: The bars visualize a value of the BigWig file at every position for two different libraries (Normal = gray, enriched = orange). Since the max value per window is automatically adapted for each track, here it looks like the orange library has a higher value than the gray one. However, using the tooltip, one realizes this is not the case.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug🐛 Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants