stateVector.design
Design the dimensions of variables in a state vector
Syntax
Description
Designs the dimensions of the listed variables. If the first input is -1, applies the design settings to all variables currently in the state vector.
obj = obj.design(variables, dimensions, 0|”c”|”current”|[])obj = obj.design(variables, dimensions, 1|”s”|”state”)obj = obj.design(variables, dimensions, 2|”e”|”ens”|”ensemble”)
Specifies the types of the listed dimensions. The listed dimensions will be set as ensemble dimensions, state dimensions, or kept in their current state. Ensemble dimensions are used to select the members of a state vector ensemble. State dimensions are used to select data elements along each state vector. When variables are first initialized, all dimensions are set to state dimensions. You must select at least one ensemble dimension in order to build a state vector ensemble.
If a single dimension type option is provided, applies the same setting to all listed dimensions. Otherwise, provide multiple dimension type options to select different settings for different dimensions.
Specify state and/or reference indices for the indices dimensions. Indices for state dimensions (state indices) indicate which elements along the dimension should be used in the state vector. Indices for ensemble dimensions (reference indices) are use as the reference points for selecting ensemble members.
Input Arguments
v
variableNames
dimensions
types
[0|”c”|”current”|[]]: (default) Leave in current state
[1|”s”|”state”]: State dimension
[2|”e”|”ens”|”ensemble”]: Ensemble dimension
If types is scalar, uses the same setting for all indicated dimensions. Otherwise, types must have one element per listed dimension.
indices
In most cases, indices should be a vector with a set of indices for each listed dimension. Each set of indices must either be a logical vector the length of the dimension, a set of linear indices, or an empty array. If the indices for a dimension are an empty array, selects all elements along the dimension as state/reference dimensions. If indices are linear indices, they cannot contain repeat elements.
If only a single dimension is listed, the dimension’s indices may be provided directly as a vector, instead of in a scalar cell. However, the scalar cell syntax is also permitted.