dash.stateVectorVariable.total
Take a total over dimensions of a state vector variable
Syntax
Description
Takes a total over the specified dimensions given total indices and NaN options.
Disables the total over the specified dimensions.
Discards weights for weighted totals of the specified dimensions.
Input Arguments
dims
vector, linear indices [nDimensions]
The indices of the dimensions over which to take a total.
indices
cell vector [nDimensions] {[] | total indices}
Total indices for the dimensions. An empty array for state dimensions, and additive indices for ensemble dimensions.
omitnan
logical vector [nDimensions]
Whether to omit NaN elements along a total (true) or whether to include NaN (false)
header
string scalar
Header for thrown error IDs
Output Arguments
obj
scalar dash.*stateVectorVariable* object
The variable updated with the new total parameters.