# Data structure

A Venn diagram requires a data structure similar to identity tables in set theory. The "In" and "Out" are binary values that determine if an element belongs to a specific set or not. To create a Venn diagram, users need to create sets in Tableau.

#### Instructions to create sets in Tableau

1. **Open Tableau:** Launch Tableau and open your workbook.
2. **Connect to Data:** Connect to the data source that you want to use for creating the Venn diagram.
3. **Create Sets:**
   * Go to the Data pane on the left.
   * Right-click on the dimension you want to use for your set.
   * Select "Create" and then "Set."
   * In the Create Set dialog box, you can define the criteria for the set. Select the members or conditions to include the elements in the set.
   * Click "OK" to create the set.

Next, use the sets to create a table which looks similar to identity tables in set theory. Its also fine to drag and drop the sets in detail, however this way its easier to verify data. &#x20;

<figure><img src="https://1632500807-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0ARtwElTSzdwWxw4t1pi%2Fuploads%2FokXA0VwQWsDdQ9brFrfX%2FVenn-data.png?alt=media&#x26;token=a2a526d7-5b31-412e-be1a-963fe368dde2" alt=""><figcaption></figcaption></figure>

Now proceed with the next steps
