Re: [R] bwplot(): Can Panel Heading Span Two Lines? [RESOLVED]

2012-09-10 Thread Rich Shepard
On Mon, 10 Sep 2012, Bert Gunter wrote: In addition, try this: x <- rep(1:10,2); y <- runif(20);f<-factor(rep(paste("This is\nLevel",1:2),e=10)) xyplot(y~x|f, par.strip.text=list(lineheight=.8,lines=3)) Bert, Thanks very much. If the docs are less than clear to you, they will certainly be

Re: [R] bwplot(): Can Panel Heading Span Two Lines? [RESOLVED]

2012-09-10 Thread David Winsemius
On Sep 10, 2012, at 1:48 PM, Bert Gunter wrote: > In addition, try this: > > x <- rep(1:10,2); y <- runif(20);f<-factor(rep(paste("This > is\nLevel",1:2),e=10)) > xyplot(y~x|f, > par.strip.text=list(lineheight=.8,lines=3)) Bert; I had imagined that the factor level character strings could b

Re: [R] bwplot(): Can Panel Heading Span Two Lines? [RESOLVED]

2012-09-10 Thread Bert Gunter
In addition, try this: x <- rep(1:10,2); y <- runif(20);f<-factor(rep(paste("This is\nLevel",1:2),e=10)) xyplot(y~x|f, par.strip.text=list(lineheight=.8,lines=3)) I find the documentation here confusing and incomplete: "par.strip.text" is listed as a parameter both in ?xyplot and ?strip.custom.

Re: [R] bwplot(): Can Panel Heading Span Two Lines? [RESOLVED]

2012-09-10 Thread Rich Shepard
On Mon, 10 Sep 2012, David Winsemius wrote: The text that appears in the "panel header" is called the "strip". I didn't see it in the help page for bwplot. You need to look at: David, That explains why I did not find it in the book's index. ?strip.custom. And since you have the Lattice b

Re: [R] bwplot(): Can Panel Heading Span Two Lines?

2012-09-10 Thread David Winsemius
On Sep 10, 2012, at 11:35 AM, Rich Shepard wrote: > A conditioning factor for bwplot() is the stream name. There are 17 > streams so each panel is comparatively small and the names in the panel > header are truncated at both ends. I would like to wrap the names on two > lines for each panel but

[R] bwplot(): Can Panel Heading Span Two Lines?

2012-09-10 Thread Rich Shepard
A conditioning factor for bwplot() is the stream name. There are 17 streams so each panel is comparatively small and the names in the panel header are truncated at both ends. I would like to wrap the names on two lines for each panel but do not see if this can be done when I look at the online d

Re: [R] bwplot: using a numeric variable to position boxplots

2012-05-03 Thread Michael Friendly
On 5/3/2012 11:23 AM, Richard M. Heiberger wrote: Michael, I normally do this with the panel.bwplot.intermediate.hh in the HH package. This function works by plotting each box with its own call to the underlying panel.bwplot function. Thanks; I'll check that out. _

Re: [R] bwplot: using a numeric variable to position boxplots

2012-05-03 Thread Richard M. Heiberger
Michael, I normally do this with the panel.bwplot.intermediate.hh in the HH package. This function works by plotting each box with its own call to the underlying panel.bwplot function. This example from ?HH::position uses the "positioned" class to determine where to place the box. > library(HH)

[R] bwplot: using a numeric variable to position boxplots

2012-05-03 Thread Michael Friendly
[Env: R 2.14.2 / Win Xp] In the examples below, I'm using lattice::bwplot to plot boxplots of 4 variables, grouped by a factor 'epoch' which also corresponds to a numeric year. I'd like to modify the plots to position the boxplots according to the numeric value of year, but I can't figure out

Re: [R] bwplot title size

2011-12-09 Thread S Ellison
l > Sent: 08 December 2011 19:36 > To: r-help@r-project.org > Subject: [R] bwplot title size > > Using the statement below to draw a plot. The title size > doesn't seem to change regardless of what value I put in for > cex.main. How do I reduce the size of the title?

[R] bwplot title size

2011-12-08 Thread g_l
Using the statement below to draw a plot. The title size doesn't seem to change regardless of what value I put in for cex.main. How do I reduce the size of the title? #print distributions by Month bwplot(RoomsInUse ~ Hour | Month, scales=list(x=list(rot=90)), horizontal=FALSE,las=2,main=title,

Re: [R] bwplot questions: box order, axis breaks, and multiple y-axis labels

