altair.VConcatChart#

class altair.VConcatChart(vconcat=Undefined, autosize=Undefined, background=Undefined, bounds=Undefined, center=Undefined, config=Undefined, data=Undefined, datasets=Undefined, description=Undefined, name=Undefined, padding=Undefined, params=Undefined, resolve=Undefined, spacing=Undefined, title=Undefined, transform=Undefined, usermeta=Undefined, **kwds)#

一个垂直拼接构面的图表。

__init__(vconcat=Undefined, autosize=Undefined, background=Undefined, bounds=Undefined, center=Undefined, config=Undefined, data=Undefined, datasets=Undefined, description=Undefined, name=Undefined, padding=Undefined, params=Undefined, resolve=Undefined, spacing=Undefined, title=Undefined, transform=Undefined, usermeta=Undefined, **kwds)#

参考 TopLevelVConcatSpec TopLevelVConcatSpec 模式封装。

参数
vconcatSequence[dict, FacetSpec, LayerSpec, RepeatSpec, FacetedUnitSpec, LayerRepeatSpec, NonNormalizedSpec, NonLayerRepeatSpec, ConcatSpecGenericSpec, HConcatSpecGenericSpec, VConcatSpecGenericSpec]

要垂直连接并放在一列中的视图列表。

autosizedict, AutosizeType, AutoSizeParams, Literal[‘pad’, ‘none’, ‘fit’, ‘fit-x’, ‘fit-y’]

如何确定可视化图表的大小。如果是字符串,应为 "pad""fit""none" 之一。对象值还可以额外指定内容大小和自动调整大小的参数。

默认值pad

backgroundstr, dict, Color, ExprRef, HexColor, ColorName, Literal[‘black’, ‘silver’, ‘gray’, ‘white’, ‘maroon’, ‘red’, ‘purple’, ‘fuchsia’, ‘green’, ‘lime’, ‘olive’, ‘yellow’, ‘navy’, ‘blue’, ‘teal’, ‘aqua’, ‘orange’, ‘aliceblue’, ‘antiquewhite’, ‘aquamarine’, ‘azure’, ‘beige’, ‘bisque’, ‘blanchedalmond’, ‘blueviolet’, ‘brown’, ‘burlywood’, ‘cadetblue’, ‘chartreuse’, ‘chocolate’, ‘coral’, ‘cornflowerblue’, ‘cornsilk’, ‘crimson’, ‘cyan’, ‘darkblue’, ‘darkcyan’, ‘darkgoldenrod’, ‘darkgray’, ‘darkgreen’, ‘darkgrey’, ‘darkkhaki’, ‘darkmagenta’, ‘darkolivegreen’, ‘darkorange’, ‘darkorchid’, ‘darkred’, ‘darksalmon’, ‘darkseagreen’, ‘darkslateblue’, ‘darkslategray’, ‘darkslategrey’, ‘darkturquoise’, ‘darkviolet’, ‘deeppink’, ‘deepskyblue’, ‘dimgray’, ‘dimgrey’, ‘dodgerblue’, ‘firebrick’, ‘floralwhite’, ‘forestgreen’, ‘gainsboro’, ‘ghostwhite’, ‘gold’, ‘goldenrod’, ‘greenyellow’, ‘grey’, ‘honeydew’, ‘hotpink’, ‘indianred’, ‘indigo’, ‘ivory’, ‘khaki’, ‘lavender’, ‘lavenderblush’, ‘lawngreen’, ‘lemonchiffon’, ‘lightblue’, ‘lightcoral’, ‘lightcyan’, ‘lightgoldenrodyellow’, ‘lightgray’, ‘lightgreen’, ‘lightgrey’, ‘lightpink’, ‘lightsalmon’, ‘lightseagreen’, ‘lightskyblue’, ‘lightslategray’, ‘lightslategrey’, ‘lightsteelblue’, ‘lightyellow’, ‘limegreen’, ‘linen’, ‘magenta’, ‘mediumaquamarine’, ‘mediumblue’, ‘mediumorchid’, ‘mediumpurple’, ‘mediumseagreen’, ‘mediumslateblue’, ‘mediumspringgreen’, ‘mediumturquoise’, ‘mediumvioletred’, ‘midnightblue’, ‘mintcream’, ‘mistyrose’, ‘moccasin’, ‘navajowhite’, ‘oldlace’, ‘olivedrab’, ‘orangered’, ‘orchid’, ‘palegoldenrod’, ‘palegreen’, ‘paleturquoise’, ‘palevioletred’, ‘papayawhip’, ‘peachpuff’, ‘peru’, ‘pink’, ‘plum’, ‘powderblue’, ‘rosybrown’, ‘royalblue’, ‘saddlebrown’, ‘salmon’, ‘sandybrown’, ‘seagreen’, ‘seashell’, ‘sienna’, ‘skyblue’, ‘slateblue’, ‘slategray’, ‘slategrey’, ‘snow’, ‘springgreen’, ‘steelblue’, ‘tan’, ‘thistle’, ‘tomato’, ‘turquoise’, ‘violet’, ‘wheat’, ‘whitesmoke’, ‘yellowgreen’, ‘rebeccapurple’]

