altair.SharedEncoding#
- class altair.SharedEncoding(angle=Undefined, color=Undefined, description=Undefined, detail=Undefined, fill=Undefined, fillOpacity=Undefined, href=Undefined, key=Undefined, latitude=Undefined, latitude2=Undefined, longitude=Undefined, longitude2=Undefined, opacity=Undefined, order=Undefined, radius=Undefined, radius2=Undefined, shape=Undefined, size=Undefined, stroke=Undefined, strokeDash=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, text=Undefined, theta=Undefined, theta2=Undefined, tooltip=Undefined, url=Undefined, x=Undefined, x2=Undefined, xError=Undefined, xError2=Undefined, xOffset=Undefined, y=Undefined, y2=Undefined, yError=Undefined, yError2=Undefined, yOffset=Undefined, **kwds)#
SharedEncoding schema wrapper.
- Parameters:
- angledict
- colordict
- descriptiondict
- detaildict,
FieldDefWithoutScale
, Sequence[dict,FieldDefWithoutScale
] Additional levels of detail for grouping data in aggregate views and in line, trail, and area marks without mapping data to a specific visual channel.
- filldict
- fillOpacitydict
- hrefdict
- keydict
- latitudedict
- latitude2dict
- longitudedict
- longitude2dict
- opacitydict
- orderdict,
OrderOnlyDef
,OrderFieldDef
,OrderValueDef
, Sequence[dict,OrderFieldDef
] Order of the marks.
For stacked marks, this
order
channel encodes stack order.For line and trail marks, this
order
channel encodes order of data points in the lines. This can be useful for creating a connected scatterplot. Settingorder
to{"value": null}
makes the line marks use the original order in the data sources.Otherwise, this
order
channel encodes layer order of the marks.
Note: In aggregate plots,
order
field should be ``aggregate``d to avoid creating additional aggregation grouping.- radiusdict
- radius2dict
- shapedict
- sizedict
- strokedict
- strokeDashdict
- strokeOpacitydict
- strokeWidthdict
- textdict
- thetadict
- theta2dict
- tooltipdict,
StringFieldDefWithCondition
,StringValueDefWithCondition
, Sequence[dict,StringFieldDef
], None The tooltip text to show upon mouse hover. Specifying
tooltip
encoding overrides the tooltip property in the mark definition.See the tooltip documentation for a detailed discussion about tooltip in Vega-Lite.
- urldict
- xdict
- x2dict
- xErrordict
- xError2dict
- xOffsetdict
- ydict
- y2dict
- yErrordict
- yError2dict
- yOffsetdict
- __init__(angle=Undefined, color=Undefined, description=Undefined, detail=Undefined, fill=Undefined, fillOpacity=Undefined, href=Undefined, key=Undefined, latitude=Undefined, latitude2=Undefined, longitude=Undefined, longitude2=Undefined, opacity=Undefined, order=Undefined, radius=Undefined, radius2=Undefined, shape=Undefined, size=Undefined, stroke=Undefined, strokeDash=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, text=Undefined, theta=Undefined, theta2=Undefined, tooltip=Undefined, url=Undefined, x=Undefined, x2=Undefined, xError=Undefined, xError2=Undefined, xOffset=Undefined, y=Undefined, y2=Undefined, yError=Undefined, yError2=Undefined, yOffset=Undefined, **kwds)#
Methods
__init__
([angle, color, description, ...])copy
([deep, ignore])Return a copy of the object.
from_dict
(dct[, validate])Construct class from a dictionary representation.
from_json
(json_string[, validate])Instantiate the object from a valid JSON string.
resolve_references
([schema])Resolve references in the context of this object's schema or root schema.
to_dict
([validate, ignore, context])Return a dictionary representation of the object.
to_json
([validate, indent, sort_keys, ...])Emit the JSON representation for this object as a string.
validate
(instance[, schema])Validate the instance against the class schema in the context of the rootschema.
validate_property
(name, value[, schema])Validate a property against property schema in the context of the rootschema.