weighted_mean
Computes weighted arithmetic, geometric, and harmonic means from numeric values and optional weights, enabling accurate aggregated averages for uneven data.
Instructions
Compute weighted, arithmetic, geometric, and harmonic means of a set of values.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| values | Yes | Array of numeric values. | |
| weights | No | Optional weights (same length as values). |