decode_design

pyoptex.utils.design.decode_design(Yenc, effect_types, coords=None)[source]

Decode the design according to the effect types. Each categorical factor is decoded from effect-encoding, unless the coordinates are specified.

It is the inverse of encode_design

Parameters

Ynp.array(2d)

The effect-encoded design matrix.

effect_typesnp.array(1d)

An array indicating whether the effect is continuous (=1) or categorical (with >1 levels).

coords: None or list[np.ndarray]

Coordinates to be used for decoding the categorical variables.

Returns

Ydecnp.array(2d)

The decoded design-matrix