LinearAlignmentsDisplay
Auto-generated from the config schema in the source. See the config guide for concepts. Provided by the alignments plugin. View source.
Draws the reads of an AlignmentsTrack as a stack of bands: the coverage
histogram with the sashimi arcs over it, the read connections, and the
pileup. Each band is one object, coverage, sashimi, readConnections
and pileup, holding whether it draws and its height; the settings every
band shares sit beside them: filter, one list of the read, junction and
connection tests, unit, facet, sort, encoding and legend.
Example usage
Minimal BAM track — no display override needed for defaults. See the alignments track guide for all adapter and display options:
{
type: 'AlignmentsTrack',
trackId: 'ngs_reads',
name: 'NGS reads',
assemblyNames: ['hg38'],
adapter: { type: 'BamAdapter', uri: 'https://example.com/sample.bam' },
}CRAM colored by CpG methylation (modBAM MM/ML tags). The displayDefaults
object shorthand applies settings without spelling out the display type or
displayId — equivalent to displays: [{ type: 'LinearAlignmentsDisplay', displayId: '...', pileup: ... }]. See
configuring displays:
{
type: 'AlignmentsTrack',
trackId: 'methylation',
name: 'Methylation',
assemblyNames: ['hg38'],
adapter: { type: 'CramAdapter', uri: 'https://example.com/sample.cram' },
displayDefaults: {
pileup: {
bases: {
show: true,
encoding: { color: 'modifications' },
unmodified: { show: true },
},
},
},
}Long reads — taller track, soft-clipping shown, split/chimeric reads connected by arcs, each segment colored by its strand against its molecule's:
{
type: 'AlignmentsTrack',
trackId: 'long_reads',
name: 'Long reads',
assemblyNames: ['hg38'],
adapter: { type: 'BamAdapter', uri: 'https://example.com/longreads.bam' },
displayDefaults: {
height: 400,
unit: 'chain',
encoding: { color: 'insertSizeAndOrientation' },
pileup: { softClips: { show: true } },
readConnections: { show: true },
},
}RNA-seq — sashimi arcs placed to avoid crossings, labelled with their read counts, dropping junctions under five reads, the non-canonical ones and the split-read joins:
{
type: 'AlignmentsTrack',
trackId: 'rnaseq',
name: 'RNA-seq',
assemblyNames: ['hg38'],
adapter: { type: 'BamAdapter', uri: 'https://example.com/rnaseq.bam' },
displayDefaults: {
coverage: { height: 80 },
sashimi: { placement: 'auto', labels: { show: true } },
filter: [
{ field: 'junction.reads', gte: 5 },
{ field: 'junction.canonical', equal: true },
{ field: 'junction.source', equal: 'gap' },
],
},
}Related links
- Adapter: BamAdapter
- Adapter: CramAdapter
- Adapter: HtsgetBamAdapter
- Adapter: SamAdapter
- State model: runtime API
- Base config: BaseLinearAlignmentsDisplay
- Tutorial: Display settings
- User guide: Alignments track
- Config guide: Alignments track
- Config guide: Tracks
- Developer guide: Custom track and display types
Color channels
| Setting | Page | scale.type |
Preset fields |
|---|---|---|---|
encoding.color |
AlignmentsColor | ordinal, linear, threshold | strand, mapq, firstOfPairStrand, insertSizeAndOrientation, mateRefName |
Config slots
Display slots go on a display entry: "displays": [{ "type": "LinearAlignmentsDisplay", ... }], or in the track's displayDefaults when this is its default display. 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 |
|---|---|
| pileup ReadsPileup |
The stacked reads, with the per-base layer drawn over them, whatever fills them: bases: { show: true, encoding: { color: "modifications" } }, "bisulfite", "baseQuality" or "base". |
| sashimi Sashimi |
The splice-junction arcs, drawn in the coverage band: show, height, placement and labels; the junction filter fields filter the junctions drawn. |
| normalInsertSize NormalInsertSize |
The insert sizes a proper pair counts as normal, from min to max bp: shorter is short, longer long, under insertSizeAndOrientation, on the reads, the connections and the hover alike. Unset, each region's band is sampled from its pairs. |
| Inherited from BaseLinearAlignmentsDisplay | 12 slots |
heightnumber = 250 |
Starting height in pixels for the bands together; heightMode decides what a pileup deeper than this does |
unitstringEnum (read, chain) = 'read' |
The unit one row draws: a read, or a chain, which is a read, its mate and its split segments rather than a UCSC chain file's alignment (the "View as pairs/link supplementary alignments" menu row) |
| filter FieldPredicate |
The alignments drawn, a list of FieldPredicate entries every one of which must hold. The flags, mapq and tags decide which reads count, so coverage, the sashimi junctions and the insert-size colors count only the reads they pass: flags.UNMAP and the other samtools flag names, mapq (MAPQ 255, none reported, passes a floor), and tags.HP and any other tag. name and the read categories pick which of those reads the pileup, the arcs, the consensus and an export draw, and leave coverage whole: spliced per alignment, and svSignal, alone and split over a read, its mate and its split segments together, each taking equal: true or false. The facet read fields pairOrientation, pairing, svKind, firstOfPairStrand (1 or -1), mateRefName and mateAssembly pick drawn reads too, each read by the section a facet by read files it under (svKind by its whole chain's), with equal or oneOf of their values, or valid: false for the reads with none; a read's strand is flags.REVERSE. A facet on a category gives its own coverage. junction.reads, junction.canonical (a split junction reads no motif and counts as canonical, so equal: false hides it), junction.class (splice for an N gap, or a split read's deletion, duplication or inversion) and junction.source (gap or split) test the sashimi junctions, and connection.interchrom, connection.offscreen and breakpoint.reads the connections the arcs, the read cloud and the connectors draw.A written list merges with the defaults by field: unmapped, QC-failed and duplicate reads out ( flags.UNMAP, flags.QCFAIL and flags.DUP equal: false), and junction.reads and breakpoint.reads at least 2. An entry replaces the defaults for the field it names, and an entry naming a field with no test, such as { field: "flags.DUP" }, only removes them. |
| facet SectionFacet |
In-track stacked grouping, one labelled section per value: a read dimension (strand, firstOfPairStrand, pairOrientation, pairing, split, spliced, svKind, mapq, mateRefName, mateAssembly), a tag (tags.HP), or any other field. { field: "tags.HP", sort: ["2", "1"] } stacks the listed values first. |
| sort AlignmentsSort |
The pileup's row order by one field: a whole-window order (position, length, spliced, split, svSignal) or a column sort at one base ({ field: "strand", pos, refName }). |
| encoding AlignmentsEncoding |
The channels the reads paint through: encoding.color, the read fill. |
| legend HiddenLegend |
The display's key: show, off by default. |
| coverage CoverageBand |
The coverage histogram band: show, height (default 45), encoding.y, its depth axis, and the interbase and alleles layers, each with a show and a filter; alleles.filter floors each allele segment's share of its position's depth, distinct from pileup.fadeLowFrequency. The read cloud's insert-size axis is a fixed log scale no setting reaches. |
| readConnections ReadConnections |
The connections between mates and split segments: show (default off), mark (link, the arcs, or rule, the read cloud), height, placement, encoding (strokeWidth) and ordinaryPairs; the connection and breakpoint filter fields filter the connections drawn. |
| tooltip ReadTooltip |
The read hover's first line, a ReadTooltip object: the field it reads off each read. A bare string is the field. |
heightModestringEnum (fixed, grow, fit) = 'fixed' |
Track-sizing strategy — how the track responds when there are more reads than fit (the menu sets fit from "Read height → Fit to track height" and grow from "Advanced → Track height → Grow the track"). fixed (the default) keeps pileup.mark.height and scrolls; grow expands the track to show every read at that height; fit squeezes reads so every uncollapsed section fills the display without scrolling |
growMaxHeightnumber = 800 |
Ceiling in pixels for the "Grow the track" sizing mode; a pileup deeper than this grows to the ceiling and scrolls the rest. Does not apply to the fixed or fit modes, and does not limit how much is laid out (see pileup.maxLayoutHeight) advanced |
| Inherited from BaseLinearDisplay | 2 slots |
fetchSizeLimitnumber = 1000000 |
bytes a region may fetch before the display asks first; an adapter that sets its own limit takes precedence over this advanced |
forceLoadboolean = false |
Declarative equivalent of the "Force load" button on the "too much data" banner: when true the display always renders, however large the region or dense the features. Off by default (the gate guards against huge downloads). Set it on a view with no user interaction, such as an embedded or notebook view or a screenshot, where the region is known and should draw without a click. advanced |
Retired keys
An older config may still write these. Each loads without an error, and jbrowse validate reports it as stale.
| Key | On load |
|---|---|
maxFeatureScreenDensity |
ignored |
maxDisplayedBpPerPx |
ignored |
mouseover |
moved into a current slot |
jexlFilters |
ignored |
colorBy |
moved into a current slot |
pileupDisplay |
moved into a current slot |
snpCoverageDisplay |
moved into a current slot |
defaultRendering |
ignored |
colorScheme |
ignored |
scaleType |
moved into a current slot |
autoscale |
moved into a current slot |
minScore |
moved into a current slot |
maxScore |
moved into a current slot |
numStdDev |
ignored |
inverted |
ignored |
multiTicks |
ignored |
jitter |
ignored |
lineWidth |
moved into a current slot |
featureHeight |
moved into a current slot |
maxHeight |
moved into a current slot |
hideSmallIndels |
ignored |
hideMismatches |
moved into a current slot |
mismatchAlpha |
moved into a current slot |
hideLargeIndels |
ignored |
minSubfeatureWidth |
ignored |
renderers |
moved into a current slot |