Skip to content

how to sort and group the data?

3 messages · Hemavathi Ramulu, Baptiste Auguie, PIKAL Petr

#
try this,

d = read.table(textConnection("USER NAME
12     admin
12     admin
10     admin
10     advertising
61     process
17    snapshot
61    ticket
61    ticket
30    snapshot
10    advertising
10    advertising
10    advertising
10    advertising
"),head=T)

str(d) # note that NAME is a factor
library(ggplot2)

qplot(NAME,USER,data=d, geom="point")


baptiste
On 2 Apr 2009, at 10:14, Hemavathi Ramulu wrote:

            
_____________________________

Baptiste Augui?

School of Physics
University of Exeter
Stocker Road,
Exeter, Devon,
EX4 4QL, UK

Phone: +44 1392 264187

http://newton.ex.ac.uk/research/emag
#
Hi

r-help-bounces at r-project.org napsal dne 02.04.2009 11:14:34:
For instance

apply(your.data, 2, sort)
or
your.data[order(your.data[,1]),]
maybe
plot(your.data)

You can not expect sensible answers of perplexing questions.

Regards
Petr
http://www.R-project.org/posting-guide.html