HARMEAN
Returns the harmonic mean of a data set of positive numbers: the reciprocal of the arithmetic mean of reciprocals.
Syntax
expression.HARMEAN(args);
expression
- A variable that represents a ApiWorksheetFunction class.
Parameters
Name | Required/Optional | Data type | Default | Description |
---|---|---|---|---|
args | Required | ApiRange | number[] | ApiName |
Returns
number
Example
var oWorksheet = Api.GetActiveSheet();
var oFunction = Api.GetWorksheetFunction();
var ans = oFunction.HARMEAN(28, 16, 878, 800, 1650, 2000);
oWorksheet.GetRange("B2").SetValue(ans);