pymovements.dataset.Dataset.load#

Dataset.load(events: bool = False, preprocessed: bool = False, subset: dict[str, float | int | str | list[float | int | str]] | None = None, events_dirname: str | None = None, preprocessed_dirname: str | None = None, extension: str = 'feather') Dataset#

Parse file information and load all gaze files.

The parsed file information is assigned to the fileinfo attribute. All gaze files will be loaded as dataframes and assigned to the gaze attribute.

Parameters:
  • events (bool) – If True, load previously saved event data. (default: False)

  • preprocessed (bool) – If True, load previously saved preprocessed data, otherwise load raw data. (default: False)

  • subset (dict[str, float | int | str | list[float | int | str]] | None) – If specified, load only a subset of the dataset. All keys in the dictionary must be present in the fileinfo dataframe inferred by scan(). Values can be either float, int , str or a list of these. (default: None)

  • events_dirname (str | None) – One-time usage of an alternative directory name to save data relative to pymovements.Dataset.path(). This argument is used only for this single call and does not alter pymovements.Dataset.events_rootpath(). (default: None)

  • preprocessed_dirname (str | None) – One-time usage of an alternative directory name to save data relative to pymovements.Dataset.path(). This argument is used only for this single call and does not alter pymovements.Dataset.preprocessed_rootpath(). (default: None)

  • extension (str) – Specifies the file format for loading data. Valid options are: csv, feather. (default: ‘feather’)

Returns:

Returns self, useful for method cascading.

Return type:

Dataset