pymovements.Gaze.save#
- Gaze.save(dirpath: str | Path, *, save_events: bool | None = None, save_samples: bool | None = None, save_experiment: bool | None = None, verbose: int = 1, extension: str = 'feather') Gaze[source]#
Save data from the Gaze object in the provided directory.
Depending on parameters, it may save three files: * preprocessed gaze in samples (samples) * calculated gaze events (events) * metadatata experiment in YAML file (experiment).
Data will be saved as feather or csv files.
- Returns:
Returns self, useful for method cascading.
- Return type:
- Parameters:
dirpath (str | Path) – Absloute directory name to save data. This argument is used only for this single call and does not alter
pymovements.Dataset.events_rootpath().save_events (bool | None) – Save events in events.{extension} file
save_samples (bool | None) – Save samples in sample.{extension} file
save_experiment (bool | None) – Save experiment metadata in experiment.yaml file
verbose (int) – Verbosity level (0: no print output, 1: show progress bar, 2: print saved filepaths) (default: 1)
extension (str) – Extension specifies the fileformat to store the data. (default: ‘feather’)
- Raises:
ValueError – If save_events is True and self.events is None or empty
ValueError – If save_experiment is True and self.experiment is None