Types Used in the Grammar¶
These types are used in the grammar but are not documented elsewhere.
AggregateOp¶
Type: "count" | "valid" | "sum" | "min" | "max" | "mean" | "q1" | "median" | "q3" | "variance"
Align¶
Type: "left" | "center" | "right"
ArrowConfig¶
buildIndex- Type: boolean
Whether the x channel should build an index for efficient subset rendering. If omitted, GenomeSpy enables indexing automatically for positional x encodings.
clip- Type: boolean |
"x"|"y"|"never"Controls whether the mark is clipped to the UnitView's rectangle. The values
"x"and"y"clip only in the corresponding screen-space direction. Inherited clipping from parent containers still applies unless"never"is used.Default value: the direction of zoomable positional scales
color- Type: string | ExprRef
Color of the mark. Affects either
fillorstroke, depending on thefilledproperty. cullByVisibleRange- Type: boolean |
"x"|"y"Hide point-like mark instances whose anchor falls outside the inherited visible range in the given screen-space direction.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is over the mark. Mark cursor takes precedence over enclosing view cursors.
Default value: browser default
direction- Type:
"forward"|"reverse"| ExprRefDirection of the arrowhead.
"forward"places the arrowhead at the secondary endpoint (x2,y2)."reverse"places it at the primary endpoint (x,y). For data-driven direction, use thedirectionencoding channel.Default value:
"forward" fill- Type: string | ExprRef
The fill color.
fillOpacity- Type: number | ExprRef
The fill opacity. Value between
0and1. filled- Type: boolean
Whether the
colorrepresents thefillcolor (true) or thestrokecolor (false). headAngle- Type: number | ExprRef
Angle in degrees between the arrow axis and an outer edge of the arrowhead. Smaller values produce longer, narrower heads. Larger values produce shorter, blunter heads. Values are clamped to
[1, 90].Default value:
45 headNotchAngle- Type: number | ExprRef
Angle in degrees between the arrow axis and the arrowhead notch edge.
90places the notch point at the tip, producing a triangular head whenheadAngleis less than90. Applies to"triangle"heads."open"heads useheadAnglefor the notch edge as well. Values are clamped to[1, 90].Default value:
90 headPlacement- Type:
"inside"|"outside"| ExprRefPlacement of the arrowhead relative to the encoded segment.
"inside"keeps the whole arrowhead within the encoded segment."outside"places the arrowhead beyond the encoded segment so that the head starts at the segment endpoint.Default value:
"inside" headShape- Type:
"triangle"|"open"| ExprRefShape of the arrowhead.
"triangle"draws a filled head."open"draws an open head whose thickness matches the resolvedsize, even whenstemisfalse.Default value:
"triangle" headSpacing- Type: number | null | ExprRef
Spacing between repeated arrowheads as a multiplier of resolved
size. The effective spacing is at least the rendered arrowhead footprint, including stroke. Ifnull, arrowheads are not repeated.Default value:
null headWidth- Type: number | ExprRef
Width of the arrowhead as a multiplier of resolved
size. Values above1make the arrowhead wider than the stem.Default value:
3 minBufferSize- Type: number
Minimum size for WebGL buffers (number of data items). Allows for using
bufferSubData()to update graphics.This property is intended for internal use.
minSize- Type: number | ExprRef
Minimum resolved arrow stem thickness in pixels. Applies to numeric, band-relative, and encoded
sizevalues.Default value:
1 minStemLength- Type: number | ExprRef
Minimum visible length of the arrow stem in pixels. When a non-repeated arrow is too short for the configured shape and minimum stem length, the affected notch or head angle is made blunter toward 90 degrees. For
"inside"placement, this applies to"triangle"heads and is measured from the start of the stem to where the stem meets the head notch edge. For"outside"placement, this applies whenstartNotchistrueand is measured from the start notch to the head start. Has no effect whenstemisfalse.Default value:
0 opacity- Type: number | ExprRef
Opacity of the mark. Affects
fillOpacityorstrokeOpacity, depending on thefilledproperty. size- Type: number | ArrowRelativeSize | ExprRef
Arrow stem thickness in pixels, or as a fraction of the perpendicular band or view span for axis-aligned arrows.
Numeric values are pixels.
{ "band": 0.8 }resolves to 80% of the perpendicular band width, or 80% of the perpendicular view span when no band scale is available. Usechannelto explicitly select the reference channel. Band-relative size is not supported for diagonal arrows.Default value:
8 startNotch- Type: boolean | ExprRef
Whether to draw a notch at the start of the arrow. The start notch uses the same slope as the arrowhead edge.
Default value:
false stem- Type: boolean | ExprRef
Whether to draw the arrow stem. When
false, the resolvedsizestill controls open-head thickness.minStemLengthhas no effect when the stem is hidden.Default value:
true stroke- Type: string | ExprRef
The stroke color
strokeOpacity- Type: number | ExprRef
The stroke opacity. Value between
0and1. strokeWidth- Type: number | ExprRef
The stroke width in pixels.
style- Type: string | string[]
Named style reference(s) resolved from
config.style. If an array is provided, later styles override earlier ones. tooltip- Type: HandledTooltip | null | boolean
Tooltip handler. If
null, no tooltip is shown. If string, specifies the tooltip handler to use. x- Type: number | ExprRef
Position on the x axis.
x2- Type: number | ExprRef
The secondary position on the x axis.
xOffset- Type: number
Offsets of the
xandx2coordinates in pixels. The offset is applied after the viewport scaling and translation.Default value:
0 y- Type: number | ExprRef
Position on the y axis.
y2- Type: number | ExprRef
The secondary position on the y axis.
yOffset- Type: number
Offsets of the
yandy2coordinates in pixels. The offset is applied after the viewport scaling and translation.Default value:
0
ArrowDirection¶
Type: "forward" | "reverse"
ArrowRelativeSize¶
bandRequired- Type: number
Fraction of the perpendicular band or view span.
channel- Type: string
Channel whose band or view span is used. If omitted or
"auto", GenomeSpy infers the perpendicular channel from the axis-aligned arrow endpoints. Band-relative size is not supported for diagonal arrows.
ArrowSize¶
Type: number | ArrowRelativeSize | ExprRef
AxisOrient¶
Type: "top" | "bottom" | "left" | "right"
AxisPlacement¶
Type: "outside" | "inside"
Baseline¶
Type: "top" | "middle" | "bottom" | "alphabetic" | "baseline"
BedDataFormat¶
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time
BedpeDataFormat¶
columns- Type: array
Optional ordered list of field names for headerless BEDPE input. If omitted, BEDPE fields are resolved from the default BEDPE column order or from a matching header row when present.
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time
BindCheckbox¶
debounce- Type: number
If defined, delays event handling until the specified milliseconds have elapsed since the last event was fired.
description- Type: string
An optional description or help text that is shown below the input element.
name- Type: string
By default, the parameter name is used to label input elements. This
nameproperty can be used instead to specify a custom label for the bound parameter.
BindInput¶
autocomplete- Type: string
A hint for form autofill. See the HTML autocomplete attribute for additional information.
debounce- Type: number
If defined, delays event handling until the specified milliseconds have elapsed since the last event was fired.
description- Type: string
An optional description or help text that is shown below the input element.
input- Type: string
The type of input element to use. The valid values are
"checkbox","radio","range","select","text","number", and"color". name- Type: string
By default, the parameter name is used to label input elements. This
nameproperty can be used instead to specify a custom label for the bound parameter. placeholder- Type: string
Text that appears in the form control when it has no value set.
BindRadioSelect¶
debounce- Type: number
If defined, delays event handling until the specified milliseconds have elapsed since the last event was fired.
description- Type: string
An optional description or help text that is shown below the input element.
inputRequired- Type: string
TODO
labels- Type: array
An array of label strings to represent the
optionsvalues. If unspecified, theoptionsvalue will be coerced to a string and used as the label. name- Type: string
By default, the parameter name is used to label input elements. This
nameproperty can be used instead to specify a custom label for the bound parameter. optionsRequired- Type: array
An array of options to select from.
BindRange¶
debounce- Type: number
If defined, delays event handling until the specified milliseconds have elapsed since the last event was fired.
description- Type: string
An optional description or help text that is shown below the input element.
max- Type: number
Sets the maximum slider value. Defaults to the larger of the signal value and
100. min- Type: number
Sets the minimum slider value. Defaults to the smaller of the signal value and
0. name- Type: string
By default, the parameter name is used to label input elements. This
nameproperty can be used instead to specify a custom label for the bound parameter. step- Type: number
Sets the minimum slider increment. If undefined, the step size will be automatically determined based on the
minandmaxvalues.
Binding¶
Type: BindCheckbox | BindRadioSelect | BindRange | BindInput
BrushConfig¶
clip- Type: boolean |
"never"Whether the brush rectangle should be clipped to the viewport.
Default value:
true cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is over the interval mark.
Default value:
{ expr: "intervalDragActive ? 'grabbing' : 'move'" } fill- Type: string
The fill color of the interval mark.
Default value:
"#808080" fillOpacity- Type: number
The fill opacity of the interval mark (a value between
0and1).Default value:
0.05 measure- Type: string
Where to display the measurement text (e.g., number of base pairs) for the interval selection.
-
"none"-- do not show the measurement. -"inside"-- show inside the brush rectangle. -"outside"-- show outside the brush rectangle.Default value:
"none" shadowBlur- Type: number | ExprRef
The blur radius of the drop shadow in pixels. Higher values produce a more diffuse shadow.
Default value:
0 shadowColor- Type: string | ExprRef
The color of the drop shadow. Any valid CSS color string is allowed.
Default value:
"black" shadowOffsetX- Type: number | ExprRef
The horizontal offset of the drop shadow in pixels. Positive values move the shadow to the right.
Default value:
0 shadowOffsetY- Type: number | ExprRef
The vertical offset of the drop shadow in pixels. Positive values move the shadow downward.
Default value:
0 shadowOpacity- Type: number | ExprRef
The opacity of the drop shadow. Value between
0(fully transparent) and1(fully opaque).Default value:
0(disabled) stroke- Type: string
The stroke color of the interval mark.
Default value:
"black" strokeOpacity- Type: number
The stroke opacity of the interval mark (a value between
0and1).Default value:
0.2 strokeWidth- Type: number
The stroke width of the interval mark.
Default value:
1 zindex- Type: number
Z-order of the interval mark relative to the view content.
Values greater than
0render after the view marks. Values less than or equal to0render before the marks.Default value:
1
BuiltInThemeName¶
Type: "genomespy" | "vegalite" | "quartz" | "dark" | "fivethirtyeight" | "urbaninstitute"
ChannelWithScale¶
Type: "x" | "y" | "x2" | "y2" | "color" | "fill" | "stroke" | "opacity" | "fillOpacity" | "strokeOpacity" | "strokeWidth" | "size" | "shape" | "direction" | "angle" | "dx" | "dy"
ChromPosDef¶
axis- Type: GenomeAxis | null
An object defining properties of axis's gridlines, ticks and labels. If
null, the axis for the encoding channel will be removed.Default value: If undefined, default axis properties are applied.
See also:
axisdocumentation. band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. chromRequired- Type: FieldName
The field having the chromosome or contig.
description- Type: string
A description of the encoded position. Can be used for documentation and to explain the meaning of the channel mapping.
domainInert- Type: boolean
Whether the field or evaluated expr should be excluded from the scale's domain. Prefer the view-level
domainInertwhen an entire subtree should be excluded.Default value:
false offset- Type: number
An offset or offsets that allow for adjusting the numbering base. The offset is subtracted from the positions.
GenomeSpy uses internally zero-based indexing with half-open intervals. UCSC-based formats (BED, etc.) generally use this scheme. However, for example, VCF files use one-based indexing and must be adjusted by setting the offset to
1.Default:
0 pos- Type: FieldName
The field having an intra-chromosomal position.
resolutionChannel- Type:
"x"|"y"|"x2"|"y2"|"color"|"fill"|"stroke"|"opacity"|"fillOpacity"|"strokeOpacity"|"strokeWidth"|"size"|"shape"|"direction"|"angle"|"dx"|"dy"An alternative channel for scale resolution.
This is mainly for internal use and allows using
colorchannel to resolvefillandstrokechannels under certain circumstances. scale- Type: Scale | null
An object defining properties of the channel's scale, which is the function that transforms values in the data domain (numbers, dates, strings, etc) to visual values (pixels, colors, sizes) of the encoding channels.
If
null, the scale will be disabled and the data value will be directly encoded.Default value: If undefined, default scale properties are applied.
See also:
scaledocumentation. title- Type: string | null
A title for the field. If
null, the title will be removed.
ChromosomalLocus¶
chromRequired- Type: string
The name of the chromosome. For example:
"chr1","CHR1", or"1". pos- Type: number
The zero-based position inside the chromosome or contig.
ColorDef¶
Type: FieldOrDatumDefWithCondition
ColorSchemeConfig¶
Type: string | SchemeParams
CompareParams¶
fieldRequired- Type: string (field name)[] | string (field name)
The field(s) to sort by
order- Type: (
"ascending"|"descending")[] |"ascending"|"descending"The order(s) to use:
"ascending"(default),"descending".
ComplexDomain¶
Type: ChromosomalLocus[]
ConcatSpec¶
axes- Type: object
Defines properties for axis resolutions used by this view subtree.
Use this when a composed view shares an axis across child views and the axis settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
baseUrl- Type: string
The base URL for relative URL data sources and URL imports. The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.
columnsRequired- Type: number
The number of columns in the grid.
concatRequired- Type: array
TODO
config- Type: GenomeSpyConfig
Configures defaults for this view subtree.
Properties in child views override properties inherited from ancestors.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is inside the view. The deepest matching cursor wins: mark cursor first, then the pointed view, then ancestor views outward toward the root.
Default value: browser default
data- Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData | Generator
Specifies a data source. If omitted, the data source is inherited from the parent view.
datasets- Type: object
Named datasets available to this view and its descendants.
A descendant declaration with the same name shadows this declaration. Declare named data here to establish reliable lexical scope and enable scoped runtime updates.
description- Type: string | string[]
A description of the view. Can be used for documentation. The description of the top-level view is shown in the toolbar of the GenomeSpy App.
domainInert- Type: boolean
If true, this view and its descendants do not contribute to scale domains. Child views inherit this flag automatically.
Default value:
false encoding- Type: Encoding
Specifies how data are encoded using the visual channels.
height- Type: SizeDef | number | Step | ExprRef |
"container"Height of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default value:
"container" legends- Type: object
Defines properties for legend resolutions used by this view subtree.
Use this when a composed view shares a legend across child views and the legend settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
name- Type: string
An explicit name used to address the view. It is recommended to keep names unique among siblings. In the App (where view state is bookmarkable), the name must be unique within its import scope for views with configurable visibility, etc.
overhang- Type: OverhangConfig
Controls whether external overhang on each edge reserves layout space. Setting an edge to false lets axes, titles, legends, or custom view overhang overlap nearby content while remaining visible.
Default value: all edges reserve overhang
padding- Type: Paddings | number
Padding applied to the view. Accepts either a number representing pixels or an object specifying separate paddings for each edge.
Examples: -
padding: 10-padding: { top: 10, right: 20, bottom: 10, left: 20 }Default value:
0 params- Type: array
Dynamic variables that parameterize a visualization.
resolve- Type: object
Specifies how scales, axes, and legends are resolved in the view hierarchy.
If legend resolution is not configured explicitly, it follows the corresponding scale resolution.
scales- Type: object
Defines properties for scale resolutions used by this view subtree.
Use this when a composed view shares a scale across child views and the scale settings, such as the visible domain, belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
separator- Type: boolean | SeparatorProps
Draws separator rules between visible child views. The separators are centered within the spacing gaps and do not affect layout.
If
true, the defaults are equivalent to:{"type":"rule","size":1,"color":"#ccc","opacity":1,"strokeDash":[4,4],"strokeCap":"butt"}UseincludePlotMarginto control whether the separators extend into the plot margin.Default value:
false spacing- Type: number
The gap between the views, in pixels.
templates- Type: object
TODO
title- Type: string | Title
View title.
transform- Type: array
An array of transformations applied to the data before visual encoding.
viewportHeight- Type: SizeDef | number | ExprRef |
"container"Optional viewport height of the view. If the view size exceeds the viewport height, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same asheight) viewportWidth- Type: SizeDef | number | ExprRef |
"container"Optional viewport width of the view. If the view size exceeds the viewport width, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same aswidth) visible- Type: boolean
The default visibility of the view. An invisible view is removed from the layout and not rendered. For context, see toggleable view visibility.
Default:
true width- Type: SizeDef | number | Step | ExprRef |
"container"Width of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default:
"container"
Contig¶
nameRequired- Type: string
TODO
sizeRequired- Type: number
TODO
CoordinateLookupInput¶
dataRequired- Type: LazyData
The lazy side data source.
transform- Type: array
Transforms applied to the side data before lookup.
CoreRootSpec¶
Type: object | object | object | object | object | object
CrossData¶
Type: UrlData | InlineData | NamedData | Generator
CrossInput¶
dataRequired- Type: UrlData | InlineData | NamedData | Generator
Finite eager data crossed with the primary input.
transform- Type: array
Unary transforms applied to the foreign data before crossing.
CsvDataFormat¶
columns- Type: array
Optional ordered list of field names for headerless CSV or TSV input. When provided, the first row is interpreted as data rather than a header row.
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time type- Type: string
Type of input data:
"json","csv","tsv","dsv".Default value: The default format type is determined by the extension of the file URL. Compression suffixes such as
.gzare ignored during inference. If no extension is detected,"json"will be used by default.
Data¶
Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData | Generator
DataFormat¶
Type: CsvDataFormat | DsvDataFormat | JsonDataFormat | BedDataFormat | BedpeDataFormat | VcfDataFormat | OtherDataFormat
DataSource¶
Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData
DirectionDef¶
Type: object | object | ValueDef
DomEventType¶
Type: "click" | "dblclick" | "mouseenter" | "mouseleave" | "mouseover" | "mousemove" | "mousedown" | "wheel" | "pointerover"
DomainValue¶
Type: number | string | boolean | ExprRef
DomainValueArray¶
Type: (number | string | boolean | ExprRef)[]
DsvDataFormat¶
columns- Type: array
Optional ordered list of field names for headerless delimiter-separated input. When provided, the first row is interpreted as data rather than a header row.
delimiterRequired- Type: string
The delimiter between records. The delimiter must be a single character (i.e., a single 16-bit code unit); so, ASCII delimiters are fine, but emoji delimiters are not.
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time
DynamicCallbackData¶
description- Type: string
A description of the data source. Can be used for documentation and to explain the role of the data in the visualization.
dynamicCallbackSourceRequired- Type: boolean
The View class has
getDynamicData()methods that provides the data. This is intended for internal use. format- Type: CsvDataFormat | DsvDataFormat | JsonDataFormat | BedDataFormat | BedpeDataFormat | VcfDataFormat | OtherDataFormat
An object that specifies the format for parsing the data.
name- Type: string
Provide a placeholder name and bind data at runtime.
DynamicOpacity¶
channel- Type:
"x"|"y"|"auto"The positional channel whose scale domain controls the opacity. If set to
"auto", bothxandyscales may contribute.If omitted,
xis used when available andyis used as a fallback. unitsPerPixelRequired- Type: array
Opacity stops expressed as units (base pairs, for example) per pixel. The values must be positive.
Each stop is paired with an opacity in
valuesat the same index. Stops can be constants or expression references. valuesRequired- Type: array
Opacity values that match the given
unitsPerPixelstops.Values outside the stop range are clamped to the nearest stop.
EventConfig¶
filter- Type: string
An optional filter expression to further filter events of the specified type. The expression can only refer to the event object as
event, and should evaluate to a boolean value indicating whether to include the event. No other data or parameters are in scope. typeRequired- Type:
"click"|"dblclick"|"mouseenter"|"mouseleave"|"mouseover"|"mousemove"|"mousedown"|"wheel"|"pointerover"The type of event to listen to. For example,
"click"or"mouseenter".
ExprDef¶
band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. description- Type: string
A description of the encoded expression. Can be used for documentation and to explain the meaning of the channel mapping.
exprRequired- Type: string
An expression. Properties of the data can be accessed through the
datumobject. title- Type: string | null
A title for the field. If
null, the title will be removed. type- Type:
"quantitative"|"ordinal"|"nominal"|"index"|"locus"TODO
ExprParameter¶
description- Type: string
A description of the parameter. Can be used for documentation and to explain the meaning of the control or selection.
exprRequired- Type: string
An expression for the value of the parameter. This expression may include other parameters, in which case the parameter will automatically update in response to upstream parameter changes.
nameRequired- Type: string
A unique name for the variable parameter. Parameter names should be valid JavaScript identifiers: they should contain only alphanumeric characters (or "$", or "_") and may not start with a digit. Reserved keywords that may not be used as parameter names are: "datum".
persist- Type: boolean
Whether the parameter should be persisted in bookmarks and provenance.
This primarily affects GenomeSpy App behavior. Set to
falsefor ephemeral params (e.g., hover selections) or when the selection cannot be persisted due to missingencoding.key.Default value:
true transition- Type: ParamTransition
Smoothly follows numeric expression output values.
Field¶
Type: string
FieldDefWithoutScale¶
description- Type: string
A description of the encoded field. Can be used for documentation and to explain the meaning of the channel mapping.
field- Type: string
Required. A string defining the name of the field from which to pull a data value or an object defining iterated values from the
repeatoperator.See also:
fielddocumentation.Notes: 1) Dots (
.) and brackets ([and]) can be used to access nested objects (e.g.,"field": "foo.bar"and"field": "foo['bar']"). If field names contain dots or brackets but are not nested, you can use\\to escape dots and brackets (e.g.,"a\\.b"and"a\\[0\\]"). See more details about escaping in the field documentation. 2)fieldis not required ifaggregateiscount. title- Type: string | null
A title for the field. If
null, the title will be removed.
FieldName¶
Type: string
FilterParams¶
Type: ExprFilterParams | SelectionFilterParams
FontStyle¶
Type: "normal" | "italic"
FontWeight¶
Type: number | "thin" | "light" | "regular" | "normal" | "medium" | "bold" | "black"
GenomeConfig¶
Type: UrlGenomeConfig | InlineGenomeConfig | GenomeConfigBase
GenomeConfigBase¶
nameRequired- Type: string
Name of the genome assembly, e.g.,
hg19orhg38.
GenomeDefinition¶
Type: UrlGenomeDefinition | InlineGenomeDefinition
HConcatSpec¶
axes- Type: object
Defines properties for axis resolutions used by this view subtree.
Use this when a composed view shares an axis across child views and the axis settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
baseUrl- Type: string
The base URL for relative URL data sources and URL imports. The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.
config- Type: GenomeSpyConfig
Configures defaults for this view subtree.
Properties in child views override properties inherited from ancestors.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is inside the view. The deepest matching cursor wins: mark cursor first, then the pointed view, then ancestor views outward toward the root.
Default value: browser default
data- Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData | Generator
Specifies a data source. If omitted, the data source is inherited from the parent view.
datasets- Type: object
Named datasets available to this view and its descendants.
A descendant declaration with the same name shadows this declaration. Declare named data here to establish reliable lexical scope and enable scoped runtime updates.
description- Type: string | string[]
A description of the view. Can be used for documentation. The description of the top-level view is shown in the toolbar of the GenomeSpy App.
domainInert- Type: boolean
If true, this view and its descendants do not contribute to scale domains. Child views inherit this flag automatically.
Default value:
false encoding- Type: Encoding
Specifies how data are encoded using the visual channels.
hconcatRequired- Type: array
TODO
height- Type: SizeDef | number | Step | ExprRef |
"container"Height of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default value:
"container" legends- Type: object
Defines properties for legend resolutions used by this view subtree.
Use this when a composed view shares a legend across child views and the legend settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
name- Type: string
An explicit name used to address the view. It is recommended to keep names unique among siblings. In the App (where view state is bookmarkable), the name must be unique within its import scope for views with configurable visibility, etc.
overhang- Type: OverhangConfig
Controls whether external overhang on each edge reserves layout space. Setting an edge to false lets axes, titles, legends, or custom view overhang overlap nearby content while remaining visible.
Default value: all edges reserve overhang
padding- Type: Paddings | number
Padding applied to the view. Accepts either a number representing pixels or an object specifying separate paddings for each edge.
Examples: -
padding: 10-padding: { top: 10, right: 20, bottom: 10, left: 20 }Default value:
0 params- Type: array
Dynamic variables that parameterize a visualization.
resolve- Type: object
Specifies how scales, axes, and legends are resolved in the view hierarchy.
If legend resolution is not configured explicitly, it follows the corresponding scale resolution.
scales- Type: object
Defines properties for scale resolutions used by this view subtree.
Use this when a composed view shares a scale across child views and the scale settings, such as the visible domain, belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
separator- Type: boolean | SeparatorProps
Draws separator rules between visible child views. The separators are centered within the spacing gaps and do not affect layout.
If
true, the defaults are equivalent to:{"type":"rule","size":1,"color":"#ccc","opacity":1,"strokeDash":[4,4],"strokeCap":"butt"}UseincludePlotMarginto control whether the separators extend into the plot margin.Default value:
false spacing- Type: number
The gap between the views, in pixels.
templates- Type: object
TODO
title- Type: string | Title
View title.
transform- Type: array
An array of transformations applied to the data before visual encoding.
viewportHeight- Type: SizeDef | number | ExprRef |
"container"Optional viewport height of the view. If the view size exceeds the viewport height, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same asheight) viewportWidth- Type: SizeDef | number | ExprRef |
"container"Optional viewport width of the view. If the view size exceeds the viewport width, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same aswidth) visible- Type: boolean
The default visibility of the view. An invisible view is removed from the layout and not rendered. For context, see toggleable view visibility.
Default:
true width- Type: SizeDef | number | Step | ExprRef |
"container"Width of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default:
"container"
HandledTooltip¶
handlerRequired- Type: string
TODO
params- Type: object
TODO
IdentifierParams¶
as- Type: string
Default:
"_uniqueId" description- Type: string
A description of the transform step. Can be used for documentation and agent context.
IndexUrlSourceRef¶
Type: string | ExprRef | IndexUrlTemplate
IndexUrlTemplate¶
templateRequired- Type: string
URL template for index files. Uses the same values and field placeholder as the
urltemplate.
InlineDataset¶
Type: number[] | string[] | boolean[] | object[] | string | object
InlineGenomeConfig¶
contigsRequired- Type: array
An array of contigs/sequences in the genome assembly.
nameRequired- Type: string
Name of the genome assembly, e.g.,
hg19orhg38.
InlineGenomeDefinition¶
contigsRequired- Type: array
An array of contigs/sequences in the genome assembly.
InlineLocusAssembly¶
Type: UrlGenomeDefinition | InlineGenomeDefinition
InteractionEventType¶
Type: "click" | "dblclick" | "mouseenter" | "mouseleave" | "mouseover" | "mousemove" | "mousedown" | "wheel"
IntervalSelectionConfig¶
clear- Type:
"click"|"dblclick"|"mouseenter"|"mouseleave"|"mouseover"|"mousemove"|"mousedown"|"wheel"|"pointerover"| EventConfig | string | booleanA string or object that defines the events that should clear the selection.
Default value:
"dblclick" encodings- Type: array
An array of encoding channels that define the interval selection.
extent- Type:
"auto"|"view"|"container"Visual extent of the interval selection rectangle.
"auto"draws one spanning rectangle when the selected channel can span a concat safely."view"draws one rectangle per participating view."container"requires one spanning rectangle.Default value:
"auto" mark- Type: BrushConfig
Interval selections display a rectangle mark to show the selected range. Use the
markproperty to adjust the appearance of this rectangle. on- Type:
"click"|"dblclick"|"mouseenter"|"mouseleave"|"mouseover"|"mousemove"|"mousedown"|"wheel"|"pointerover"| EventConfig | stringA string or object that defines the events to which the selection should listen.
Default value:
- point selections:
"click"- interval selections: -"mousedown[event.shiftKey]"when any brushed channel is zoomable -"mousedown"otherwise zoom- Type:
"click"|"dblclick"|"mouseenter"|"mouseleave"|"mouseover"|"mousemove"|"mousedown"|"wheel"|"pointerover"| EventConfig | string | booleanControls whether an active interval selection can be resized by mouse wheel. The wheel interaction only applies when the cursor is over the interval.
Can be:
-
true/false- event type string such as"wheel"or"wheel[event.altKey]"- anEventConfigobjectCurrently, only
"wheel"events are supported.Default value:
-
falsewhen any brushed channel uses a zoomable scale -trueotherwise
JsonDataFormat¶
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time property- Type: string
The JSON property containing the desired data. This parameter can be used when the loaded JSON file may have surrounding structure or meta-data. For example
"property": "values.features"is equivalent to retrievingjson.values.featuresfrom the loaded JSON object.
KeyDef¶
Type: FieldDefWithoutScale | FieldDefWithoutScale[]
LayerSpec¶
axes- Type: object
Defines properties for axis resolutions used by this view subtree.
Use this when a composed view shares an axis across child views and the axis settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
baseUrl- Type: string
The base URL for relative URL data sources and URL imports. The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.
config- Type: GenomeSpyConfig
Configures defaults for this view subtree.
Properties in child views override properties inherited from ancestors.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is inside the view. The deepest matching cursor wins: mark cursor first, then the pointed view, then ancestor views outward toward the root.
Default value: browser default
data- Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData | Generator
Specifies a data source. If omitted, the data source is inherited from the parent view.
datasets- Type: object
Named datasets available to this view and its descendants.
A descendant declaration with the same name shadows this declaration. Declare named data here to establish reliable lexical scope and enable scoped runtime updates.
description- Type: string | string[]
A description of the view. Can be used for documentation. The description of the top-level view is shown in the toolbar of the GenomeSpy App.
domainInert- Type: boolean
If true, this view and its descendants do not contribute to scale domains. Child views inherit this flag automatically.
Default value:
false encoding- Type: Encoding
Specifies how data are encoded using the visual channels.
height- Type: SizeDef | number | Step | ExprRef |
"container"Height of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default value:
"container" layerRequired- Type: array
TODO
legends- Type: object
Defines properties for legend resolutions used by this view subtree.
Use this when a composed view shares a legend across child views and the legend settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
name- Type: string
An explicit name used to address the view. It is recommended to keep names unique among siblings. In the App (where view state is bookmarkable), the name must be unique within its import scope for views with configurable visibility, etc.
opacity- Type: number | DynamicOpacity | ExprRef
Opacity of the view and all its children.
This can be:
- a fixed number between
0and1- an expression reference (ExprRef) - aDynamicOpacitydefinition for zoom-dependent opacityDynamic opacity is useful for semantic zooming where layers are faded in and out as the user zooms.
Example:
json "opacity": { "unitsPerPixel": [100000, 40000], "values": [0, 1] }In this example, the view fades in while zooming in from 100 000 to 40 000 units per pixel.
Default value:
1.0 overhang- Type: OverhangConfig
Controls whether external overhang on each edge reserves layout space. Setting an edge to false lets axes, titles, legends, or custom view overhang overlap nearby content while remaining visible.
Default value: all edges reserve overhang
padding- Type: Paddings | number
Padding applied to the view. Accepts either a number representing pixels or an object specifying separate paddings for each edge.
Examples: -
padding: 10-padding: { top: 10, right: 20, bottom: 10, left: 20 }Default value:
0 params- Type: array
Dynamic variables that parameterize a visualization.
resolve- Type: object
Specifies how scales, axes, and legends are resolved in the view hierarchy.
If legend resolution is not configured explicitly, it follows the corresponding scale resolution.
scales- Type: object
Defines properties for scale resolutions used by this view subtree.
Use this when a composed view shares a scale across child views and the scale settings, such as the visible domain, belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
templates- Type: object
TODO
title- Type: string | Title
View title.
transform- Type: array
An array of transformations applied to the data before visual encoding.
view- Type: ViewBackground
TODO
viewportHeight- Type: SizeDef | number | ExprRef |
"container"Optional viewport height of the view. If the view size exceeds the viewport height, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same asheight) viewportWidth- Type: SizeDef | number | ExprRef |
"container"Optional viewport width of the view. If the view size exceeds the viewport width, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same aswidth) visible- Type: boolean
The default visibility of the view. An invisible view is removed from the layout and not rendered. For context, see toggleable view visibility.
Default:
true width- Type: SizeDef | number | Step | ExprRef |
"container"Width of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default:
"container"
LazyDataParams¶
Type: AxisTicksData | object | object | object | AxisGenomeData | IndexedFastaData | BigWigData | BigBedData | BamData | TabixTsvData | Gff3Data | VcfData
LegendDirection¶
Type: "vertical" | "horizontal"
LegendOrient¶
Type: "left" | "right" | "top" | "bottom" | "top-left" | "top-right" | "bottom-left" | "bottom-right"
LegendTitleOrient¶
Type: "top" | "bottom" | "left" | "right"
LerpTransition¶
epsilon- Type: number
Distance from the target at which the current value snaps to the target.
Default value:
0.01 halfLife- Type: number
Time in milliseconds for the remaining distance to the target to halve.
Default value:
80
LookupSelfInput¶
MarkPropExprDef¶
band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. description- Type: string
A description of the encoded expression. Can be used for documentation and to explain the meaning of the channel mapping.
domainInert- Type: boolean
Whether the field or evaluated expr should be excluded from the scale's domain. Prefer the view-level
domainInertwhen an entire subtree should be excluded.Default value:
false exprRequired- Type: string
An expression. Properties of the data can be accessed through the
datumobject. legend- Type: Legend | null
Legend properties for the encoding channel. If
null, the legend for the channel is removed. If an object is provided, a legend is created even when legends are disabled by default in the config.Default value: If undefined, configured legend defaults are applied.
resolutionChannel- Type:
"x"|"y"|"x2"|"y2"|"color"|"fill"|"stroke"|"opacity"|"fillOpacity"|"strokeOpacity"|"strokeWidth"|"size"|"shape"|"direction"|"angle"|"dx"|"dy"An alternative channel for scale resolution.
This is mainly for internal use and allows using
colorchannel to resolvefillandstrokechannels under certain circumstances. scale- Type: Scale | null
An object defining properties of the channel's scale, which is the function that transforms values in the data domain (numbers, dates, strings, etc) to visual values (pixels, colors, sizes) of the encoding channels.
If
null, the scale will be disabled and the data value will be directly encoded.Default value: If undefined, default scale properties are applied.
See also:
scaledocumentation. title- Type: string | null
A title for the field. If
null, the title will be removed. typeRequired- Type:
"quantitative"|"ordinal"|"nominal"|"index"|"locus"TODO
MarkProps¶
Type: RectProps | ArrowProps | TextProps | RuleProps | TickProps | LinkProps | PointProps
MarkType¶
Type: "rect" | "point" | "rule" | "tick" | "text" | "link" | "arrow"
MergeFacetsParams¶
description- Type: string
A description of the transform step. Can be used for documentation and agent context.
MultiUrlSourceRef¶
Type: string | string[] | ExprRef | UrlTemplate
MultiscaleSpec¶
axes- Type: object
Defines properties for axis resolutions used by this view subtree.
Use this when a composed view shares an axis across child views and the axis settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
baseUrl- Type: string
The base URL for relative URL data sources and URL imports. The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.
config- Type: GenomeSpyConfig
Configures defaults for this view subtree.
Properties in child views override properties inherited from ancestors.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is inside the view. The deepest matching cursor wins: mark cursor first, then the pointed view, then ancestor views outward toward the root.
Default value: browser default
data- Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData | Generator
Specifies a data source. If omitted, the data source is inherited from the parent view.
datasets- Type: object
Named datasets available to this view and its descendants.
A descendant declaration with the same name shadows this declaration. Declare named data here to establish reliable lexical scope and enable scoped runtime updates.
description- Type: string | string[]
A description of the view. Can be used for documentation. The description of the top-level view is shown in the toolbar of the GenomeSpy App.
domainInert- Type: boolean
If true, this view and its descendants do not contribute to scale domains. Child views inherit this flag automatically.
Default value:
false encoding- Type: Encoding
Specifies how data are encoded using the visual channels.
height- Type: SizeDef | number | Step | ExprRef |
"container"Height of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default value:
"container" legends- Type: object
Defines properties for legend resolutions used by this view subtree.
Use this when a composed view shares a legend across child views and the legend settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
multiscaleRequired- Type: array
TODO
name- Type: string
An explicit name used to address the view. It is recommended to keep names unique among siblings. In the App (where view state is bookmarkable), the name must be unique within its import scope for views with configurable visibility, etc.
opacity- Type: number | DynamicOpacity | ExprRef
Opacity of the view and all its children.
This can be:
- a fixed number between
0and1- an expression reference (ExprRef) - aDynamicOpacitydefinition for zoom-dependent opacityDynamic opacity is useful for semantic zooming where layers are faded in and out as the user zooms.
Example:
json "opacity": { "unitsPerPixel": [100000, 40000], "values": [0, 1] }In this example, the view fades in while zooming in from 100 000 to 40 000 units per pixel.
Default value:
1.0 overhang- Type: OverhangConfig
Controls whether external overhang on each edge reserves layout space. Setting an edge to false lets axes, titles, legends, or custom view overhang overlap nearby content while remaining visible.
Default value: all edges reserve overhang
padding- Type: Paddings | number
Padding applied to the view. Accepts either a number representing pixels or an object specifying separate paddings for each edge.
Examples: -
padding: 10-padding: { top: 10, right: 20, bottom: 10, left: 20 }Default value:
0 params- Type: array
Dynamic variables that parameterize a visualization.
resolve- Type: object
Specifies how scales, axes, and legends are resolved in the view hierarchy.
If legend resolution is not configured explicitly, it follows the corresponding scale resolution.
scales- Type: object
Defines properties for scale resolutions used by this view subtree.
Use this when a composed view shares a scale across child views and the scale settings, such as the visible domain, belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
stopsRequired- Type: (number | ExprRef)[] | FadedMultiscaleStops | TransitionedMultiscaleStops
Stop definition that controls transitions between the multiscale levels.
-
number[]is shorthand for{ metric: "unitsPerPixel", values: ... }-(number | ExprRef)[]supports mixed constants and expressions - Object form allows configuring metric, channel, and fade. templates- Type: object
TODO
title- Type: string | Title
View title.
transform- Type: array
An array of transformations applied to the data before visual encoding.
view- Type: ViewBackground
TODO
viewportHeight- Type: SizeDef | number | ExprRef |
"container"Optional viewport height of the view. If the view size exceeds the viewport height, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same asheight) viewportWidth- Type: SizeDef | number | ExprRef |
"container"Optional viewport width of the view. If the view size exceeds the viewport width, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same aswidth) visible- Type: boolean
The default visibility of the view. An invisible view is removed from the layout and not rendered. For context, see toggleable view visibility.
Default:
true width- Type: SizeDef | number | Step | ExprRef |
"container"Width of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default:
"container"
MultiscaleStops¶
Type: FadedMultiscaleStops | TransitionedMultiscaleStops
MultiscaleStopsDef¶
Type: (number | ExprRef)[] | FadedMultiscaleStops | TransitionedMultiscaleStops
NamedGenomeConfig¶
Type: UrlGenomeDefinition | InlineGenomeDefinition | object
NumericDomain¶
Type: number[]
NumericMarkPropDef¶
Type: FieldOrDatumDefWithCondition
NumericStopDef¶
Type: number | ExprRef
NumericValueDef¶
description- Type: string
A description of the encoded value. Can be used for documentation and to explain the meaning of the channel mapping.
title- Type: string | null
A title for the field. If
null, the title will be removed. valueRequired- Type: number | ExprRef
A constant value in visual domain (e.g.,
"red"/"#0099ff", values between0to1for opacity).
OtherDataFormat¶
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time typeRequired- Type: string
Type of input data:
"json","csv","tsv","dsv".Default value: The default format type is determined by the extension of the file URL. Compression suffixes such as
.gzare ignored during inference. If no extension is detected,"json"will be used by default.
OverhangConfig¶
bottom- Type: boolean
TODO
left- Type: boolean
TODO
right- Type: boolean
TODO
top- Type: boolean
TODO
PackLegendLabelsParams¶
columnPadding- Type: number
Padding between columns in pixels.
Default:
0 columns- Type: number
The number of columns in which to arrange entries.
description- Type: string
A description of the transform step. Can be used for documentation and agent context.
direction- Type: string
The direction in which entries are laid out.
Default:
"vertical" fontSize- Type: number
Label font size in pixels.
Default:
10 labelOffset- Type: number
Offset between the symbol and label in pixels.
Default:
0 labelWidthRequired- Type: string (field name)
The field that contains measured label width in pixels.
rowPadding- Type: number
Padding between rows in pixels.
Default:
0 symbolOffset- Type: number
Horizontal offset for generated symbol coordinates in pixels.
Default:
0 symbolSize- Type: number | string (field name)
Symbol size in pixels squared, or a field containing per-entry symbol sizes in pixels squared.
Default:
100 symbolStrokeWidth- Type: number | string (field name)
Symbol stroke width in pixels, or a field containing per-entry stroke widths in pixels.
Default:
0 xOffset- Type: number
Horizontal offset for all generated entry coordinates in pixels.
Default:
0 yExtent- Type: number | ExprRef
Height of the pixel-space layout area. When provided, the transform also emits inverted y coordinates for GenomeSpy's unit y range.
yOffset- Type: number
Vertical offset for all generated entry coordinates in pixels.
Default:
0
PaddingConfig¶
Type: Paddings | number
Paddings¶
bottom- Type: number
TODO
left- Type: number
TODO
right- Type: number
TODO
top- Type: number
TODO
Parameter¶
Type: PlainValueParameter | TransitionedValueParameter | ExprParameter | SelectionParameter | RulerParameter
Parse¶
Type: object
ParseValue¶
Type: string | null
PlainValueParameter¶
bind- Type: BindCheckbox | BindRadioSelect | BindRange | BindInput
Binds the parameter to an external input element such as a slider, selection list or radio button group.
description- Type: string
A description of the parameter. Can be used for documentation and to explain the meaning of the control or selection.
nameRequired- Type: string
A unique name for the variable parameter. Parameter names should be valid JavaScript identifiers: they should contain only alphanumeric characters (or "$", or "_") and may not start with a digit. Reserved keywords that may not be used as parameter names are: "datum".
persist- Type: boolean
Whether the parameter should be persisted in bookmarks and provenance.
This primarily affects GenomeSpy App behavior. Set to
falsefor ephemeral params (e.g., hover selections) or when the selection cannot be persisted due to missingencoding.key.Default value:
true value- The initial value of the parameter.
Default value:
undefined
PointSelectionConfig¶
clear- Type:
"click"|"dblclick"|"mouseenter"|"mouseleave"|"mouseover"|"mousemove"|"mousedown"|"wheel"|"pointerover"| EventConfig | string | booleanA string or object that defines the events that should clear the selection.
Default value:
"dblclick" on- Type:
"click"|"dblclick"|"mouseenter"|"mouseleave"|"mouseover"|"mousemove"|"mousedown"|"wheel"|"pointerover"| EventConfig | stringA string or object that defines the events to which the selection should listen.
Default value:
- point selections:
"click"- interval selections: -"mousedown[event.shiftKey]"when any brushed channel is zoomable -"mousedown"otherwise toggle- Type: boolean
Controls whether data values should be toggled (inserted or removed from a point selection) when clicking with the shift key pressed.
-
true-- additional values can be selected by shift-clicking. -false-- only a single value can be selected at a time.Default value:
true
Position2Def¶
Type: object | SecondaryChromPosDef | object | object | PositionValueDef
PositionDatumDef¶
axis- Type: GenomeAxis | null
An object defining properties of axis's gridlines, ticks and labels. If
null, the axis for the encoding channel will be removed.Default value: If undefined, default axis properties are applied.
See also:
axisdocumentation. band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. datum- Type: Scalar | ExprRef
A constant value in data domain.
description- Type: string
A description of the encoded datum. Can be used for documentation and to explain the meaning of the channel mapping.
domainInert- Type: boolean
Whether the field or evaluated expr should be excluded from the scale's domain. Prefer the view-level
domainInertwhen an entire subtree should be excluded.Default value:
false resolutionChannel- Type:
"x"|"y"|"x2"|"y2"|"color"|"fill"|"stroke"|"opacity"|"fillOpacity"|"strokeOpacity"|"strokeWidth"|"size"|"shape"|"direction"|"angle"|"dx"|"dy"An alternative channel for scale resolution.
This is mainly for internal use and allows using
colorchannel to resolvefillandstrokechannels under certain circumstances. scale- Type: Scale | null
An object defining properties of the channel's scale, which is the function that transforms values in the data domain (numbers, dates, strings, etc) to visual values (pixels, colors, sizes) of the encoding channels.
If
null, the scale will be disabled and the data value will be directly encoded.Default value: If undefined, default scale properties are applied.
See also:
scaledocumentation. title- Type: string | null
A title for the field. If
null, the title will be removed. typeRequired- Type:
"quantitative"|"ordinal"|"nominal"|"index"|"locus"TODO
PositionDef¶
Type: PositionFieldDef | ChromPosDef | PositionDatumDef | PositionExprDef | PositionValueDef
PositionExprDef¶
axis- Type: GenomeAxis | null
An object defining properties of axis's gridlines, ticks and labels. If
null, the axis for the encoding channel will be removed.Default value: If undefined, default axis properties are applied.
See also:
axisdocumentation. band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. description- Type: string
A description of the encoded expression. Can be used for documentation and to explain the meaning of the channel mapping.
domainInert- Type: boolean
Whether the field or evaluated expr should be excluded from the scale's domain. Prefer the view-level
domainInertwhen an entire subtree should be excluded.Default value:
false exprRequired- Type: string
An expression. Properties of the data can be accessed through the
datumobject. title- Type: string | null
A title for the field. If
null, the title will be removed. typeRequired- Type:
"quantitative"|"ordinal"|"nominal"|"index"|"locus"TODO
PositionFieldDef¶
axis- Type: GenomeAxis | null
An object defining properties of axis's gridlines, ticks and labels. If
null, the axis for the encoding channel will be removed.Default value: If undefined, default axis properties are applied.
See also:
axisdocumentation. band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. description- Type: string
A description of the encoded field. Can be used for documentation and to explain the meaning of the channel mapping.
domainInert- Type: boolean
Whether the field or evaluated expr should be excluded from the scale's domain. Prefer the view-level
domainInertwhen an entire subtree should be excluded.Default value:
false field- Type: string
Required. A string defining the name of the field from which to pull a data value or an object defining iterated values from the
repeatoperator.See also:
fielddocumentation.Notes: 1) Dots (
.) and brackets ([and]) can be used to access nested objects (e.g.,"field": "foo.bar"and"field": "foo['bar']"). If field names contain dots or brackets but are not nested, you can use\\to escape dots and brackets (e.g.,"a\\.b"and"a\\[0\\]"). See more details about escaping in the field documentation. 2)fieldis not required ifaggregateiscount. resolutionChannel- Type:
"x"|"y"|"x2"|"y2"|"color"|"fill"|"stroke"|"opacity"|"fillOpacity"|"strokeOpacity"|"strokeWidth"|"size"|"shape"|"direction"|"angle"|"dx"|"dy"An alternative channel for scale resolution.
This is mainly for internal use and allows using
colorchannel to resolvefillandstrokechannels under certain circumstances. scale- Type: Scale | null
An object defining properties of the channel's scale, which is the function that transforms values in the data domain (numbers, dates, strings, etc) to visual values (pixels, colors, sizes) of the encoding channels.
If
null, the scale will be disabled and the data value will be directly encoded.Default value: If undefined, default scale properties are applied.
See also:
scaledocumentation. title- Type: string | null
A title for the field. If
null, the title will be removed. typeRequired- Type:
"quantitative"|"ordinal"|"nominal"|"index"|"locus"TODO
PositionValueDef¶
description- Type: string
A description of the encoded value. Can be used for documentation and to explain the meaning of the channel mapping.
title- Type: string | null
A title for the field. If
null, the title will be removed. valueRequired- Type: number | ExprRef
A constant value in visual domain (e.g.,
"red"/"#0099ff", values between0to1for opacity).
PositionalChannel¶
Type: "x" | "y" | "x2" | "y2"
PrimaryPositionalChannel¶
Type: "x" | "y"
ResolutionBehavior¶
Type: "independent" | "shared" | "excluded" | "forced"
RulerChannelValue¶
Type: Scalar | ChromosomalLocus | null
RulerClear¶
Type: mouseleave | mouseup | False
RulerDisplay¶
Type: "line" | "center" | "band" | "none"
RulerEventConfig¶
filter- Type: string
Optional filter expression that must evaluate to true before the event updates the ruler.
typeRequired- Type:
"mousemove"|"mousedown"Event that updates a pointer-driven ruler.
RulerEventType¶
Type: "mousemove" | "mousedown"
RulerExtent¶
Type: "auto" | "view" | "container"
RulerInitMapping¶
x- Type: Scalar | ChromosomalLocus | null
TODO
y- Type: Scalar | ChromosomalLocus | null
TODO
RulerMarkConfig¶
fill- Type: string
Fill color for
display: "band". fillOpacity- Type: number
Fill opacity for
display: "band". opacity- Type: number
Opacity of ruler lines and bands.
shadowBlur- Type: number | ExprRef
The blur radius of the drop shadow in pixels. Higher values produce a more diffuse shadow.
Default value:
0 shadowColor- Type: string | ExprRef
The color of the drop shadow. Any valid CSS color string is allowed.
Default value:
"black" shadowOffsetX- Type: number | ExprRef
The horizontal offset of the drop shadow in pixels. Positive values move the shadow to the right.
Default value:
0 shadowOffsetY- Type: number | ExprRef
The vertical offset of the drop shadow in pixels. Positive values move the shadow downward.
Default value:
0 shadowOpacity- Type: number | ExprRef
The opacity of the drop shadow. Value between
0(fully transparent) and1(fully opaque).Default value:
0(disabled) stroke- Type: string
Stroke color of ruler lines and band outlines.
strokeDash- Type: array
Alternating stroke and gap lengths for dashed ruler lines and band outlines.
strokeWidth- Type: number
Stroke width of ruler lines and band outlines, in pixels.
zindex- Type: number
Z-order relative to the view content.
Values greater than
0render after the view marks. Values less than or equal to0render before the marks. The default value depends on the element type.
RulerParameter¶
description- Type: string
A description of the parameter. Can be used for documentation and to explain the meaning of the control or selection.
nameRequired- Type: string
A unique name for the variable parameter. Parameter names should be valid JavaScript identifiers: they should contain only alphanumeric characters (or "$", or "_") and may not start with a digit. Reserved keywords that may not be used as parameter names are: "datum".
persist- Type: boolean
Whether the parameter should be persisted in bookmarks and provenance.
This primarily affects GenomeSpy App behavior. Set to
falsefor ephemeral params (e.g., hover selections) or when the selection cannot be persisted due to missingencoding.key.Default value:
true rulerRequired- Type: RulerConfig
Tracks a domain coordinate and displays it as a ruler in compatible views.
value- Type: RulerInitMapping
Initial ruler value.
RulerSnap¶
Type: auto | integer | False
RulerSource¶
Type: "pointer" | "viewport"
Scalar¶
Type: string | number | boolean
ScalarDomain¶
Type: NumericDomain | string[] | boolean[]
Scale¶
align- Type: number
The alignment of the steps within the scale range.
This value must lie in the range
[0,1]. A value of0.5indicates that the steps should be centered within the range. A value of0or1may be used to shift the bands to one side, say to position them adjacent to an axis.Default value:
0.5 assembly- Type: string | InlineLocusAssembly
Genome assembly definition for locus scales.
This can be:
- A string reference to a named assembly (built-in or root-configured). - An inline anonymous assembly that defines either
contigsorurl.If undefined, the default genome from the genome store is used.
base- Type: number
The logarithm base of the
logscale (default10). bins- Type: array
An array of bin boundaries over the scale domain. If provided, axes and legends will use the bin boundaries to inform the choice of tick marks and text labels.
clamp- Type: boolean
If
true, values that exceed the data domain are clamped to either the minimum or maximum range valueDefault value: derived from the scale config's
clamp(trueby default). constant- Type: number
A constant determining the slope of the symlog function around zero. Only used for
symlogscales.Default value:
1 domain- Type: NumericDomain | string[] | boolean[] | ComplexDomain | SelectionDomainRef | ExprRef | DomainValueArray
Customized domain values.
For quantitative fields,
domaincan take the form of a two-element array with minimum and maximum values. Piecewise scales can be created by providing adomainwith more than two entries.For temporal fields,
domaincan be a two-element array minimum and maximum values, in the form of either timestamps or the DateTime definition objects.For ordinal and nominal fields,
domaincan be an array that lists valid input values.The domain can also be defined by an expression reference that evaluates to the domain array. Array elements may also be expression references.
domainMax- Type: number
Sets the maximum value in the scale domain, overriding the
domainproperty. This property is only intended for use with scales having continuous domains. domainMid- Type: number
Inserts a single mid-point value into a two-element domain. The mid-point value must lie between the domain minimum and maximum values. This property can be useful for setting a midpoint for diverging color scales. The domainMid property is only intended for use with scales supporting continuous, piecewise domains.
domainMin- Type: number
Sets the minimum value in the scale domain, overriding the domain property. This property is only intended for use with scales having continuous domains.
domainTransition- Type: boolean | object
Controls whether domain updates are applied immediately or with a smooth transition.
Set this to
falseto apply domain updates immediately. The default istrue, except for domains that includeExprRefs, which default tofalseunless overridden.Default value:
true, exceptfalseforExprRef-driven domains. exponent- Type: number
The exponent of the
powscale. interpolate- Type:
"rgb"|"lab"|"hcl"|"hsl"|"hsl-long"|"hcl-long"|"cubehelix"|"cubehelix-long"| ScaleInterpolateParamsThe interpolation method for range values. By default, a general interpolator for numbers, dates, strings and colors (in HCL space) is used. For color ranges, this property allows interpolation in alternative color spaces. Legal values include
rgb,hsl,hsl-long,lab,hcl,hcl-long,cubehelixandcubehelix-long('-long' variants use longer paths in polar coordinate spaces). If object-valued, this property accepts an object with a string-valued type property and an optional numeric gamma property applicable to rgb and cubehelix interpolators. For more, see the d3-interpolate documentation.Default value:
hcl name- Type: string
The name of the scale. Names are optional but allow the scales to be referenced and found with the API.
nice- Type: boolean | number | object
Extending the domain so that it starts and ends on nice round values. This method typically modifies the scale’s domain, and may only extend the bounds to the nearest round value. Nicing is useful if the domain is computed from data and may be irregular. For example, for a domain of [0.201479…, 0.996679…], a nice domain might be [0.2, 1.0].
For quantitative scales such as linear,
nicecan be either a boolean flag or a number. Ifniceis a number, it will represent a desired tick count. This allows greater control over the step size used to extend the bounds, guaranteeing that the returned ticks will exactly cover the domain.Default value:
truefor unbinned quantitative fields;falseotherwise. numberingOffset- Type: number
The numbering offset used when formatting tick labels on index and locus scales.
Default value:
0 padding- Type: number
For continuous scales, expands the scale domain to accommodate the specified number of pixels on each of the scale range. The scale range must represent pixels for this parameter to function as intended. Padding adjustment is performed prior to all other adjustments, including the effects of the
zero,nice,domainMin, anddomainMaxproperties.For band scales, shortcut for setting
paddingInnerandpaddingOuterto the same value.For point scales, alias for
paddingOuter.Default value: For continuous scales, derived from the scale config's
continuousPadding. For band and point scales, seepaddingInnerandpaddingOuter. By default, Vega-Lite sets padding such that width/height = number of unique values * step. paddingInner- Type: number
The inner padding (spacing) within each band step of band scales, as a fraction of the step size. This value must lie in the range [0,1].
For point scale, this property is invalid as point scales do not have internal band widths (only step sizes between bands).
Default value: derived from the scale config's
bandPaddingInner. paddingOuter- Type: number
The outer padding (spacing) at the ends of the range of band and point scales, as a fraction of the step size. This value must lie in the range [0,1].
Default value: derived from the scale config's
bandPaddingOuterfor band scales andpointPaddingfor point scales. By default, Vega-Lite sets outer padding such that width/height = number of unique values * step. range- Type: {'anyOf': [{'type': 'number'}, {'type': 'string'}, {'$ref': '#/definitions/ExprRef'}]}[] | string
The range of the scale. One of:
- A string indicating a pre-defined named scale range (e.g., example,
"symbol", or"diverging").- For continuous scales, two-element array indicating minimum and maximum values, or an array with more than two entries for specifying a piecewise scale. Array elements may also be expression references.
- For discrete and discretizing scales, an array of desired output values. Array elements may also be expression references.
Notes:
1) For color scales you can also specify a color
schemeinstead ofrange.2) Any directly specified
rangeforxandychannels will be ignored. Range can be customized via the view's corresponding size (widthandheight). reverse- Type: boolean
If true, reverses the order of the scale range.
Default value:
false. round- Type: boolean
If
true, rounds numeric output values to integers. This can be helpful for snapping to the pixel grid.Default value:
false. scheme- Type: string | SchemeParams
A string indicating a color scheme name (e.g.,
"category10"or"blues") or a scheme parameter object.Discrete color schemes may be used with discrete or discretizing scales. Continuous color schemes are intended for use with color scales.
For the full list of supported schemes, please refer to the Vega Scheme reference.
type- Type:
"null"|"linear"|"log"|"pow"|"sqrt"|"symlog"|"identity"|"sequential"|"quantize"|"threshold"|"ordinal"|"point"|"band"|"index"|"locus"The type of scale. Vega-Lite supports the following categories of scale types:
1) Continuous Scales -- mapping continuous domains to continuous output ranges (
"linear","pow","sqrt","symlog","log","time","utc".2) Discrete Scales -- mapping discrete domains to discrete (
"ordinal") or continuous ("band"and"point") output ranges.3) Discretizing Scales -- mapping continuous domains to discrete output ranges
"bin-ordinal","quantile","quantize"and"threshold".Default value: please see the scale type table.
zero- Type: boolean
If
true, ensures that a zero baseline value is included in the scale domain.Default value:
truefor x and y channels if the quantitative field is not binned and no customdomainis provided;falseotherwise.Note: Log, time, and utc scales do not support
zero. zoom- Type: boolean | ZoomParams
If
trueand the scale is used on a positional channel, it can bee zoomed and translated interactively.
ScaleInterpolate¶
Type: "rgb" | "lab" | "hcl" | "hsl" | "hsl-long" | "hcl-long" | "cubehelix" | "cubehelix-long"
ScaleInterpolateParams¶
gamma- Type: number
TODO
typeRequired- Type: string
TODO
ScaleType¶
Type: "null" | "linear" | "log" | "pow" | "sqrt" | "symlog" | "identity" | "sequential" | "quantize" | "threshold" | "ordinal" | "point" | "band" | "index" | "locus"
SchemeParams¶
count- Type: number
The number of colors to use in the scheme. This can be useful for scale types such as
"quantize", which use the length of the scale range to determine the number of discrete bins for the scale domain. extent- Type: array
The extent of the color range to use. For example
[0.2, 1]will rescale the color scheme such that color values in the range [0, 0.2) are excluded from the scheme. nameRequired- Type: string
A color scheme name for ordinal scales (e.g.,
"category10"or"blues").For the full list of supported schemes, please refer to the Vega Scheme reference.
SearchDef¶
Type: FieldDefWithoutScale | FieldDefWithoutScale[]
SecondaryChromPosDef¶
axis- Type: GenomeAxis | null
An object defining properties of axis's gridlines, ticks and labels. If
null, the axis for the encoding channel will be removed.Default value: If undefined, default axis properties are applied.
See also:
axisdocumentation. band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. chromRequired- Type: FieldName
The field having the chromosome or contig.
description- Type: string
A description of the encoded position. Can be used for documentation and to explain the meaning of the channel mapping.
domainInert- Type: boolean
Whether the field or evaluated expr should be excluded from the scale's domain. Prefer the view-level
domainInertwhen an entire subtree should be excluded.Default value:
false offset- Type: number
An offset or offsets that allow for adjusting the numbering base. The offset is subtracted from the positions.
GenomeSpy uses internally zero-based indexing with half-open intervals. UCSC-based formats (BED, etc.) generally use this scheme. However, for example, VCF files use one-based indexing and must be adjusted by setting the offset to
1.Default:
0 pos- Type: FieldName
The field having an intra-chromosomal position.
title- Type: string | null
A title for the field. If
null, the title will be removed.
SecondaryPositionalChannel¶
Type: "x2" | "y2"
SelectionExtent¶
Type: "auto" | "view" | "container"
SelectionInitIntervalMapping¶
x- Type: array
TODO
y- Type: array
TODO
SelectionType¶
Type: "point" | "interval"
SeparatorProps¶
buildIndex- Type: boolean
Whether the x channel should build an index for efficient subset rendering. If omitted, GenomeSpy enables indexing automatically for positional x encodings.
clip- Type: boolean |
"x"|"y"|"never"Controls whether the mark is clipped to the UnitView's rectangle. The values
"x"and"y"clip only in the corresponding screen-space direction. Inherited clipping from parent containers still applies unless"never"is used.Default value: the direction of zoomable positional scales
color- Type: string | ExprRef
Color of the mark. Affects either
fillorstroke, depending on thefilledproperty. cullByVisibleRange- Type: boolean |
"x"|"y"Hide point-like mark instances whose anchor falls outside the inherited visible range in the given screen-space direction.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is over the mark. Mark cursor takes precedence over enclosing view cursors.
Default value: browser default
includePlotMargin- Type: boolean
Whether separators extend into the plot margin (axes/padding) around the grid.
Default value:
true minBufferSize- Type: number
Minimum size for WebGL buffers (number of data items). Allows for using
bufferSubData()to update graphics.This property is intended for internal use.
minLength- Type: number | ExprRef
The minimum stroke length in pixels. Use this property to ensure that very short strokes remain visible even when the user zooms out.
Default value:
0 opacity- Type: number | ExprRef
Opacity of the mark. Affects
fillOpacityorstrokeOpacity, depending on thefilledproperty. size- Type: number | ExprRef
Stroke width of
"link"and"rule"marks in pixels, the area of the bounding square of"point"mark, or the font size of"text"mark. strokeCap- Type:
"butt"|"square"|"round"| ExprRefThe style of stroke ends. Available choices:
"butt","round", and"square".Default value:
"butt" strokeDash- Type: array
An array of of alternating stroke and gap lengths or
nullfor solid strokes.Default value:
null strokeDashOffset- Type: number
An offset for the stroke dash pattern.
Default value:
0 style- Type: string | string[]
Named style reference(s) resolved from
config.style. If an array is provided, later styles override earlier ones. tooltip- Type: HandledTooltip | null | boolean
Tooltip handler. If
null, no tooltip is shown. If string, specifies the tooltip handler to use. x- Type: number | ExprRef
Position on the x axis.
x2- Type: number | ExprRef
The secondary position on the x axis.
xOffset- Type: number
Offsets of the
xandx2coordinates in pixels. The offset is applied after the viewport scaling and translation.Default value:
0 y- Type: number | ExprRef
Position on the y axis.
y2- Type: number | ExprRef
The secondary position on the y axis.
yOffset- Type: number
Offsets of the
yandy2coordinates in pixels. The offset is applied after the viewport scaling and translation.Default value:
0 zindex- Type: number
Z-order of the separator relative to the view content.
Values greater than
0render after the view marks. Values less than or equal to0render before the marks.Default value:
0
SequenceGenerator¶
description- Type: string
A description of the data source. Can be used for documentation and to explain the role of the generated data in the visualization.
name- Type: string
Provide a placeholder name and bind data at runtime.
sequenceRequired- Type: SequenceParams
Generate a sequence of numbers.
SequenceParams¶
as- Type: FieldName | ExprRef
The name of the generated sequence field.
Default value:
"data" startRequired- Type: number | ExprRef
The starting value of the sequence (inclusive).
step- Type: number | ExprRef
The step value between sequence entries.
Default value:
1 stopRequired- Type: number | ExprRef
The ending value of the sequence (exclusive).
ShapeDef¶
Type: FieldOrDatumDefWithCondition
SingleUrlSourceRef¶
Type: string | ExprRef | UrlTemplate
SortOrder¶
Type: "ascending" | "descending"
StringDatumDef¶
band- Type: number
Relative position on band scale. For example, the marks will be positioned at the beginning of the band if set to
0, and at the middle of the band if set to0.5. datum- Type: Scalar | ExprRef
A constant value in data domain.
description- Type: string
A description of the encoded datum. Can be used for documentation and to explain the meaning of the channel mapping.
format- Type: string
When used with the default
"number"format type, the text formatting pattern for labels of guides (axes, legends, headers) and text marks.- If the format type is
"number"(e.g., for quantitative fields), this is D3's number format pattern.See the format documentation for more examples.
resolutionChannel- Type:
"x"|"y"|"x2"|"y2"|"color"|"fill"|"stroke"|"opacity"|"fillOpacity"|"strokeOpacity"|"strokeWidth"|"size"|"shape"|"direction"|"angle"|"dx"|"dy"An alternative channel for scale resolution.
This is mainly for internal use and allows using
colorchannel to resolvefillandstrokechannels under certain circumstances. scale- Type: Scale | null
An object defining properties of the channel's scale, which is the function that transforms values in the data domain (numbers, dates, strings, etc) to visual values (pixels, colors, sizes) of the encoding channels.
If
null, the scale will be disabled and the data value will be directly encoded.Default value: If undefined, default scale properties are applied.
See also:
scaledocumentation. title- Type: string | null
A title for the field. If
null, the title will be removed. type- Type:
"quantitative"|"ordinal"|"nominal"|"index"|"locus"TODO
StringFieldDef¶
Type: object | object
TextDef¶
Type: object | object | StringDatumDef | ExprDef | ValueDef
TitleAnchor¶
Type: None | start | middle | end
TitleFrame¶
Type: "bounds" | "group"
TitleOrient¶
Type: "none" | "left" | "right" | "top" | "bottom"
Tooltip¶
Type: HandledTooltip | null | boolean
TooltipDef¶
Type: object | object | StringDatumDef | ExprDef | ValueDef
TransformParams¶
Type: AlignmentMismatchesParams | AggregateParams | CollectParams | CoverageParams | CoordinateLookupParams | CrossParams | FlattenDelimitedParams | FormulaParams | LookupParams | ExprFilterParams | SelectionFilterParams | FilterScoredLabelsParams | FlattenParams | FlattenCompressedExonsParams | FlattenCigarParams | FlattenSequenceParams | IdentifierParams | LinearizeGenomicCoordinateParams | MeasureTextParams | TruncateTextParams | PackLegendLabelsParams | MergeFacetsParams | PileupParams | ProjectParams | RegexExtractParams | RegexFoldParams | SampleParams | SetIntersectionParams | StackParams | WindowParams
TransitionedValueParameter¶
bind- Type: BindCheckbox | BindRadioSelect | BindRange | BindInput
Binds the parameter to an external input element such as a slider, selection list or radio button group.
description- Type: string
A description of the parameter. Can be used for documentation and to explain the meaning of the control or selection.
nameRequired- Type: string
A unique name for the variable parameter. Parameter names should be valid JavaScript identifiers: they should contain only alphanumeric characters (or "$", or "_") and may not start with a digit. Reserved keywords that may not be used as parameter names are: "datum".
persist- Type: boolean
Whether the parameter should be persisted in bookmarks and provenance.
This primarily affects GenomeSpy App behavior. Set to
falsefor ephemeral params (e.g., hover selections) or when the selection cannot be persisted due to missingencoding.key.Default value:
true transitionRequired- Type: ParamTransition
Smoothly follows numeric target values.
valueRequired- Type: number
The finite numeric initial target value of the transitioned parameter.
TruncateTextParams¶
as- Type: string
The output field where the truncated text is written.
Default: Same as
field. description- Type: string
A description of the transform step. Can be used for documentation and agent context.
ellipsis- Type: string
Text appended after truncation.
Default:
"...". fieldRequired- Type: string (field name)
The field that contains the text to be truncated.
font- Type: string
The font typeface. Uses the same asynchronously loaded SDF fonts as the
"text"mark.Default:
"Lato" fontSizeRequired- Type: number
The font size in pixels.
fontStyle- Type:
"normal"|"italic"The font style. Valid values:
"normal"and"italic".Default:
"normal" fontWeight- Type: number |
"thin"|"light"|"regular"|"normal"|"medium"|"bold"|"black"The font weight.
Default:
"regular" limit- Type: number
Maximum text width in pixels.
Type¶
Type: "quantitative" | "ordinal" | "nominal" | "index" | "locus"
TypeForShape¶
Type: "ordinal" | "nominal"
UrlGenomeConfig¶
nameRequired- Type: string
Name of the genome assembly, e.g.,
hg19orhg38. urlRequired- Type: string
A URL to a
chrom.sizesfile, which is a tab-separated file with two columns: the sequence name and its size.You may want to strip alternative loci, haplotypes, and other non-canonical contigs from the file.
Example:
"https://genomespy.app/data/genomes/hg19/chrom.sizes"
UrlGenomeDefinition¶
urlRequired- Type: string
A URL to a
chrom.sizesfile, which is a tab-separated file with two columns: the sequence name and its size.You may want to strip alternative loci, haplotypes, and other non-canonical contigs from the file.
Example:
"https://genomespy.app/data/genomes/hg19/chrom.sizes"
UrlList¶
type- Type: string
The format of the data in the list. If the type is
"json", the list is expected to be an array of strings. If the type is"csv"or"tsv", the list is expected to be a table with a single column namedurl.Default value:
"txt" urlsFromFileRequired- Type: string
A URL that returns a list of URLs to load the data set. The URLs in the list can be absolute or relative to the URL of the list.
UrlSourceRef¶
Type: string | string[] | ExprRef | UrlList | UrlTemplate
VConcatSpec¶
axes- Type: object
Defines properties for axis resolutions used by this view subtree.
Use this when a composed view shares an axis across child views and the axis settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
baseUrl- Type: string
The base URL for relative URL data sources and URL imports. The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.
config- Type: GenomeSpyConfig
Configures defaults for this view subtree.
Properties in child views override properties inherited from ancestors.
cursor- Type: string | ExprRef
Mouse cursor shown while the pointer is inside the view. The deepest matching cursor wins: mark cursor first, then the pointed view, then ancestor views outward toward the root.
Default value: browser default
data- Type: UrlData | InlineData | NamedData | DynamicCallbackData | LazyData | Generator
Specifies a data source. If omitted, the data source is inherited from the parent view.
datasets- Type: object
Named datasets available to this view and its descendants.
A descendant declaration with the same name shadows this declaration. Declare named data here to establish reliable lexical scope and enable scoped runtime updates.
description- Type: string | string[]
A description of the view. Can be used for documentation. The description of the top-level view is shown in the toolbar of the GenomeSpy App.
domainInert- Type: boolean
If true, this view and its descendants do not contribute to scale domains. Child views inherit this flag automatically.
Default value:
false encoding- Type: Encoding
Specifies how data are encoded using the visual channels.
height- Type: SizeDef | number | Step | ExprRef |
"container"Height of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default value:
"container" legends- Type: object
Defines properties for legend resolutions used by this view subtree.
Use this when a composed view shares a legend across child views and the legend settings belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
name- Type: string
An explicit name used to address the view. It is recommended to keep names unique among siblings. In the App (where view state is bookmarkable), the name must be unique within its import scope for views with configurable visibility, etc.
overhang- Type: OverhangConfig
Controls whether external overhang on each edge reserves layout space. Setting an edge to false lets axes, titles, legends, or custom view overhang overlap nearby content while remaining visible.
Default value: all edges reserve overhang
padding- Type: Paddings | number
Padding applied to the view. Accepts either a number representing pixels or an object specifying separate paddings for each edge.
Examples: -
padding: 10-padding: { top: 10, right: 20, bottom: 10, left: 20 }Default value:
0 params- Type: array
Dynamic variables that parameterize a visualization.
resolve- Type: object
Specifies how scales, axes, and legends are resolved in the view hierarchy.
If legend resolution is not configured explicitly, it follows the corresponding scale resolution.
scales- Type: object
Defines properties for scale resolutions used by this view subtree.
Use this when a composed view shares a scale across child views and the scale settings, such as the visible domain, belong to the composed view rather than an individual encoding. An ancestor declaration shadows the whole declaration of a descendant that targets the same resolution. Declarations in separate sibling subtrees are ambiguous and cause an error.
separator- Type: boolean | SeparatorProps
Draws separator rules between visible child views. The separators are centered within the spacing gaps and do not affect layout.
If
true, the defaults are equivalent to:{"type":"rule","size":1,"color":"#ccc","opacity":1,"strokeDash":[4,4],"strokeCap":"butt"}UseincludePlotMarginto control whether the separators extend into the plot margin.Default value:
false spacing- Type: number
The gap between the views, in pixels.
templates- Type: object
TODO
title- Type: string | Title
View title.
transform- Type: array
An array of transformations applied to the data before visual encoding.
vconcatRequired- Type: array
TODO
viewportHeight- Type: SizeDef | number | ExprRef |
"container"Optional viewport height of the view. If the view size exceeds the viewport height, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same asheight) viewportWidth- Type: SizeDef | number | ExprRef |
"container"Optional viewport width of the view. If the view size exceeds the viewport width, it will be shown with scrollbars. This property implicitly enables clipping. If an expression reference is provided, it must resolve to a number or
"container".Default:
null(same aswidth) visible- Type: boolean
The default visibility of the view. An invisible view is removed from the layout and not rendered. For context, see toggleable view visibility.
Default:
true width- Type: SizeDef | number | Step | ExprRef |
"container"Width of the view. If a number, it is interpreted as pixels. If an expression reference is provided, it must resolve to a number or
"container". Check child sizing for details.Default:
"container"
ValueParameter¶
Type: PlainValueParameter | TransitionedValueParameter
VcfDataFormat¶
parse- Type: Parse | null
If set to
null, disable type inference based on the spec and only use type inference based on the data. Alternatively, a parsing directive object can be provided for explicit data types. Each property of the object corresponds to a field name, and the value to the desired data type (one of"number","boolean","date", or null (do not parse the field)). For example,"parse": {"modified_on": "date"}parses themodified_onfield in each input record a Date value.For
"date", we parse data based using Javascript'sDate.parse(). For Specific date formats can be provided (e.g.,{foo: "date:'%m%d%Y'"}), using the d3-time-format syntax. UTC date format parsing is supported similarly (e.g.,{foo: "utc:'%m%d%Y'"}). See more about UTC time
ViewBackground¶
fill- Type: string
Fill color of the view background.
fillOpacity- Type: number
Opacity of the view background fill.
shadowBlur- Type: number | ExprRef
The blur radius of the drop shadow in pixels. Higher values produce a more diffuse shadow.
Default value:
0 shadowColor- Type: string | ExprRef
The color of the drop shadow. Any valid CSS color string is allowed.
Default value:
"black" shadowOffsetX- Type: number | ExprRef
The horizontal offset of the drop shadow in pixels. Positive values move the shadow to the right.
Default value:
0 shadowOffsetY- Type: number | ExprRef
The vertical offset of the drop shadow in pixels. Positive values move the shadow downward.
Default value:
0 shadowOpacity- Type: number | ExprRef
The opacity of the drop shadow. Value between
0(fully transparent) and1(fully opaque).Default value:
0(disabled) stroke- Type: string
Stroke color of the view background.
strokeOpacity- Type: number
Opacity of the view background stroke.
strokeWidth- Type: number
Stroke width of the view background border.
strokeZindex- Type: number
Z-order of the background stroke relative to the view content.
Values greater than
0render after the view marks. Values less than or equal to0render before the marks.Default value:
0, or10when the view content is clipped or scrollable. style- Type: string | string[]
Named style reference(s) resolved from
config.style. If an array is provided, later styles override earlier ones.Default value:
"cell" zindex- Type: number
Z-order of the background fill relative to the view content.
Values greater than
0render after the view marks. Values less than or equal to0render before the marks.Default value:
0
ViewOpacityDef¶
Type: number | DynamicOpacity | ExprRef
ViewSpec¶
Type: UnitSpec | LayerSpec | MultiscaleSpec | VConcatSpec | HConcatSpec | ConcatSpec
WindowOnlyOp¶
Type: "row_number" | "rank" | "dense_rank" | "percent_rank" | "cume_dist" | "ntile" | "lag" | "lead" | "first_value" | "last_value" | "nth_value" | "prev_value" | "next_value"
WindowOp¶
Type: "row_number" | "rank" | "dense_rank" | "percent_rank" | "cume_dist" | "ntile" | "lag" | "lead" | "first_value" | "last_value" | "nth_value" | "prev_value" | "next_value" | "count" | "valid" | "sum" | "min" | "max" | "mean" | "q1" | "median" | "q3" | "variance"