2011-06-26 Thread Deepayan Sarkar
On Mon, Jun 27, 2011 at 2:35 AM, Saalem Adera wrote: > Hi all, > > I used bwplot in lattice to create a 6-panel boxplot grouped by a > conditioning variable (param) that displays concentration (conc) in > response to treatment (trtmnt).  Here is the functional part of my > code followed by my thre

[R] bwplot questions: box order, axis breaks, and multiple y-axis labels

2011-06-26 Thread Saalem Adera
Hi all, I used bwplot in lattice to create a 6-panel boxplot grouped by a conditioning variable (param) that displays concentration (conc) in response to treatment (trtmnt). Here is the functional part of my code followed by my three questions: library(lattice); ww<-read.csv(file="c:/Rdata/latti

Re: [R] bwplot in ascending order

2011-05-02 Thread Doran, Harold
"13" "13" ... $ finalRank : int 1274 1274 1274 1274 1274 2643 2643 81 81 81 ... $ totalScore: int [1:58921(1d)] 1130 1130 1130 1130 1130 390 390 1768 1768 1768 ... ..- attr(*, "dimnames")=List of 1 .. ..$ : chr "13" "13" "13" "1

Re: [R] bwplot in ascending order

2011-05-02 Thread Mark Difford
On May 01 (2011) Harold Doran wrote: >> Can anyone point me to examples with R code where bwplot in lattice is >> used to order the boxes in >> ascending order? You don't give an example and what you want is not entirely clear. Presumably you want ordering by the median (boxplot, and based on t

Re: [R] bwplot in ascending order

2011-05-02 Thread Uwe Ligges
On 01.05.2011 22:52, Doran, Harold wrote: Can anyone point me to examples with R code where bwplot in lattice is used to order the boxes in ascending order? I have found the following discussion and it partly works. But, I have a conditioning variable, so my example is more like bwplot(var1

[R] bwplot in ascending order

2011-05-01 Thread Doran, Harold
Can anyone point me to examples with R code where bwplot in lattice is used to order the boxes in ascending order? I have found the following discussion and it partly works. But, I have a conditioning variable, so my example is more like bwplot(var1 ~ var2|condition, dat) Th example in the disc

Re: [R] bwplot [lattice]: how to get different y-axis scales for each row?

2011-04-01 Thread Deepayan Sarkar
On Sun, Mar 27, 2011 at 8:50 PM, Marius Hofert wrote: > Dear expeRts, > > I partially managed to obtain what I wanted by using latticeExtra. However, > the > following questions remain: > 1) why do not all x-axis labels appear? [compare bw and bw2] You have unnecessarily asked for relation="free

Re: [R] bwplot [lattice]: how to get different y-axis scales for each row?

2011-03-27 Thread Marius Hofert
Dear expeRts, I partially managed to obtain what I wanted by using latticeExtra. However, the following questions remain: 1) why do not all x-axis labels appear? [compare bw and bw2] 2) Can I have the y-axis labels on the right margin/side of the plot? Changing the "alternating" argument does not

Re: [R] bwplot: how to get plotmath labels?

2011-03-26 Thread Marius Hofert
Dear David, many thanks, that was it. Cheers, Marius On 2011-03-26, at 18:04 , David Winsemius wrote: > > On Mar 26, 2011, at 4:47 AM, Marius Hofert wrote: > >> Dear expeRts, >> >> How can I get plotmath-labels in the bwplot below? >> As you can see, I couldn't manage to pass the expression

Re: [R] bwplot: how to get plotmath labels?

2011-03-26 Thread David Winsemius
On Mar 26, 2011, at 4:47 AM, Marius Hofert wrote: Dear expeRts, How can I get plotmath-labels in the bwplot below? As you can see, I couldn't manage to pass the expressions through the dimnames argument. It would have been helpful, and may still be necessary, for you to explain more ful

[R] bwplot: how to get plotmath labels?

2011-03-26 Thread Marius Hofert
Dear expeRts, How can I get plotmath-labels in the bwplot below? As you can see, I couldn't manage to pass the expressions through the dimnames argument. Cheers, Marius library(lattice) ## data dim <- c(100, 6, 2, 3) dimnames <- list(n=paste("n=", seq_len(100), sep=""), grou

[R] bwplot [lattice]: how to get different y-axis scales for each row?

2011-03-26 Thread Marius Hofert
Dear expeRts, How can I get ... (1) different y-axis scales for each row (2) while having the same y-axis scales for different columns? I coulnd't manage to do this with relation="free" [which gives (1) but not (2)]. I also tried relation="sliced", but it did not give the same y-axis scales wit

