# formatRadians

[**@qbead/bloch-sphere**](https://qbead.gitbook.io/bloch-sphere/index)

***

[@qbead/bloch-sphere](https://qbead.gitbook.io/bloch-sphere/index) / formatRadians

## Function: formatRadians()

> **formatRadians**(`radians`, `precision`): `string`

Defined in: [src/format.ts:23](https://github.com/qbead/bloch-sphere/blob/41247d60e67bd802cc21854379a06362e5d0957c/src/format.ts#L23)

Format an angle given in radians as a string in radians with a given precision.

### Parameters

| Parameter   | Type     | Default value |
| ----------- | -------- | ------------- |
| `radians`   | `number` | `undefined`   |
| `precision` | `number` | `2`           |

### Returns

`string`
