Learn R Programming

editbl (version 1.2.0)

standardizeArgument_colnames: Standardize colnames argument to the format of named character vector

Description

Standardize colnames argument to the format of named character vector

Usage

standardizeArgument_colnames(colnames, data)

Value

named character vector

Arguments

colnames

if missing, the column names of the data; otherwise it can be an unnamed character vector of names you want to show in the table header instead of the default data column names; alternatively, you can provide a named numeric or character vector of the form 'newName1' = i1, 'newName2' = i2 or c('newName1' = 'oldName1', 'newName2' = 'oldName2', ...), where newName is the new name you want to show in the table, and i or oldName is the index of the current column name

data

tbl. The function will automatically cast to tbl if needed.

Author

Jasper Schelfhout