Skip to content

changing colnames in dataframes

1 message · Wolfgang Lindner

#
thank you all, Jagat, Bert and Prof. Ripley for your kind help.

The PROBLEM was:

give descripitve names to the columns in
JJ<-data.frame( c( as.character(rep( gender,3))) , c( F76,6- F83, F90) )

Possible SOLUTIONs are:

1.    JJ <- data.frame( gender=c( as.character(rep( gender,3))) ,
J.value=c(F76,6- F83, F90) )

2.   names(JJ) <- c("gender","J.value")

Now I can continue my work being happy with R.

hth
Wolfgang