Chart Cells

Visualize your data directly from a dataframe!

Chart cells are in currently in beta and we'll be adding functionality over the next several weeks. If you run into any issues or have feedback on what you'd like to see reach out to[email protected]!

To create a plot, first add a chart cell to your project and then select the DataFrame you wish to visualize from the "Data" dropdown menu. From there, you can assign columns to variables and configure the visual elements of the chart. See the section below for more details on chart configuration.

Under the hood we're using Vega, a high-level grammar of interactive graphics. Because our chart cells are built off of this library we use much of the terminology of the Vega ecosystem. Learn more about Vega's grammar of graphics system here.

Check out this video demo for how to quickly visualize your data with chart cells

Chart Cell Demo! — Watch Video

Chart Configuration

Once you've created a chart cell you can configure it in the following ways:

Data: Specify the DataFrame you'd like to visualize.

Mark: Select the type of visualization you want. Currently we support Bar, Point, and Line plots. Mark details can be further customized by clicking the cog icon.

  • Tooltips: True/False to display details of data points on mouse over

  • Filled: True/False to fill marks.

  • Orientation (Line & Bar type only): Horizontal or vertical plot orientation.

  • Interpolate (Line type only): Type of interpolation to use. See here for details on options.

  • Point (Line type only): True/False to overlay points on a line.

  • Shape (Point type only): Choose the default shape of points.

  • Size: (Point type only): Choose the default size of points.

X-axis & Y-axis: Select the columns you'd like to encode to the x and y axis. The data encoded to each axis can be further customized by clicking the cog icon.

  • Type: Set the data type of the column that is linked to each axis. Data types are:

    • Quantitative: Expresses some kind of quantity, typically this is numerical data.

    • Temporal: Supported data are date-times and times such as "2015-03-07 12:32:17", "17:01", "2015-03-16". "2015", 1552199579097 (timestamp).

    • Ordinal: Represents data with ranked order. Unlike with quantitative data, there is no relative degree of difference between ranks.

    • Nominal: Also known as categorical data. Values are differentiated based on their names or categories. Gender, species, & genre are examples of nominal data.

  • Aggregate: You can apply aggregations to the data encoded to each axis. Full list of supported aggregation methods here (not including argmin and argmax).

Depending on the mark type you select some further encoding options become available.

Color: Select a column from the identified DataFrame to encode mark color on your plot. For example, in the chart above data points are color coded by species of iris.

Size: Set the size of the marks in your chart according to the values in a column from the identified DataFrame.

Shape (Point charts only): Set the shape of the marks in your chart according to the values in a column from the identified DataFrame. For example, in the chart above data point shape is coded by species of iris.

Dash (Line type only): Select a column from the identified DataFrame to encode line type on your plot.

Detail (Line type only): Group lines by a field without mapping to any visual properties (e.g lines of all the same color, width, etc)

Duplicate Chart Cell as Code

Find yourself doing this often? Let us know what you'd like to see in standard Chart cells by reaching out to[email protected]!

If you are familiar with Altair and/or Vega (the libraries we leverage to generate Chart cells) you are welcome to "eject" from a visually configured Chart cell and customize your charts more deeply using the Vega-lite grammar.

Every Chart cell has a "Duplicate as code cell" option in the dropdown on the upper right. Selecting this option will add a new Code cell to the Project that contains the code used to generate the chart. You will no longer be able to leverage the visual configuration options described above, but you can get very detailed with your customization.

The "Duplicate as code cell" option