pymovements.datasets.base.PublicDataset.pos2vel

PublicDataset.pos2vel(method: str = 'smooth', verbose: bool = True) None[source]

Compute gaze velocites in dva/s from dva coordinates.

This requires an experiment definition and also assumes that the columns ‘x_left_dva’,

‘y_left_dva’, ‘x_right_dva’ and ‘y_right_dva’ are available in the gaze dataframe.

After success, the gaze dataframe is extended by the columns ‘x_left_vel’, ‘y_left_vel’, ‘x_right_vel’ and, ‘y_right_vel’.

Parameters
  • method (str) – Computation method. See pos2vel() for details, default: smooth.

  • verbose (bool) – If True, show progress of computation.

Raises

AttributeError – If gaze is None or there are no gaze dataframes present in the gaze attribute, or if experiment is None.