Heloo,
I have the following problem:
orig.data <- NULL
Inside a loop I have instructions like:
orig.data <- rbind(orig.data, ...)
After that I do:
colnames(orig.data)<-c('Data','InicioViagem', ...)
Everything works fine.
For example, the first line of the matrix is:
> orig.data[1,]
Data InicioViagem ...
1 40466 ...
The problem is: I can't refer the columns by the column names.
For example:
> orig.data[1,InicioViagem]
Error: Object "InicioViagem" not found
or
> orig.data[1,]$InicioViagem
NULL
but:
> orig.data[1,2]
[1] 40466
works!
Can someone help me?
Thanks
Joao Moreira
______________________________________________
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html