用作整个视图背景的 CSS 颜色属性。

默认值: "white"

boundsLiteral[‘full’, ‘flush’]

用于确定子图范围的边界计算方法。可以是 full(默认)或 flush 之一。

  • 如果设置为 full,将使用计算出的整个边界(包括轴、标题和图例)。

  • 如果设置为 flush,则仅使用子视图指定的宽度和高度值。flush 设置在尝试将没有轴或图例的子图放入统一的网格结构时非常有用。

默认值: "full"

centerbool

布尔标志,指示子视图是否应相对于其各自的行或列居中。

默认值: false

configdict, Config

Vega-Lite 配置对象。此属性只能在规范的顶层定义。

datadict, Data, UrlData, Generator, NamedData, DataSource, InlineData, SphereGenerator, SequenceGenerator, GraticuleGenerator, None

描述数据源的对象。设置为 null 将忽略父级的数据源。如果未设置数据,则从父级继承。

datasetsdict, Datasets

用于命名数据集的全局数据存储。这是名称到内联数据集的映射。可以是对象或原始值数组,或字符串。原始值数组将被作为具有 data 属性的对象摄取。

descriptionstr

此标记的描述,用于注释目的。

namestr

可视化图表的名称,供以后参考。

paddingdict, float, ExprRef, Padding

默认的可视化图表填充,以像素为单位,从可视化画布边缘到数据矩形。如果为数字,则指定所有侧面的填充。如果为对象,值应采用 {"left": 5, "top": 5, "right": 5, "bottom": 5} 格式来指定可视化图表每一侧的填充。

默认值5

paramsSequence[dict, TopLevelParameter, VariableParameter, TopLevelSelectionParameter]

参数化可视化图表的动态变量或选择。

resolvedict, Resolve

视图组合规范的比例、轴和图例解析。

spacingfloat

连接操作符的子视图之间的像素间距。

默认值10

titlestr, dict, Text, Sequence[str], TitleParams

图表的标题。

transformSequence[dict, Transform, BinTransform, FoldTransform, LoessTransform, PivotTransform, StackTransform, ExtentTransform, FilterTransform, ImputeTransform, LookupTransform, SampleTransform, WindowTransform, DensityTransform, FlattenTransform, QuantileTransform, TimeUnitTransform, AggregateTransform, CalculateTransform, RegressionTransform, JoinAggregateTransform]

数据转换数组,例如过滤和新字段计算。

usermetadict, Dict

将传递给 Vega 的可选元数据。此对象完全被 Vega 和 Vega-Lite 忽略,可用于自定义元数据。

$schemastr

指向 Vega-Lite 规范的 JSON 模式的 URL。除非您有理由更改此项,否则请使用 https://vega.github.io/schema/vega-lite/v5.json。设置 $schema 属性允许支持 JSON 模式的编辑器进行自动验证和自动完成。

方法

__init__([vconcat, autosize, background, ...])

参考 TopLevelVConcatSpec TopLevelVConcatSpec 模式封装。

add_params(*params)

向图表添加一个或多个参数。

add_selection(*selections)

'add_selection' 已弃用。

configure([arc, area, aria, autosize, axis, ...])

参考 Config Config 模式封装。

configure_arc([align, angle, aria, ...])

参考 RectConfig RectConfig 模式封装。

configure_area([align, angle, aria, ...])

参考 AreaConfig AreaConfig 模式封装。

