Tracks as an id and a uri
The extension picks the track type and the adapter.
Supported file types
lists what each extension resolves to. Beside uri, the shorthand takes index
for an index at another URL, or csi: true for a .csi beside the file. Spell
type and adapter out when the file name does not decide the format.
Show source · 28 linesHide source · 28 lines
import { LinearGenomeView } from '@jbrowse/react-linear-genome-view2'
const base = 'https://jbrowse.org/code/jb2/main/test_data/volvox'
export default function TrackShorthand() {
return (
<LinearGenomeView
assembly={{
name: 'volvox',
uri: 'https://jbrowse.org/genomes/volvox/volvox.2bit',
}}
tracks={[
{ trackId: 'genes', uri: `${base}/volvox.sort.gff3.gz` },
{ trackId: 'microarray', uri: `${base}/volvox_microarray.bw` },
{
trackId: 'breakends',
uri: `${base}/volvox.dup.vcf.gz`,
name: 'Breakends',
displayDefaults: { encoding: { color: { value: 'purple' } } },
},
]}
view={{
loc: 'ctgA:1..50,000',
tracks: ['genes', 'microarray', 'breakends'],
}}
/>
)
}