[R] bwplot with Date object

GOUACHE David D.GOUACHE at arvalisinstitutduvegetal.fr
Thu Jul 31 21:54:55 CEST 2008


Hello R-helpers,
 
I would like to produce a boxplot for dates, using lattice.
 
Here is a dummy example :
 
dates<-as.Date(32768:32895,origin="1900-01-01")
plouf<-data.frame(days=dates,group=factor(rep(1:2,times=128/2)))
 
bwplot(group~days,data=plouf)
# doesn't work, whereas :
bwplot(group~as.numeric(days),data=plouf)
# does, but is obviously not good looking when it comes to axis legends...
 
Is there a way to pull off a boxplot with dates ?
 
In advance thank you.
 
 David Gouache

 ARVALIS - Institut du végétal

 Station de La Minière

 78280 Guyancourt

 Tel: 01.30.12.96.22 / Port: 06.86.08.94.32



More information about the R-help mailing list