Lesson five: Controls and actions
Welcome to lesson five: Controls and actions.
In the last lesson, we built our first charts and visualizations, and our dashboard began to take shape. We also learned more about lineage in Sigma to help simplify our development process.
Now, we’ll make our dashboard interactive for end users by configuring controls and actions. At the end of this lesson, our dashboard will have several customizable controls that filter our parent data table and update our visualizations.
This lesson covers the following Sigma features:
- Controls
- Converting filters to controls
- Placing filters on parent elements
- Actions
- Conditional actions
Creating basic interaction with controls
Controls are Sigma elements that allow you to define specific interactions a user can have with your workbook. There are many different types of controls, each of which offers different functionality.
To start, let’s configure a few basic controls to let users filter data on the dashboard pages. We can use controls to filter our parent table, which updates the various child charts to show trends and totals for the filtered dataset. In the next lesson, we’ll expand on this by discussing user experience, and making it clear what filters are active when.
There are two main methods for creating a filter control:
- Creating a control from the Add element bar and targeting a table
- Creating a filter from the table and converting it to a page control
This lesson covers both of these methods.
Let’s start by creating a control from the Add element bar, and targeting our parent table.
-
Open your workbook for editing, and navigate to the Departure Delay vs Arrival Delay page.
-
In the Add element bar, select Controls > Date range.

This creates a new date range control with default settings.
- Select the date range control. It displays options for selecting a date range.

- Make a selection in the date range control.
Notice that no matter what we change about this control, nothing changes about our dashboard. This is because we haven’t configured the control to target any elements.
-
Clear the date range control.
-
In the editor panel, select Targets (0) and then
Add filter target.

- Select Raw Data > FLIGHTS and set the column to Scheduled Departure DateTime.

- In the control, set a date range between
07/01/2015
and07/31/2015
.
All the elements on the workbook page update to only reflect data from flights that were scheduled to depart in July of 2015.
- Clear the control, and the elements update to reflect data from the entire year again.
By configuring a target for our control, and selecting the Scheduled Departure DateTime
column of our parent FLIGHTS table, we made it so that our control directly filters the parent table of all of our dashboard elements. By targeting the parent table, we can filter the data for all of our dashboard elements from just one control. This is another advantage of building our dashboard elements from one parent table.
Now, let’s look at an even easier way to configure a control that filters our parent table, by adding a filter to the table directly, and converting it to a page control.
-
Navigate to the Raw Data page.
-
Select the FLIGHTS table, and add a filter on the
Airline
column.

- Select
More for the filter and click Convert to page control.

This creates a list values control that targets the Airline
column of the FLIGHTS table.
- Select the Airline control, and click
More > Move to > Departure Delay vs Arrival Delay to move it to a user-facing page.
We now have a second control that filters our parent table.
Because we created it as a filter on our parent table first, and then converted it to a page control, we didn’t have to configure the target like we did with the date range control.
When should I convert a filter to a page control?Every filter in Sigma corresponds to a particular type of control element, meaning we can convert any filter to a control. The filter converts to a control with one target on the table element it originated from. Additionally, a control created this way auto-populates control values based on the table, meaning less manual configuration is required for controls like value lists.
This means that the convert to page control workflow is most useful when you need to quickly create several controls that target one table element. It’s less useful when the controls need to target several elements, as they still need to be manually configured.
To get more comfortable with this workflow for creating a control, let’s do it two more times to create filter controls for our Origin and Destination Airports.
-
Navigate to the Raw Data page.
-
Select the FLIGHTS table.
-
Add filters for both the
Origin Airport
andDestination Airport
fields.

- For both filters, click
More and select Convert to page control.
Both filters are converted to controls.

- For both controls, click
More > Move to > Departure Delay vs Arrival Delay to move them to a user-facing page.