[R] Bwplot with dendrogram to indicate significant differences

2011-02-10 Thread Michael Hoffman
I would like to make a box plot with a dendogram on top that can be used to indicate significant differences (with an asterisk or three at a node depending on the p-value). I can supply the adjacency information a priori. Is there an easy way to do this? Other ways of presenting the same inform

[R] bwplot

2011-01-05 Thread Aina Carbonell
I'm trying use the function bwplot, but I receive a message that the function is not found. I charged the lattice, sm, and Hmrsc, package but without success. That I trying to do is an unique box-plot with in the x-axes two levels Season and Area, and in the y axis abundance. [[alternati

Re: [R] bwplot change whiskers position to percentile 5 and P95

2010-10-16 Thread Frank Harrell
See also the panel.bpplot function in the Hmisc package. This gives you many options for extended box plots. Frank - Frank Harrell Department of Biostatistics, Vanderbilt University -- View this message in context: http://r.789695.n4.nabble.com/bwplot-change-whiskers-position-to-percenti

Re: [R] bwplot change whiskers position to percentile 5 and P95

2010-10-15 Thread Christophe Bouffioux
Hi David, More info Thanks a lot Christophe ## library(Hmisc) library(lattice) library(fields) library(gregmisc) library(quantreg) > str(sasdata03_a) 'data.frame': 109971 obs. of 6 variables: $ jaar : Factor w/ 3 levels "2006","2007",..: 1 1 1 1 1 1 1 1 1 1 ... $ Cat_F

Re: [R] bwplot change whiskers position to percentile 5 and P95

2010-10-14 Thread Christophe Bouffioux
Hi, I have tried your proposition, and it works properly on the simulated data, but not on my real data, and I do not see any explanations, this is weird, i have no more ideas to explore the problem so here i give some information on my data, nothing special actually, Christophe > summary(sasd

Re: [R] bwplot change whiskers position to percentile 5 and P95

2010-10-14 Thread David Winsemius
On Oct 14, 2010, at 11:07 AM, Christophe Bouffioux wrote: Hi, I have tried your proposition, and it works properly on the simulated data, but not on my real data, and I do not see any explanations, this is weird, i have no more ideas to explore the problem You should: a) provide the co

Re: [R] bwplot change whiskers position to percentile 5 and P95

2010-10-13 Thread David Winsemius
On Oct 13, 2010, at 10:05 AM, Christophe Bouffioux wrote: Dear R-community, Using bwplot, how can I put the whiskers at percentile 5 and percentile 95, in place of the default position coef=1.5?? Using panel=panel.bwstrip, whiskerpos=0.05, from the package agsemisc gives satisfaction, bu

[R] bwplot change whiskers position to percentile 5 and P95

2010-10-13 Thread Christophe Bouffioux
Dear R-community, Using bwplot, how can I put the whiskers at percentile 5 and percentile 95, in place of the default position coef=1.5?? Using panel=panel.bwstrip, whiskerpos=0.05, from the package agsemisc gives satisfaction, but changes the appearance of my boxplot and works with an old versio

Re: [R] bwplot superpose panel.points from another dataframe

2010-09-28 Thread Christophe Bouffioux
BINGO we have the solution thanks a lot both, Deepayan and Dennis, for your help Christophe On Tue, Sep 28, 2010 at 2:10 PM, Deepayan Sarkar wrote: > On Tue, Sep 28, 2010 at 12:59 PM, Christophe Bouffioux > wrote: > > Thanks for your help Peter > > but the red marks on boxplot do not correspon

Re: [R] bwplot superpose panel.points from another dataframe

2010-09-28 Thread Deepayan Sarkar
On Tue, Sep 28, 2010 at 12:59 PM, Christophe Bouffioux wrote: > Thanks for your help Peter > but the red marks on boxplot do not correspond to ex2 dataframe > actually, it reproduce on each panel the same marks > that is to say the 3 first lines of ex2 > So this is not correct You are probably lo

Re: [R] bwplot superpose panel.points from another dataframe

2010-09-28 Thread Dennis Murphy
Hi: I did this in ggplot2, which seemed easier than the approach you tried in lattice's bwplot() - as far as I can tell, you want to plot the unique value of v1b as a red dot in each boxplot. To that end, ex <- data.frame(v1 = log(abs(rt(180, 3)) + 1), v2 = rep(c("2007", "2006", "

