Function read_experiment_dir

Source
pub fn read_experiment_dir(
    dir_path: impl AsRef<str>,
    experiment_type: ExperimentType,
) -> Result<DataFrame, FitsLoaderError>
Expand description

Reads all FITS files in a directory and combines them into a single DataFrame.

§Arguments

  • dir_path - Path to the directory containing FITS files
  • experiment_type - Type of experiment (e.g., ExperimentType::Xrr)

§Returns

A Result containing either the combined DataFrame or a FitsLoaderError.

§Example

use pyref_core::{read_experiment_dir, ExperimentType};

let df = read_experiment_dir("path/to/directory", ExperimentType::Xrr);