We now have four filter controls on our dashboard page that target our parent element. When we share our final dashboard, users can make selections on these controls to filter the visualizations by Date, Airline, and Airport, while the raw data remains hidden. In this way, Sigma control elements allow you to determine the interaction a user has with your dashboard. You can choose more than just what data should appear in what charts, you can also choose how users interact with that data.
To finish this section, let’s quickly configure some settings for these four controls.
-
Select the Scheduled Departure DateTime control. Double click the label and rename it Scheduled Departure Date.
-
In the editor panel, update the Control ID to
control-departure-date
.

Control IDs are customizable unique identifiers for control elements. Later in this course, we’ll use control IDs to reference controls and their values in workbook actions. For now, we just need to write unique, standardized, sufficiently descriptive ID values for each control.
-
Select the Airline control.
-
In the editor panel, deselect the checkbox for Show null option. This removes the null option from the list of values the user can select from.
-
Set the Control ID value to
control-airline
.

-
Select the Origin Airport control.
-
In the editor panel, deselect the checkbox for Show null option. Set the Control ID value to
control-origin-airport
. -
Select the Destination Airport control.
-
In the editor panel, deselect the checkbox for Show null option. Set the Control ID value to
control-destination-airport
. -
Click Publish save your work to the published version.
Controls, lineage, and user experience
In the last section, we leveraged our workbook lineage, as well as the convert to page control feature to quickly make controls out of several filters that targeted our parent table. Now, let’s create another filter control that targets a different point in our workbook lineage.
- Navigate to the Raw Data page, and select the FLIGHTS - Delay Breakdown table.
Recall that this is a child table of our FLIGHTS table, but also the parent table for our donut chart element in the dashboard. This means that all the control elements we made in the previous section impact this table as well, since they target the upstream data source this table is based on.
Let’s make a control that targets just this table and its child elements, without impacting the parent FLIGHTS table.
Our manager has asked us to add a control that lets users filter flights in the delay breakdown based on their total arrival delay time. For example, this control would allow a user to filter for flights that were delayed by an hour or more, or between two hours and three hours, so that they can observe how the different delay root causes vary with total delay time.
- Select
Filters & controls for the FLIGHTS - Delay Breakdown table.
You might see four filters like below:

- Click
Add filter… and select Arrival Delay as the column.
Notice that nothing changed. Because we already have a filter on the Arrival Delay
column, Sigma prevents us from adding a second. This has advantages and disadvantages:
- Advantage - This protects users from having an unintuitive experience with our dashboard. Having two filters on the same column can be unclear for end users, especially if one of the filters is on a table that they don’t have access to.
- Disadvantage - This seems to remove some agency from us as the dashboard creator. Perhaps we want to offer users a control to filter on this field, but we also want some assurance that the table will always be filtered properly, which seems to require two filters.
There is a way to circumvent this limitation. But before we do that, it’s worth pausing to consider why we want to. In this case, it’s because we want to retain a filter on our parent table while also offering a control on that same column to end users. They should never be able to view a flight with less than 15 minutes in Arrival Delay
. Beyond that, however, they can filter however they want.
-
Navigate to the Arrival Delay by Delay Type page.
-
In the Add element bar, select Controls > Range slider.
-
Rename the control
Total Arrival Delay
.

- In the editor panel, under Settings, set a Min value of
15
, a Max value of1971
, and a Control ID ofcontrol-total-arrival-delay
.

- Under Targets (0), select
Add filter target. Select FLIGHTS - Delay Breakdown, and then select Arrival Delay.
We now have a control that functions as a second filter on the Arrival Delay
column. No matter our settings in the control, that table is still filtered to only show flights with at least 15 minutes of arrival delay. Note that we set a maximum value of 1971 because that is the maximum number of minutes a flight was delayed by in the dataset.
Make some selections in the range control, and observe any trends in the Average Arrival Delay by Delay Type donut chart.
- Click Publish save your work to the published version.
Intro to actions
To conclude this lesson, let’s make one more control that relies on an action workflow.
In Sigma, actions are events, or sequences of events, that you can configure to happen on a trigger. As a simple example, you might add a button to your workbook, and configure an action to take place when a user clicks the button. Actions can also be configured with conditions, meaning that even if the trigger event happens, the action sequence only kicks off if a set of criteria are met.
Our goal is to create a segmented control that allows users to include or exclude cancelled flights. To do this, we need to configure a control on the Cancelled
column, which can be either True
or False
.
-
Navigate to the Departure Delay vs Arrival Delay page.
-
In the Add element bar, select Controls > Segmented.
A segmented control appears on the page.

