---
url: >-
  https://adk.nht.io/api/@nhtio/adk/batteries/tools/statistics/variables/statsCorrelateTool.md
description: Compute the Pearson correlation coefficient between two numeric arrays.
---

# Variable: statsCorrelateTool

```ts
const statsCorrelateTool: Tool<SpooledArtifact>;
```

Defined in: [batteries/tools/statistics/index.ts:105](https://github.com/NHTIO/ADK/blob/v1.20260605.0/src/batteries/tools/statistics/index.ts#L105)

Compute the Pearson correlation coefficient between two numeric arrays.

## Remarks

Returns `r`, `r²` (as a percentage of explained variance), and a plain-English interpretation
of strength and direction. Arrays must be the same length and contain at least two points.
