Learn R Programming

crestr (version 1.2.1)

normalise: Normalises the percentages

Description

Normalises the percentages

Usage

normalise(df, col2convert = 2:ncol(df))

Value

A vector of unique taxonIDs.

Arguments

df

The dataframe containing the data to convert.

col2convert

A vector of the columns to convert. Default is all the columns but the first, which contains an age, a depth or a sampleID.

Examples

Run this code
df <- data.frame(matrix(1:25, ncol = 5))
colnames(df) <- paste(rep("col", 5), 1:5, sep = "")
normalise(df)
normalise(df, col2convert = 3:5)

Run the code above in your browser using DataLab