Example representation: Workbook with a line chart (Beta)
This documentation describes one or more private beta features that are in development. Beta features are subject to quick, iterative changes; therefore the current user experience in the Sigma service can differ from the information provided in this page.
This page should not be considered official published documentation until Sigma removes this notice and the beta flag on the corresponding feature(s) in the Sigma service. For the full beta feature disclaimer, see Beta features.
If you are interested in joining a limited test group and enabling this feature in your Sigma organization, contact Support or reach out to your Account Executive.
This is an example representation of a workbook, created using the get a workbook representation endpoint. Representations like this one can be used to create a workbook from code using the create a workbook from a representation endpoint. Each page in this example library includes the code representation of the workbook and step-by-step instructions to create it in the Sigma UI.
Consult this example and others in the Workbook representation example library to:
- Troubleshoot the formatting of a particular feature in code representation
- Relate a feature from the Sigma UI to its representation in code
- Provide context to AI tools used to create workbooks from code
This example representation cannot be used as-is. All identifying details, such as IDs, names, and URLs, have been replaced with randomized ID values or generic substitutions. The format of these contents, like the length of ID values, is preserved for demonstrative purposes. However, this representation cannot be directly used without modification to the base URL, connection details, and more. For more information, see Create and manage workbooks from code.
System and user requirements
To complete the steps in this example, you must meet the user requirements listed below for creating the workbook in the UI and creating it from code.
The ability to create this workbook in the Sigma UI requires the following:
- You must be assigned an account type with the Create, edit, and publish workbooks permission enabled.
- You must have access to a connection to a data platform.
The ability to create a workbook from code requires the following:
- You must be assigned an account type with the Create, edit, and publish workbooks permission enabled.
- You must have developer credentials for the Sigma API. For more information, see Get started with the Sigma REST API.
This example uses a table from the Sigma Sample Connection. Your organization might have disabled access to the Sigma sample connection. If so, you can contact an admin to enable it, or use a table from another connection to follow along with this example.
Create the example workbook in the Sigma UI
This example shows a simple workbook with a single table element, sourced from a warehouse table, and a line chart.
To create this workbook in the Sigma UI:
-
Go to the Home page.
-
Select
Create new > Workbook.
A new workbook opens.
-
From the Add element bar, select Data > Table.
-
In the Select source modal, search for the table
TRIPSin theEXAMPLES.BIKESschema. -
Select the table to add it to the workbook.
The table appears in the workbook.
-
Select
Add child element > Chart.
A new bar chart element appears on the workbook canvas.
-
In the editor panel, select Properties and configure the chart with the following settings:
Option Setting Chart type Line X-axis Day of Start Date Y-axis Count of Id -
Select the down arrow
next to Day of Start Date to open the column details menu and select Truncate date > Month.
-
In the document header, select Save as.
-
Enter a name for the workbook, such as
line-chart. -
Select Save.
Get a code representation of this workbook
To get a representation of this workbook, follow the steps in Get the code representation of a workbook.
The code representation of this workbook appears like the following:
YAML representation
workbookId: 441c3b9b-6810-48ba-a0f2-36e17102b649
name: line-chart
url: https://aws-api.sigmacomputing.com/org-name/workbook/line-chart-e3fJ4ChD6R0N65vvII4ar
documentVersion: 3
latestDocumentVersion: 3
ownerId: Ipb0LILcSmxdd6uZFfy2EJLR6N2nr
folderId: 2cfd0815-2749-49b4-9a07-46684d13e7d0
createdBy: Ipb0LILcSmxdd6uZFfy2EJLR6N2nr
updatedBy: Ipb0LILcSmxdd6uZFfy2EJLR6N2nr
createdAt: '2026-04-20T20:09:53.640Z'
updatedAt: '2026-04-21T19:06:04.784Z'
schemaVersion: 1
pages:
- id: cyWhHmmqyl
name: Page 1
elements:
- id: 1jPqRYvgkg
kind: table
source:
connectionId: d6bfeea1-5da2-458c-9bcf-ec9400d24ceb
kind: warehouse-table
path:
- FUN
- BIKES
- TRIP
columns:
- id: dVHOY6UGZR
formula: '[TRIP/Id]'
- id: tFf2VZKI32
formula: '[TRIP/Duration]'
- id: eM75IAXijU
formula: '[TRIP/Start Date]'
- id: cZGxnVxxkh
formula: '[TRIP/Start Station Name]'
- id: SILXk3cs2g
formula: '[TRIP/Start Station Id]'
- id: JsyylJOYOc
formula: '[TRIP/End Date]'
- id: Ct2F3feoPR
formula: '[TRIP/End Station Name]'
- id: yLCRBDuh1F
formula: '[TRIP/End Station Id]'
- id: JVRRod6ojh
formula: '[TRIP/Bike Id]'
- id: V5BFSgRLQf
formula: '[TRIP/Subscription Type]'
- id: scIP88kjXi
formula: '[TRIP/Zip Code]'
order:
- dVHOY6UGZR
- tFf2VZKI32
- eM75IAXijU
- cZGxnVxxkh
- SILXk3cs2g
- JsyylJOYOc
- Ct2F3feoPR
- yLCRBDuh1F
- JVRRod6ojh
- V5BFSgRLQf
- scIP88kjXi
- id: xLjdrkDom2
kind: line-chart
source:
elementId: 1jPqRYvgkg
kind: table
columns:
- id: EyRpfDLcDG
formula: DateTrunc("month", [Start Date])
- id: E2i1kDnOsK
formula: Count([Id])
- id: ATTkk7PzOY
formula: '[TRIP/Id]'
- id: tzPL15PMZh
formula: '[TRIP/Duration]'
- id: ZcRynZxgBS
formula: '[TRIP/Start Date]'
- id: Bq87FWheam
formula: '[TRIP/Start Station Name]'
- id: XiJtntl3Cu
formula: '[TRIP/Start Station Id]'
- id: 2Bqvchcc7L
formula: '[TRIP/End Date]'
- id: OghSYFEqzp
formula: '[TRIP/End Station Name]'
- id: 02A2c1H2gt
formula: '[TRIP/End Station Id]'
- id: YCey3mSSAS
formula: '[TRIP/Bike Id]'
- id: wepQywWo3R
formula: '[TRIP/Subscription Type]'
- id: fTNGVjLMZB
formula: '[TRIP/Zip Code]'
yAxis:
columnIds:
- E2i1kDnOsK
xAxis:
columnId: EyRpfDLcDG
layout: |
<?xml version="1.0" encoding="utf-8"?>
<Page type="grid" gridTemplateColumns="repeat(24, 1fr)" gridTemplateRows="auto" id="cyWhHmmqyl">
<LayoutElement elementId="1jPqRYvgkg" gridColumn="1 / 25" gridRow="1 / 21"/>
<LayoutElement elementId="xLjdrkDom2" gridColumn="1 / 25" gridRow="21 / 41"/>
</Page>
Representing line charts
Line chart representation
...
id: xLjdrkDom2
kind: line-chart
source:
elementId: 1jPqRYvgkg
kind: table
columns:
- id: EyRpfDLcDG
formula: DateTrunc("month", [Start Date])
- id: E2i1kDnOsK
formula: Count([Id])
- id: ATTkk7PzOY
formula: '[TRIP/Id]'
- id: tzPL15PMZh
formula: '[TRIP/Duration]'
- id: ZcRynZxgBS
formula: '[TRIP/Start Date]'
- id: Bq87FWheam
formula: '[TRIP/Start Station Name]'
- id: XiJtntl3Cu
formula: '[TRIP/Start Station Id]'
- id: 2Bqvchcc7L
formula: '[TRIP/End Date]'
- id: OghSYFEqzp
formula: '[TRIP/End Station Name]'
- id: 02A2c1H2gt
formula: '[TRIP/End Station Id]'
- id: YCey3mSSAS
formula: '[TRIP/Bike Id]'
- id: wepQywWo3R
formula: '[TRIP/Subscription Type]'
- id: fTNGVjLMZB
formula: '[TRIP/Zip Code]'
yAxis:
columnIds:
- XkIgpZ9nL5
xAxis:
columnId: EyRpfDLcDG
...