configure_axis([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisBand([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisBottom([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisDiscrete([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisLeft([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisPoint([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisQuantitative([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisRight([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisTemporal([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisTop([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisX([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisXBand([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisXDiscrete([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisXPoint([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisXQuantitative([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisXTemporal([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisY([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisYBand([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisYDiscrete([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisYPoint([aria, bandPosition, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisYQuantitative([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_axisYTemporal([aria, ...])

参考 AxisConfig AxisConfig 模式封装。

configure_bar([align, angle, aria, ...])

参考 BarConfig BarConfig 模式封装。

configure_boxplot([box, extent, median, ...])

参考 BoxPlotConfig BoxPlotConfig 模式封装。

configure_circle([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_concat([columns, spacing])

参考 CompositionConfig CompositionConfig 模式封装。

configure_errorband([band, borders, extent, ...])

参考 ErrorBandConfig ErrorBandConfig 模式封装。

configure_errorbar([extent, rule, size, ...])

参考 ErrorBarConfig ErrorBarConfig 模式封装。

configure_facet([columns, spacing])

参考 CompositionConfig CompositionConfig 模式封装。

configure_geoshape([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_header([format, formatType, ...])

参考 HeaderConfig HeaderConfig 模式封装。

configure_headerColumn([format, formatType, ...])

参考 HeaderConfig HeaderConfig 模式封装。

configure_headerFacet([format, formatType, ...])

参考 HeaderConfig HeaderConfig 模式封装。

configure_headerRow([format, formatType, ...])

参考 HeaderConfig HeaderConfig 模式封装。

configure_image([align, angle, aria, ...])

参考 RectConfig RectConfig 模式封装。

configure_legend([aria, clipHeight, ...])

参考 LegendConfig LegendConfig 模式封装。

configure_line([align, angle, aria, ...])

参考 LineConfig LineConfig 模式封装。

configure_mark([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_point([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_projection([center, clipAngle, ...])

参考 ProjectionConfig ProjectionConfig 模式封装。

configure_range([category, diverging, ...])

参考 RangeConfig RangeConfig 模式封装。

configure_rect([align, angle, aria, ...])

参考 RectConfig RectConfig 模式封装。

configure_rule([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_scale([bandPaddingInner, ...])

参考 ScaleConfig ScaleConfig 模式封装。

configure_selection([interval, point])

参考 SelectionConfig SelectionConfig 模式封装。

configure_square([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_text([align, angle, aria, ...])

参考 MarkConfig MarkConfig 模式封装。

configure_tick([align, angle, aria, ...])

参考 TickConfig TickConfig 模式封装。

configure_title([align, anchor, angle, ...])

参考 TitleConfig TitleConfig 模式封装。

configure_tooltipFormat([...])

参考 FormatConfig FormatConfig 模式封装。

configure_trail([align, angle, aria, ...])

参考 LineConfig LineConfig 模式封装。

configure_view([clip, continuousHeight, ...])

参考 ViewConfig ViewConfig 模式封装。

copy([deep, ignore])

返回对象的副本。

display([renderer, theme, actions])

在 Jupyter Notebook 或 JupyterLab 中显示图表。

from_dict(dct[, validate])

从字典表示构建类。

from_json(json_string[, validate])

从有效的 JSON 字符串实例化对象。

interactive([name, bind_x, bind_y])

使图表轴的比例尺具有交互性。

open_editor(*[, fullscreen])

使用默认浏览器在 Vega 图表编辑器中打开图表规范。

project([type, center, clipAngle, ...])

为图表添加地理投影。

properties(**kwargs)

设置图表的顶层属性。

repeat([repeat, row, column, layer, columns])

返回从当前图表构建的 RepeatChart。

resolve_axis([x, y])

参考 AxisResolveMap AxisResolveMap 模式封装。

resolve_legend([angle, color, fill, ...])

参考 LegendResolveMap LegendResolveMap 模式封装。

resolve_references([schema])

在对象模式或根模式的上下文中解析引用。

resolve_scale([angle, color, fill, ...])

参考 ScaleResolveMap ScaleResolveMap 模式封装。

save(fp[, format, ...])

将图表保存为多种格式的文件。

serve([ip, port, n_retries, files, ...])

'serve' 已弃用。

show()

使用活动的渲染器显示图表。

to_dict([validate, format, ignore, context])

将图表转换为适用于 JSON 导出的字典。

to_html([base_url, output_div, ...])

将 Vega/Vega-Lite 规范嵌入到 HTML 页面中。

to_json([validate, indent, sort_keys, ...])

将图表转换为 JSON 字符串。

to_url(*[, fullscreen])

将图表转换为 URL,以便在 Vega 图表编辑器中打开图表规范。

transform_aggregate([aggregate, groupby])

向模式添加 AggregateTransform

transform_bin([as_, field, bin])

向模式添加 BinTransform

transform_calculate([as_, calculate])

向模式添加 CalculateTransform

transform_density(density[, as_, bandwidth, ...])

向规范添加 DensityTransform

transform_extent(extent, param)

向规范添加 ExtentTransform

transform_filter([predicate, empty])

向规范添加 FilterTransform

transform_flatten(flatten[, as_])

向模式添加 FlattenTransform

transform_fold(fold[, as_])

向规范添加 FoldTransform

transform_impute(impute, key[, frame, ...])

向模式添加 ImputeTransform

transform_joinaggregate([joinaggregate, groupby])

向模式添加 JoinAggregateTransform

transform_loess(on, loess[, as_, bandwidth, ...])

向规范添加 LoessTransform

transform_lookup([lookup, from_, as_, default])

向图表添加 DataLookupTransformSelectionLookupTransform

transform_pivot(pivot, value[, groupby, ...])

向图表添加 PivotTransform

transform_quantile(quantile[, as_, groupby, ...])

向图表添加 QuantileTransform

transform_regression(on, regression[, as_, ...])

向图表添加 RegressionTransform

transform_sample([sample])

向模式添加 SampleTransform

transform_stack(as_, stack, groupby[, ...])

向模式添加 StackTransform

transform_timeunit([as_, field, timeUnit])

向模式添加 TimeUnitTransform

transform_window([window, frame, groupby, ...])

向模式添加 WindowTransform

transformed_data([row_limit, exclude])

评估 VConcatChart 的转换。

validate(instance[, schema])

在根模式的上下文中根据类模式验证实例。

validate_property(name, value[, schema])

在根模式的上下文中根据属性模式验证属性。

属性

data