Re: [R] bwplot superpose panel.points from another dataframe

2010-09-28 Thread Christophe Bouffioux
Thanks for your help Peter but the red marks on boxplot do not correspond to ex2 dataframe actually, it reproduce on each panel the same marks that is to say the 3 first lines of ex2 So this is not correct Christophe On Mon, Sep 27, 2010 at 6:18 PM, Peter Ehlers wrote: > On 2010-09-27 4:54, Ch

Re: [R] bwplot superpose panel.points from another dataframe

2010-09-27 Thread Peter Ehlers
On 2010-09-27 4:54, Christophe Bouffioux wrote: bwplot(v2 ~ v1 | z, data = ex3, layout=c(3,2), pch = "|", par.settings = list( plot.symbol = list(alpha = 1, col = "transparent",cex = 1,pch = 20)), panel = function(x, y){ panel.bwplot(x, y)

[R] bwplot superpose panel.points from another dataframe

2010-09-27 Thread Christophe Bouffioux
Hi everybody, using bwplot for producing panel boxplot with 3 dimensions i want to add a mark on each boxplot representing one individual (on all its dimensions) till now, i didn't succeed getting the desired solution I want as well to keep the median symbols as a line Many thanks for your help c

Re: [R] bwplot in loop

2010-05-17 Thread David Winsemius
On May 17, 2010, at 1:36 PM, GL wrote: I have the two loops listed below. The first executes perfectly and creates a series of density plots. The second does not produce any output, however, if I enter the exact bwplot command after the loop executes, I get output for the last value in t

Re: [R] bwplot in loop

2010-05-17 Thread GL
Subsequently saw this in FAQs See FAQ: http://cran.r-project.org/doc/FAQ/R-FAQ.html#Why-do-lattice_002ftrellis-graphics-not-work_003f -- View this message in context: http://r.789695.n4.nabble.com/bwplot-in-loop-tp2220020p2220034.html Sent from the R help mailing list archive at Nabble.com. __

[R] bwplot in loop

2010-05-17 Thread GL
I have the two loops listed below. The first executes perfectly and creates a series of density plots. The second does not produce any output, however, if I enter the exact bwplot command after the loop executes, I get output for the last value in the list of services. Why am I not getting output

Re: [R] bwplot: how to draw smooth curve through medians?

2010-05-12 Thread Deepayan Sarkar
On Wed, May 12, 2010 at 3:24 AM, Marius Hofert wrote: > Dear R experts, > > Is there an easy way how to combine the black dots (i.e., the medians) in the > bwplot > > bwplot(voice.part ~ height, data=singer, xlab="Height (inches)") > > by a smooth curve? Depends on what you mean by "smooth". bw

[R] bwplot: how to draw smooth curve through medians?

2010-05-12 Thread Marius Hofert
Dear R experts, Is there an easy way how to combine the black dots (i.e., the medians) in the bwplot bwplot(voice.part ~ height, data=singer, xlab="Height (inches)") by a smooth curve? Cheers, Marius __ R-help@r-project.org mailing list https://st

Re: [R] bwplot - scattered

2010-04-28 Thread Erik Iverson
someone wrote: Hi, I'm using the bwplot from the agsemisc package which has a scattered attribute which can be set so that the single dots can bee seen better. my problem is, that I am having so many dots that they still overlap. I could increase the output of the diagram but thats not really m

[R] bwplot - scattered

2010-04-28 Thread someone
Hi, I'm using the bwplot from the agsemisc package which has a scattered attribute which can be set so that the single dots can bee seen better. my problem is, that I am having so many dots that they still overlap. I could increase the output of the diagram but thats not really my intention. has s

Re: [R] bwplot puts the bars in the wrong place

2010-04-19 Thread Peter Ehlers
James, It's actually the bars for hour 3 (which don't exist) that are missing. You still need the 'drop.unused.levels=FALSE' and if you make 'OnHour' into a factor then you won't need the 'horizontal=FALSE'. -Peter Ehlers On 2010-04-19 8:27, James Rome wrote: You were right about the gdf$. So

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread Peter Ehlers
James, Your problem with bwplot is with your scales definition. bwplot places the plots at locations 1:24; you can then supply arbitrary labels for these locations. Try changing the following: xlim = c(-1, 24) to xlim = c(0, 25) at = hrs to at = hrs + 1 (or redefine hrs) As to needing to use

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread Ben Bolker
James Rome gmail.com> writes: > ... does the call automatically assume that the variable > names are from the frame in the data= statement? Yes, it does. How about bwplot(tt~factor(OnHour,levels=0:23)|Runway,data=gdf, drop.unused.levels=FALSE) ? __

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread David Winsemius
On Apr 17, 2010, at 11:01 AM, James Rome wrote: Ah, Well, I thought I put up just the data needed. Sorry, was wrong file. And yes I am still climbing up the very steep learning curve hill. I attach a better data set. If it gets stripped, it is at http://dl.dropbox.com/u/537118/gdf.txt 1. I pu

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread Peter Ehlers
On 2010-04-17 9:01, James Rome wrote: Ah, Well, I thought I put up just the data needed. Sorry, was wrong file. And yes I am still climbing up the very steep learning curve hill. I attach a better data set. If it gets stripped, it is at http://dl.dropbox.com/u/537118/gdf.txt 1. I put the gdf$tt

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread David Winsemius
After unzipping that file, http://dl.dropbox.com/u/537118/gdf.zip , I got a structure object that took what seemed to be an inordinately long time to eval-parse wehn assigned to gdf, but it did eventually produce: > str(gdf) 'data.frame': 2656 obs. of 21 variables: $ OnDate:Clas

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread Peter Ehlers
Well, finally we have something that we can respond to. Do note the following from the Posting Guide: # No binary attachments except for PS, PDF, and some image and archive formats (others are automatically stripped off because they can contain malicious software). Files in other formats and lar

Re: [R] bwplot puts the bars in the wrong place

2010-04-17 Thread James Rome
The data are at http://dl.dropbox.com/u/537118/gdf.zip On 4/17/2010 1:42 AM, Deepayan Sarkar wrote: On Fri, Apr 16, 2010 at 1:54 PM, James Rome wrote: > Dear R-Help, > > With the attached data set, I am still getting incorrect bwplots > None of your attachments came through (presumably becaus

Re: [R] bwplot puts the bars in the wrong place

2010-04-16 Thread Deepayan Sarkar
On Fri, Apr 16, 2010 at 1:54 PM, James Rome wrote: > Dear R-Help, > > With the attached data set, I am still getting incorrect bwplots None of your attachments came through (presumably because of the list filters), and we need the data to figure out what's happening. Either put the result of dput

Re: [R] bwplot puts the bars in the wrong place

2010-04-16 Thread James Rome
On 4/16/2010 8:27 PM, Jun Shen wrote:Jim, Try this, bwplot(tt~as.factor(OnHour),data=gdf,..) Jun Shen from Millipore I already tried using a factor, and the data set I enclosed had gdf$OnHFact which was already a factor. It gave the same wrong plot. What did work was to call xyplot instead

Re: [R] bwplot puts the bars in the wrong place

2010-04-16 Thread Jun Shen
Jim, Try this, bwplot(tt~as.factor(OnHour),data=gdf,..) Jun Shen from Millipore On Fri, Apr 16, 2010 at 3:54 PM, James Rome wrote: > Dear R-Help, > > With the attached data set, I am still getting incorrect bwplots > > > xyplot(gdf$tt~gdf$OnHour |gdf$Runway, data=gdf) # Is correct > >

[R] bwplot puts the bars in the wrong place

2010-04-16 Thread James Rome
Dear R-Help, With the attached data set, I am still getting incorrect bwplots > xyplot(gdf$tt~gdf$OnHour |gdf$Runway, data=gdf) # Is correct > bwplot(gdf$tt~gdf$OnHour |gdf$Runway, data=gdf, horizontal=FALSE) # Puts the boxes on the wrong x-axis values # look especially at 0 and 3. How do

Re: [R] bwplot() {lattice}

2010-03-02 Thread Peng Cai
Thanks Deepayan ! On Sun, Feb 28, 2010 at 2:08 PM, Deepayan Sarkar wrote: > On Sat, Feb 27, 2010 at 8:14 PM, Peng Cai > wrote: > > Thanks a lot Deepayan, one question: > > > > Is it possible to place these barplots side-by-side instaed of super > > imposing? Something like this: > > http://www.i

Re: [R] bwplot with pch = "|"

2010-03-02 Thread Deepayan Sarkar
On Mon, Mar 1, 2010 at 10:49 AM, Duncan Mackay wrote: > Dear All > > Below is a toy example of a modified standard bwplot. > > require(lattice) > DF <- > data.frame(site = rep(1:5, each = 20), >           height = rnorm(100)) > > bwplot(site ~ height,DF, > pch = "|", > par.settings = list(strip.ba

[R] bwplot with pch = "|"

2010-02-28 Thread Duncan Mackay
Dear All Below is a toy example of a modified standard bwplot. require(lattice) DF <- data.frame(site = rep(1:5, each = 20), height = rnorm(100)) bwplot(site ~ height,DF, pch = "|", par.settings = list(strip.background = list(col = "transparent"), box.rectangle = list(col = "grey70

Re: [R] bwplot() {lattice}

2010-02-28 Thread Deepayan Sarkar
On Sat, Feb 27, 2010 at 8:14 PM, Peng Cai wrote: > Thanks a lot Deepayan, one question: > > Is it possible to place these barplots side-by-side instaed of super > imposing? Something like this: > http://www.imachordata.com/wp-content/uploads/2009/09/boxplot.png Well, yes; a quick approximation is

Re: [R] bwplot() {lattice}

2010-02-27 Thread Peng Cai
Thanks a lot Deepayan, one question: Is it possible to place these barplots side-by-side instaed of super imposing? Something like this: http://www.imachordata.com/wp-content/uploads/2009/09/boxplot.png library(lattice) bwplot(yield ~ variety, data = barley, col = 1, pch = 16, panel = panel

Re: [R] bwplot() {lattice}

2010-02-26 Thread Deepayan Sarkar
On Fri, Feb 26, 2010 at 8:30 AM, Peng Cai wrote: > Hi All, > > I'm trying to plot boxplot graph. I tried barchart with "groups=" option and > it worked fine. But when I try to generate same kind of graph using > bwplot(), "groups=" option doesn't seem to work. Though this works, > > yield ~ variet

[R] bwplot() {lattice}

2010-02-25 Thread Peng Cai
Hi All, I'm trying to plot boxplot graph. I tried barchart with "groups=" option and it worked fine. But when I try to generate same kind of graph using bwplot(), "groups=" option doesn't seem to work. Though this works, yield ~ variety | site * year I'm thinking why "groups=" doesn't work in th

Re: [R] bwplot scales in alphabetical order

2009-09-30 Thread Tim Clark
Peter, Thanks, that did it! Tim Tim Clark Department of Zoology University of Hawaii --- On Wed, 9/30/09, Peter Ehlers wrote: > From: Peter Ehlers > Subject: Re: [R] bwplot scales in alphabetical order > To: "Tim Clark" > Cc: r-help@r-project.org > Date: Wednesd

Re: [R] bwplot scales in alphabetical order

2009-09-30 Thread Peter Ehlers
Tim, Add the argument as.table=TRUE to your call: bwplot(y~x|id, horizontal=FALSE, as.table=TRUE) Peter Ehlers Tim Clark wrote: Dear List, I know this has been covered before, but I don't seem to be able to get it right. I am constructing a boxplot in lattice and can't get the scales in t

[R] bwplot scales in alphabetical order

2009-09-30 Thread Tim Clark
Dear List, I know this has been covered before, but I don't seem to be able to get it right. I am constructing a boxplot in lattice and can't get the scales in the correct alphebetical order. I have already read that this is due to the way factors are treated, and I have to redefine the level

Re: [R] bwplot with Date object

2008-07-31 Thread Deepayan Sarkar
On Thu, Jul 31, 2008 at 12:54 PM, GOUACHE David <[EMAIL PROTECTED]> wrote: > 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=1

[R] bwplot with Date object

2008-07-31 Thread GOUACHE David
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.num

Re: [R] bwplot

2008-05-05 Thread Deepayan Sarkar
On 5/5/08, cfinet <[EMAIL PROTECTED]> wrote: > Hi, > I have 2 questions about bwplot in R : > 1) How to change the order of my different boxes in the graph ? > 2) How to rename the names of the differents boxes ? because I know how to > do that with boxplot (using names) but I do not find the eq

Re: [R] bwplot

2008-05-05 Thread Yasir Kaheil
Hi Cedric, to change the names of different boxes, you could use levels on the dataframe factor variable you're plotting- see this example: library('lattice'); bwplot(voice.part ~ height, data=singer, xlab="Height (inches)") singer.m<-singer levels(singer.m$voice.part)<- c("a","f","g","j","k","o",

[R] bwplot

2008-05-05 Thread cfinet
Hi, I have 2 questions about bwplot in R : 1) How to change the order of my different boxes in the graph ? 2) How to rename the names of the differents boxes ? because I know how to do that with boxplot (using names) but I do not find the equivalent parameter in bwplot. thanks, Cédric _