msmbuilder.MSMLib.apply_mapping_to_assignments

msmbuilder.MSMLib.apply_mapping_to_assignments(assignments, mapping)[source]

Remap the states in an assignments file according to a mapping.

Parameters:

assignments : ndarray

Standard 2D assignments array

mapping : ndarray

1D numpy array of length equal to the number of states in Assignments. Mapping[a] = b means that the frames currently in state a will be mapped to state b

Returns:

NewAssignments : ndarray

Notes

This function is useful after performing PCCA or Ergodic Trimming. Also, the state -1 is treated specially – it always stays -1 and is not remapped.

Versions