Skip to contents

Extract parts of an nmr_dataset

Usage

# S3 method for class 'nmr_dataset'
x[i]

Arguments

x

an nmr_dataset object

i

indices of the samples to keep

Value

an nmr_dataset with the extracted samples

Examples

dir_to_demo_dataset <- system.file("dataset-demo", package = "AlpsNMR")
dataset <- nmr_read_samples_dir(dir_to_demo_dataset)
dataset2 <- dataset[1:3] # get the first 3 samples