This creates a new CPOTrained object which will behave according to the given state. The state should usually be obtained using getCPOTrainedState and then slightly modified. No checks for correctness of the state will (or can) be done, it is the user's responsibility to ensure that the correct CPOConstructor is used, and that the state is only modified in a way the CPO can handle.

makeCPOTrainedFromState(constructor, state, get.inverter = FALSE)

Arguments

constructor

[CPOConstructor]
A cpo constructor.

state

[list]
A state gotten from another CPORetrafo or CPOInverter object using getCPOTrainedState.

get.inverter

[logical(1)]
Whether to get a CPOInverter. Usually a CPORetrafo is created. This must be TRUE if the state was created from a CPOInverter, FALSE otherwise. Default is FALSE.

Value

[CPOTrained]. A CPORetrafo or CPOInverter (as if retrieved using retrafo or inverter after a primitive CPO was applied to some data) with the given state.

See also