CheckSampleIDs: Check Input Sample IDs

View source: R/createOmics_CheckSampleIDs.R

CheckSampleIDsR Documentation

Check Input Sample IDs

Description

Check the class of the sample IDs and if they are unique. This assumes that the sample IDs are in the first column.

Usage

CheckSampleIDs(df)

Arguments

df

An assay or phenotype data frame supplied to the CreateOmics function

Details

This function checks that the sample IDs are unique, then coerces them from factor to character (if necessary), stores these IDs as the first column, then returns the same data frame.

Value

The same data frame, if the sample IDs pass sanity checks, with the sample IDs as a character vector.

Examples

 # DO NOT CALL THIS FUNCTION DIRECTLY. CALL FROM WITHIN CreateOmics().

## Not run: 
 data("colonSurv_df")
 CheckSampleIDs(colonSurv_df[, -(2:3)])

## End(Not run)


gabrielodom/pathwayPCA documentation built on July 10, 2023, 3:32 a.m.