function blocksplit_trajs

deeptime.decomposition.blocksplit_trajs(trajs, blocksize=1, sliding=True, shift=None, random_state=None)

Splits trajectories into approximately uncorrelated fragments.

Will split trajectories into fragments of lengths lag or longer. These fragments are overlapping in order to conserve the transition counts at given lag. If sliding=True, the resulting trajectories will lead to exactly the same count matrix as when counted from dtrajs. If sliding=False (sampling at lag), the count matrices are only equal when also setting shift=0.

Parameters:
  • trajs (list of ndarray(int)) – Trajectories

  • blocksize (int) – The minimum block size.

  • sliding (bool) – True for splitting trajectories for sliding count, False if lag-sampling will be applied

  • shift (None or int) – Start of first full tau-window. If None, shift will be randomly generated

  • random_state (None or int or np.random.RandomState) – Random seed to use.

Returns:

blocks – The blocks.

Return type:

list of ndarray