[R] Odp: Data frame query

Petr PIKAL petr.pikal at precheza.cz
Mon Mar 8 08:51:55 CET 2010


Hi

r-help-bounces at r-project.org napsal dne 05.03.2010 13:40:54:

> 
> I have created a large dataframe (d) by getting data from file using
> read.table
> 
> I now have 79 columns and 3 million rows. How can I plot the 6th column? 
I
> tried plot(d[,6]) but it doesn't look right. When I try to do just d[,6] 
the
> console gets some odd "levels" message I don't understand

See
?factor

You shall check your input process. You probably have imported some or all 
your data as factors. Try 

levels(d[,6]) to see if there is some non numeric value in it. 

>From your second query I suppose you have included heading into your data.

I recommend to try to use your read.table with header=TRUE.

Regards
Petr



> 
> Moon
> -- 
> View this message in context: http://n4.nabble.com/Data-frame-query-
> tp1579555p1579555.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide 
http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list