> For the complete documentation index, see [llms.txt](https://flutter.wednesday.is/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://flutter.wednesday.is/charts/guides/cartesian-charts/chart-structuring.md).

# Chart Structuring

Any `[CARTESIAN_TYPE]Chart` widget represents the data along the Cartesian Axes and plotted with the Cartesian Grid. We will learn about configuring the Chart Axes in the next chapter.

Every Cartesian Chart widget provides two key properties:

1. `chartStructureData`
2. `chartStylingData`

These properties control how your Grid and Axes layouts are configured as per provided data and stylised as required.

## ChartStructureData

First, let's understand the `chartStructureData` property, as it plays a vital role in the Grid Layout Construction. For this example, we will be using a `BarChart` in the code sample.

Let's take a look at the below example:

{% tabs %}
{% tab title="Code Sample" %}

<pre class="language-dart"><code class="lang-dart">...
BarChart(
  height: 400,
<strong>  chartStructureData: const CartesianChartStructureData(
</strong><strong>    xUnitValue: 1,
</strong><strong>    yUnitValue: 1,
</strong><strong>    maxXValue: 10,
</strong><strong>    maxYValue: 10,
</strong><strong>  ),
</strong>  data: BarSeries( // Data is mandatory for any chart
    barData: [
      SimpleBar(
        xValue: 1,
        yValue: const BarData(yValue: 2.3),
      ),
    ],
  ),
),
</code></pre>

{% endtab %}

{% tab title="Result" %}

<figure><img src="/files/H0hKhXPgn0QWcMCSDGzj" alt=""><figcaption></figcaption></figure>
{% endtab %}
{% endtabs %}

In the above example, we specified that our maximum values along X & Y axis are `10`. And we are to consider unit value as `1` for both. This creates a `10 x 10` Cartesian Grid in which we have plotted our bar value.

If we were to update the unit values to `2`, then we would get. `5 X 5` Grid. This how you can can use the `chartStructureData` property to effectively control the structuring of your grid dimensions, hence the name.

### Class Properties

<table><thead><tr><th width="135">Name</th><th width="293">Behaviour</th><th width="80">Type</th><th width="103">Required</th><th>Default Value</th></tr></thead><tbody><tr><td>xUnitValue</td><td>Constructs intervals along x-axis.</td><td><code>num</code></td><td><mark style="color:blue;">false</mark></td><td>1</td></tr><tr><td>yUnitValue</td><td>Constructs intervals along y-axis.</td><td><code>num</code></td><td><mark style="color:blue;">false</mark></td><td>10</td></tr><tr><td>maxXValue</td><td>The max value along +ve x-axis. Auto-calculated internally from series data if not specified.</td><td><code>num?</code></td><td><mark style="color:blue;">false</mark></td><td><code>null</code></td></tr><tr><td>maxYValue</td><td>The max value along +ve y-axis. Auto-calculated internally from series data if not specified.</td><td><code>num?</code></td><td><mark style="color:blue;">false</mark></td><td><code>null</code></td></tr></tbody></table>

Once the Chart Structure is defined, all that's left is styling for the Grid and Axes. We'll look at this in the next chapter.
