# Gauge Chart

## Gauge

{% embed url="<https://stackblitz.com/edit/swimlane-gauge-chart?embed=1&file=app/app.component.ts>" %}

## Inputs

| Property           | Type               | Default Value | Description                                                                                                      |
| ------------------ | ------------------ | ------------- | ---------------------------------------------------------------------------------------------------------------- |
| view               | number\[]          |               | the dimensions of the chart \[width, height]. If left undefined, the chart will fit to the parent container size |
| results            | object\[]          |               | the chart data                                                                                                   |
| scheme             | object             |               | the color scheme of the chart                                                                                    |
| customColors       | function or object |               | custom colors for the chart. Used to override a color for a specific value                                       |
| animations         | boolean            | true          | enable animations                                                                                                |
| legend             | boolean            | false         | show or hide the legend                                                                                          |
| legendTitle        | string             | 'Legend'      | the legend title                                                                                                 |
| min                | number             | 0             | starting point of the scale                                                                                      |
| max                | number             | 100           | ending point of the scale                                                                                        |
| units              | string             |               | text to display under the value                                                                                  |
| bigSegments        | number             | 10            | number of big segments on the axis                                                                               |
| smallSegments      | number             | 5             | number of small segments between every big segment                                                               |
| showAxis           | boolean            | true          | show or hide the axis                                                                                            |
| axisTickFormatting | function           |               | the axis tick formatting                                                                                         |
| valueFormatting    | function           |               | function that formats the value in the middle of the chart                                                       |
| angleSpan          | number             | 240           | the angle that the chart spans (in degrees)                                                                      |
| startAngle         | number             | -120          | the angle that the chart is rotated by. Use negative half of the spanning angle to centralize                    |
| tooltipDisabled    | boolean            | false         | show or hide the tooltip                                                                                         |
| tooltipTemplate    | TemplateRef        |               | a custom ng-template to be displayed inside the tooltip                                                          |
| showText           | boolean            | true          | show or hide the inner text                                                                                      |

## Outputs

| Property   | Description                              |
| ---------- | ---------------------------------------- |
| select     | click event                              |
| activate   | element activation event (mouse enter)   |
| deactivate | element deactivation event (mouse leave) |

## Data Format

The data format is single series:

```
[
  {
    "name": "Germany",
    "value": 8940000
  },
  {
    "name": "USA",
    "value": 5000000
  }
]
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://swimlane.gitbook.io/ngx-charts/examples/gauge-chart.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
