# scaleOf

function in `@dioramajs/data/chart`

```ts
import { scaleOf } from '@dioramajs/data/chart'
```

Bounds and ticks of the value axis: from 0, or below it for negative values.

```ts
function scaleOf(
  values: readonly number[],
  top?: number,
): { hi: number; lo: number; ticks: number[] }
```

| Parameter | Type | Description |
| --- | --- | --- |
| `values` | `readonly number[]` |  |
| `top?` | `number` |  |

Defined in [packages/data/src/chart.ts](https://github.com/MasterKurosava/diorama/blob/main/packages/data/src/chart.ts#L151).
