[R] Keeping the order of data set when plotting

cosinenonqua sergeygoder at gmail.com
Tue Mar 2 03:53:57 CET 2010


I have a data frame with 3 columns and I want to order the entire list by one
column and then plot. I used order() and it does order the data set but when
I plot it is as if the set is as it was originally. I also can't figure out
how to plot two sets of data on the same graph. I have,

Occupation		American.Workers	Foreign.Workers
Accountant		12				2
Engineer		45				54
Doctor		50				37

I want to be able to order American.Workers and then
plot(Occupation,American.Workers) and plot(Occupation,Foreign.Workers) on
the same graph.
-- 
View this message in context: http://n4.nabble.com/Keeping-the-order-of-data-set-when-plotting-tp1574535p1574535.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list