VcfAdapter
Auto-generated config schema for the current JBrowse release — see the
config guide for concepts. Provided by the variants
plugin.
View source.
Example usage
{
type: 'VariantTrack',
trackId: 'my_track',
name: 'My track',
assemblyNames: ['hg38'],
adapter: {
type: 'VcfAdapter',
uri: 'https://example.com/variants.vcf',
},
}
variants.vcf infers VcfAdapter and VariantTrack on its own, and name
defaults to the file name. In a config declaring one assembly, assemblyNames
comes from there too — see
the shortest track.
{
trackId: 'my_track',
uri: 'https://example.com/variants.vcf',
assemblyNames: ['hg38'],
}
See the Config slots section below for all available configuration fields.
used to load plain-text (non-bgzipped) VCF files. Loads the whole file into memory, so prefer the VcfTabixAdapter for large files.
Related links
- Track: VariantTrack
- Display: ChordVariantDisplay
- Display: LDDisplay
- Display: LinearMultiSampleVariantDisplay
- Display: LinearMultiSampleVariantMatrixDisplay
- Display: LinearPairedArcDisplay
- Display: LinearVariantDisplay
- Guide: Structural variants (Cancer GIAB)
- Guide: Supported file types
Config slots
These slots go inside the track's adapter:
"adapter": { "type": "VcfAdapter", ... }. It also accepts the
shorthand keys uri,
baseUri in place of writing a location slot out. Slot types (fileLocation,
frozen, ...) are explained in the
config slot types reference. Slots a base
configuration contributes are listed here too, so this table is the whole
surface.
| Slot | Description |
|---|---|
vcfLocationfileLocation = { uri: '/path/to/my.vcf', locationType: 'UriLocation' } | location of the VCF file. May be gzipped; it is read and parsed in full on first use, so the whole call set has to fit in memory. |
samplesTsvLocationfileLocation = { uri: '/path/to/samples.tsv', locationType: 'UriLocation' } | location of a tab-separated table of per-sample metadata. It needs a header row, and its first column must be the sample name exactly as the VCF spells it; every other column (population, superpopulation, ...) becomes a value the multi-sample variant displays can group, sort and color their sample rows by. |