This will replace a column name with a new column name - it will not make any changes to the underlying data.

replaceName(dataIn, oldName, newName)

Arguments

dataIn

Input data frame with the old name within

oldName

string column name to replace

newName

the replacement name

Value

data frame

Author

Avants BB

Examples

mydf = generateSubtyperData( 100 )
rbfnames = names(mydf)[grep("Random",names(mydf))]
mydf = replaceName( mydf, rbfnames[1], 'mileyCyrus' )