Answers for "Change column name of specific R column by index"

R
0

Change column name of specific R column by index

colnames(df)[col_indx] <- “new_col_name_at_col_indx”

#More specifically,
colnames(df)[3] <- "column3" #Names the third column of df as "column3".
Posted by: Guest on June-24-2021

Code answers related to "Change column name of specific R column by index"

Browse Popular Code Answers by Language