These functions load samples from files and return a nmr_dataset.
nmr_read_samples_dir(
samples_dir,
format = "bruker",
pulse_sequence = NULL,
metadata_only = FALSE,
...
)
nmr_read_samples(
sample_names,
format = "bruker",
pulse_sequence = NULL,
metadata_only = FALSE,
...
)
A directory or directories that contain multiple samples
Either "bruker" or "jdx"
If it is set to a pulse sequence ("NOESY", "JRES", "CPMG"...) it will only load the samples that match that pulse sequence.
A logical, to load only metadata (default: FALSE
)
Arguments passed on to read_bruker_pdata
pdata_file
File name of the binary NMR data to load. Usually "1r".
If NULL
, it is autodetected based on the dimension
sample_path
A character path of the sample directory
pdata_path
Path from sample_path
to the preprocessed data
all_components
If FALSE
load only the real component. Otherwise load the real and imaginary components
read_pdata_title
If TRUE
also reads metadata from pdata title file.
A character vector with file or directory names.
a nmr_dataset object
Other import/export functions:
Pipelines
,
files_to_rDolphin()
,
load_and_save_functions
,
nmr_data()
,
nmr_meta_export()
,
nmr_read_bruker_fid()
,
nmr_zip_bruker_samples()
,
save_files_to_rDolphin()
,
save_profiling_output()
,
to_ChemoSpec()
dir_to_demo_dataset <- system.file("dataset-demo", package = "AlpsNMR")
dataset <- nmr_read_samples_dir(dir_to_demo_dataset)
dir_to_demo_dataset <- system.file("dataset-demo", package = "AlpsNMR")
zip_files <- fs::dir_ls(dir_to_demo_dataset, glob = "*.zip")
dataset <- nmr_read_samples(sample_names = zip_files)