sample_data_with_new_names: Load sample data from file and rename samples using names of...

View source: R/targets_misc.R

sample_data_with_new_namesR Documentation

Load sample data from file and rename samples using names of samples and an optional order

Description

lifecycle-maturing

Useful for targets bioinformatic pipeline.

Usage

sample_data_with_new_names(
  file_path,
  names_of_samples,
  samples_order = NULL,
  ...
)

Arguments

file_path

(required) a path to the sample_data file

names_of_samples

(required) a vector of sample names

samples_order

Optional numeric vector to sort sample names

...

Other arguments passed on to utils::read.delim() function.

Value

A data.frame from file_path and new names

Author(s)

Adrien Taudière

See Also

rename_samples()

Examples

sam_file <- system.file("extdata", "sam_data.csv", package = "MiscMetabar")
sample_data_with_new_names(sam_file, paste0("Samples_", seq(1, 185)))


MiscMetabar documentation built on Oct. 8, 2024, 1:07 a.m.