pymovements.datasets.base.PublicDataset.pix2deg
- PublicDataset.pix2deg(verbose: bool = True) None[source]
Compute gaze positions in degrees of visual angle from pixel coordinates.
- This requires an experiment definition and also assumes that the columns ‘x_left_pix’,
‘y_left_pix’, ‘x_right_pix’ and ‘y_right_pix’ are available in the gaze dataframe.
After success, the gaze dataframe is extended by the columns ‘x_left_dva’, ‘y_left_dva’, ‘x_right_dva’ and, ‘y_right_dva’.
- Parameters
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.