Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for each mark type #2607

Merged
merged 19 commits into from
Nov 4, 2022
Prev Previous commit
Next Next commit
circle subpage
  • Loading branch information
Hannah Barton committed May 26, 2022
commit b33e39719c7f90e6d6c8dfadf408b97c231be765
31 changes: 31 additions & 0 deletions doc/user_guide/marks/circle.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
.. currentmodule:: altair

.. _user-guide-circle-marks:

Circle
~~~~~~

``circle`` mark is similar to ``point`` mark, except that (1) the ``shape`` value is always set to ``circle`` (2) they are filled by default.

Scatterplot with Circle
^^^^^^^^^^^^^^^^^^^^^^^

Here is an example scatter plot with ``circle`` marks:

.. altair-plot::
import altair as alt
from vega_datasets import data

source = data.cars.url

alt.Chart(source).mark_circle().encode(
x = ('Horsepower:Q'),
y = ('Miles_per_Gallon:Q')
)

Circle Config
^^^^^^^^^^^^^

The ``circle`` property of the top-level ``config`` object sets the default properties for all circle marks. If mark property encoding channels are specified for marks, these config values will be overridden.

The circle config can contain any circle mark properties (except ``type``, ``style``, and ``clip``).