-
Rename it
Include Cancellations?
-
In the editor panel, under Settings, set the Value source to be the FLIGHTS table in our Raw Data page. For the column, select Cancelled.
The segmented control updates with values True
and False
.
Let’s pause for a moment: is this actually what we want to do with this control? Do we want users to toggle between True
and False
values for cancellations? If that were the case, we could configure the control to target the Cancelled
column. Then, when users select True
, they’d see data for flights that were cancelled, and when they select False
they’d see information about flights that were not cancelled.
But this isn’t the same as including or excluding cancellations. What we actually want is for users to be able to select between one of two possible lists of values:
- If they want to include cancellations, we need to show flights that have a
Cancelled
value of eitherTrue
orFalse
. - If they want to exclude cancellations, we need to show flights that have a
Cancelled
value ofFalse
only.
In other words, we want to offer our users a binary choice (include or exclude) but return data based on a set of values that aren’t binary. Let’s resolve this by using actions.
-
Select the Include Cancellations? control.
-
Change the Value source to Create manual list, and change the Value type to Text.
-
Enter the values
Yes
andNo
. -
Change the Control ID to
control-cancellations-segmented
.

- Navigate to the Raw Data page and add a filter on the
Cancelled
column, then convert it to a page control.
A list values control labelled Cancelled appears.

-
Select the Cancelled control and change the Control ID to
control-cancellations-list-values
. -
Navigate back to the Departure Delay vs Arrival Delay page.
-
Select the Include Cancellations? segmented control.
-
In the editor panel, select Actions.

In the actions panel, we can configure one or more action sequences. Each action sequence contains a condition (optional), trigger, and action. By default, there is one action sequence with no actions configured.
Let’s configure the following action sequences:
- Action sequence one - include cancellations
- Condition: When Include Cancellations? =
Yes
- Action: Set the
control-cancellations-list-values
control - Cancelled - toTrue
,False
- Condition: When Include Cancellations? =
- Action sequence two - exclude cancellations
- Condition: When Include Cancellations? =
No
- Action: Set the
control-cancellations-list-values
control - Cancelled - toFalse
- Condition: When Include Cancellations? =
- In the first Action sequence, click
More > Add condition.

- Set the Condition as Control value is equal to > Yes.

- Back in the action sequence, click
Add action…

- Configure a Set control value action to update the Cancelled (Raw Data) control like below:

- Click
Add action sequence to add another action sequence.

- Set the Condition for the second action sequence as Control value is equal to > No.

- Configure a Set control value action to update the Cancelled (Raw Data) control like below:

Test the action by changing the selection of the control. The table contents update to reflect the changes in the parent data table.
Controls can control other controls?You may have noticed that the segmented control we’re providing to the user has no targets, but can still update the table thanks to actions that change another control. This is one option for having one control set another control, but you can also use synced controls.
Synced controls allow you to create two identical controls, and automatically apply any updates made to one control to the other. This can be used to manage multiple controls on the same data source across several pages.
In this lesson, however, we can't use a synced control, since the two controls we want to connect are of different types and have different contents. In instances like this, using an action sequence is more appropriate.
- Click Publish save your work to the published version.
Conclusion
At the end of lesson five, we’ve built interactivity into our dashboard so that users can explore and analyze the data independently. To do that, we learned about the following:
- Controls
- Converting filters to controls
- Placing filters on parent elements
- Actions
- Conditional actions
Updated about 3 hours ago