# Charts (/docs/typescript-sdk/charts)

## ChartType [#charttype]

**Enum Members**:

- `BAR` ("bar")
- `LINE` ("line")
- `PIE` ("pie")
- `SCATTER` ("scatter")
- `UNKNOWN` ("unknown")

## parseChart() [#parsechart]

```ts
function parseChart(chart: Chart): Chart;
```

**Parameters**:

- `chart` _Chart_


**Returns**:

- `Chart`

***


## BarChart [#barchart]

```ts
type BarChart = Chart2D & {
  type: "bar";
};
```

### Type Declaration [#type-declaration]

#### type [#type]

```ts
type: "bar";
```

***


## BarData [#bardata]

```ts
type BarData = Pick<GeneratedChartElement, "group" | "label" | "value">;
```

***


## BoxAndWhiskerChart [#boxandwhiskerchart]

```ts
type BoxAndWhiskerChart = Chart2D & {
  type: "box_and_whisker";
};
```

### Type Declaration [#type-declaration-1]

#### type [#type-1]

```ts
type: "box_and_whisker";
```

***


## BoxAndWhiskerData [#boxandwhiskerdata]

```ts
type BoxAndWhiskerData = Pick<GeneratedChartElement, "first_quartile" | "label" | "max" | "median" | "min" | "outliers">;
```

***


## Chart [#chart]

```ts
type Chart = GeneratedChart;
```

***


## Chart2D [#chart2d]

```ts
type Chart2D = Pick<GeneratedChart, "type" | "title" | "png" | "x_label" | "y_label" | "elements">;
```

***


## ChartElement [#chartelement]

```ts
type ChartElement = GeneratedChartElement;
```

***


## CompositeChart [#compositechart]

```ts
type CompositeChart = Pick<GeneratedChart, "type" | "title" | "png" | "elements"> & {
  type: "composite_chart";
};
```

### Type Declaration [#type-declaration-2]

#### type [#type-2]

```ts
type: "composite_chart";
```

***


## LineChart [#linechart]

```ts
type LineChart = PointChart & {
  type: "line";
};
```

### Type Declaration [#type-declaration-3]

#### type [#type-3]

```ts
type: "line";
```

***


## PieChart [#piechart]

```ts
type PieChart = Pick<GeneratedChart, "type" | "title" | "png" | "elements"> & {
  type: "pie";
};
```

### Type Declaration [#type-declaration-4]

#### type [#type-4]

```ts
type: "pie";
```

***


## PieData [#piedata]

```ts
type PieData = Pick<GeneratedChartElement, "angle" | "label" | "radius">;
```

***


## PointChart [#pointchart]

```ts
type PointChart = Pick<GeneratedChart, 
  | "type"
  | "title"
  | "png"
  | "x_label"
  | "y_label"
  | "x_ticks"
  | "y_ticks"
  | "x_tick_labels"
  | "y_tick_labels"
  | "x_scale"
  | "y_scale"
| "elements">;
```

***


## PointData [#pointdata]

```ts
type PointData = Pick<GeneratedChartElement, "label" | "points">;
```

***


## ScatterChart [#scatterchart]

```ts
type ScatterChart = PointChart & {
  type: "scatter";
};
```

### Type Declaration [#type-declaration-5]

#### type [#type-5]

```ts
type: "scatter";
```
