> ## Documentation Index
> Fetch the complete documentation index at: https://domoinc-openapi-sync-dataflows.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Segments in Analyzer

export const InlineImage = ({src, alt = '', height = '1.6em'}) => {
  return <img noZoom src={src} alt={alt} style={{
    display: 'inline',
    verticalAlign: 'start',
    height: height,
    margin: '0'
  }} />;
};

### Intro

The Segments feature allows you to create better comparisons of a Segment versus another group. Additionally, you can dynamically filter one item without impacting the Segment and compare the results. You can add a Segment to any multi-series chart, period-over-period chart, or multi-value chart. You can also add Segments to the Card Details view of cards and dashboards.

***

### Required Grants

You must have the Edit DataSet grant to create Segments on a DataSet. Learn more about grants in [Managing Custom Roles](/s/article/360043438973).

### Create a Segment

Follow these steps to create a Segment. Segments are saved to the DataSet and can be reused on other cards.

1. Open a card in Analyzer.
2. In the toolbar, select
   **Segments**.

   <Frame>
     <img alt="select segments.jpg" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UPoz.jpg?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=700a74002a92003658376ae5714ad41b" style={{width: 898, height: 73}} width="2976" height="242" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UPoz.jpg" />
   </Frame>

   The Segment creation modal displays.

   <Frame>
     <img alt="Screenshot 2024-03-11 at 11.06.38 AM.png" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UPk9.jpg?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=2e51d5bf51c2e4d5f9ea49e77fce98be" style={{width: 551, height: 740}} width="1290" height="1732" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UPk9.jpg" />
   </Frame>
3. In the modal, enter a name in the
   **Segment name** field. **Note:** The Segment name must match the item you are filtering in your data. For example, if you are selecting where the `Product` column equals "Toys", then you would name the Segment "Toys". Otherwise, your chart displays both the original data for "Toys" and the new Segment for "Toys" instead of the Segment replacing the existing data for "Toys."
4. (Optional) Enter information about the segment in the
   **Description** field. This helps users determine what Segments to use if there are multiple on the DataSet.
5. Under
   **Filter columns to create a Segment**, select <InlineImage src="/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UQ6j.jpg" /> to add columns to define and filter the Segment.
6. Select the value in the column by which you want to filter the Segment and select
   **Apply**. Repeat steps 5 and 6 as needed. As you make changes, you can preview your Segment at the bottom of the modal.
7. Under
   **Do not filter this segment by the following columns** **,** select <InlineImage src="/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UQ6j.jpg" /> columns that you do not want to filter the Segment. Repeat as needed. As you make changes, you can preview your Segment at the bottom of the modal.
8. (Optional) Under
   **Segment color rules,** select a color from the **Card color** or **Dataset color** dropdown to apply color to the Segment. **Note:** The Segment always displays the DataSet color unless a card color has been set; card color overrides DataSet color. Card color only displays for this Segment on this particular card.
9. Select
   **Save & Close** to save the Segment and close the model.

### Use Segments

<Note>
  **Notes:**

  * Segments are saved to the DataSet. If you use a DataSet with Segments on a dashboard, the Segments option displays.
  * You can save up to 20 segments to a DataSet.
</Note>

# Use a Segment in a Card

1. Open the card for which you want to use a Segment in Analyzer.
2. In the left panel, in the
   **Segments** tab, select the Segment you want to use.
3. Drag the Segment above the visualization beside the
   **X axis**, **Y axis**, and **Series** areas.
4. Repeat steps 2 and 3 until all the desired Segments are added.
5. Save the card.

# Use a Segment in the Card Details View

When viewing the card Details for a card, if the DataSet has a Segment or Segments, you can go to the **Segments** tab and select up to three Segments at a time to display on the card.

# Use a Segment on a Dashboard

1. At the top of the dashboard where you want to use a Segment, locate the Filter Bar. To open it, select
   <InlineImage src="/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UTPZ.jpg" /> **Show Page filters**. DataSets associated with the dashboard must have Segments already created. See how to [create a Segment](#create_segment) above.

   <Frame>
     <img alt="filter bar.jpg" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UTcT.jpg?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=16822a55e674d05d4d7c0042de3b8e7f" style={{width: 851, height: 262}} width="3296" height="1014" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000UTcT.jpg" />
   </Frame>
2. Select the
   **Segments** dropdown.

   <Frame>
     <img alt="Segments_Drop_Down_Menu.png" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EM5w000005vOxR.png?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=37b0194b49efd39b97756bf0bab77638" width="454" height="58" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EM5w000005vOxR.png" />
   </Frame>
3. Select the Segment(s) to apply to the dashboard. In the dropdown, hover over the Segment to display its description if applicable.

   <Frame>
     <img alt="Segments_in_Dashboard.png" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EM5w000005vOy2.png?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=bdcd01665f5dcfaae43e905b584b3ea8" style={{width: 750, height: 433}} width="1101" height="636" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EM5w000005vOy2.png" />
   </Frame>
4. Select
   **Apply** to apply the selected Segments to the dashboard.

#### Disable Segments on a Dashboard

Follow these steps to disable Segments on a dashboard.

1. Select
   <InlineImage src="/images/kb/ka05w0000012Aam-00N5w00000Ri7BU-0EM5w000006vrB8.jpg" /> **Settings menu** > <InlineImage src="/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000bRSg.jpg" /> **Filter options**.

   The **Filter options** modal displays.

   <Frame>
     <img alt="filter options.jpg" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000bPfO.jpg?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=d75e031c536c9e1145a08a4f668bc087" style={{width: 899, height: 480}} width="3448" height="1840" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000bPfO.jpg" />
   </Frame>
2. In the modal, clear the
   **Allow segments** checkbox.

   <Frame>
     <img alt="allow segments.jpg" src="https://mintcdn.com/domoinc-openapi-sync-dataflows/2k2HWlcjOFv0edU2/images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000bSYP.jpg?fit=max&auto=format&n=2k2HWlcjOFv0edU2&q=85&s=c430994b2418bba8583e2a0e741c6d4a" style={{width: 451, height: 305}} width="1106" height="748" data-path="images/kb/ka0Vq0000000dar-00N5w00000Ri7BU-0EMVq000000bSYP.jpg" />
   </Frame>
3. Select
   **Save**.

### Segments (video)

<iframe allowfullscreen="allowfullscreen" frameborder="0" height="315" src="//www.youtube-nocookie.com/embed/wOqH0Dc9qoU" width="560" />
