GMOD / jbrowse

JBrowse 1, a full-featured genome browser built with JavaScript and HTML5. For JBrowse 2, see https://github.com/GMOD/jbrowse-components.
http://jbrowse.org
Other
464 stars 199 forks source link

Score value in Primary Data #364

Closed hkmoon closed 11 years ago

hkmoon commented 11 years ago

Hi,

Is there a way to show score in primary data? I have match data with e-value in the column of score in GFF3 format. Currently, biodb-to-json.pl and json are used for importing gff3 file.

For example, be_v1 e-value BlastHit 259 1233 3e-128 - . ID=be_S_v1;Parent=be_v1;Name=NP_001157823.1;Target=NP_001157823.1 1 324;Species=;Note="factor 3, subunit I"

How can I show the score in "Primary data" section? Currently, I treat this data as "FeatureTrack" type and "Transcript" class for the display.

Regards, HongKee

rbuels commented 11 years ago

You could either:

a. Put the e-value in the score column of the gff3 you're loading, in which case it would show up as Score under primary data

b. Make the dialog be a custom popup that shows anything you want, by implementing a custom left-click behavior for that track in the trackList.json. An example of that can be seen at https://github.com/GMOD/jbrowse/blob/16c50d5de1a4a31f1e7a97c862bf84476ed6461d/docs/tutorial/conf_files/volvox.json#L93

Does this work for you? Just reopen the issue to continue the conversation if not.

hkmoon commented 11 years ago

Hi, Thank you for the reply. Still, I'm not able to see stored score value inside trackData.json. Probably, does bin/biodb-to-json.pl check the "type" column if it needs score value or not, during importing process? In my gff3 file, I named "BlastHit" in the "type" column.

Do you have any clue?

rbuels commented 11 years ago

It's definitely not related to the type column.

Have you tried clearing your browser's cache when reloading? Your browser could be caching on old version of the feature data.

hkmoon commented 11 years ago

Hi,

gff3 data looks like: ox_Smed_v1_00001 e-value BlastHit 211 528 9e-19 + . ID=ox_Smed_v1_00001bmatch001;Parent=ox_Smed_v1_00001;Name=XP_004069140.1;Target=XP_004069140.1 51 155;Species=Japanese medaka;Note="bcl-2-like protein 1-like" ox_Smed_v1_00001 e-value BlastHit 172 528 3e-16 + . ID=ox_Smed_v1_00001bmatch002;Parent=ox_Smed_v1_00001;Name=XP_003457009.1;Target=XP_003457009.1 68 185;Species=Oreochromis niloticus (Linnaeus, 1758);Note="bcl-2-like protein 1-like" ox_Smed_v1_00001 e-value BlastHit 139 528 2e-15 + . ID=ox_Smed_v1_00001bmatch003;Parent=ox_Smed_v1_00001;Name=NP_571882.1;Target=NP_571882.1 63 191;Species=Danio rerio (Hamilton, 1822);Note="bcl2-like 1"

trackData.json looks like: "histograms":{"stats":[{"basesPerBin":"500","max":3,"mean":3}],"meta":[{"basesPerBin":"500","arrayParams":{"length":2,"chunkSize":10000,"urlTemplate":"hist-500-{Chunk}.json"}}]},"featureCount":3,"intervals":{"nclist":[[1,138,528,1,"e-value"," 1822)","ox_Smed_v1_00001","ox_Smed_v1_00001bmatch003","NP_571882.1","Danio rerio (Hamilton","\"bcl2-like 1\"\r","ox_Smed_v1_00001","NP_571882.1 63 191","BlastHit"],[1,171,528,1,"e-value"," 1758)","ox_Smed_v1_00001","ox_Smed_v1_00001bmatch002","XP_003457009.1","Oreochromis niloticus (Linnaeus","\"bcl-2-like protein 1-like\"\r","ox_Smed_v1_00001","XP_003457009.1 68 185","BlastHit"],[0,210,528,1,"e-value","ox_Smed_v1_00001","ox_Smed_v1_00001bmatch001","XP_004069140.1","Japanese medaka","\"bcl-2-like protein 1-like\"\r","ox_Smed_v1_00001","XP_004069140.1 51 155","BlastHit"]],"classes":[{"isArrayAttr":{},"attributes":["Start","End","Strand","Source","Seq_id","Load_id","Name","Species","Note","Parent_id","Target","Type"]},{"isArrayAttr":{},"attributes":["Start","End","Strand","Source","Species2","Seq_id","Load_id","Name","Species","Note","Parent_id","Target","Type"]},{"isArrayAttr":{"Sublist":1},"attributes":["Start","End","Chunk"]}],"maxEnd":528,"count":3,"lazyClass":2,"urlTemplate":"lf-{Chunk}.json","minStart":138},"formatVersion":1}

I couldn't see any score here.

Thank you so much!

rbuels commented 11 years ago

Hmm, I think there is a bug somewhere in here. I'll look into it.

rbuels commented 11 years ago

Fixed in git, the fix will come out in 1.10.7. Thanks for reporting it!

hkmoon commented 11 years ago

Thanks a lot, Robert!