Re: [R] Changing colour in barchart

2011-09-26 Thread Deepayan Sarkar
On Mon, Sep 26, 2011 at 2:55 PM, shikantaza martyn.wilkin...@uhb.nhs.uk wrote: Hello. I've been trying to change the colour of the bars in the auto.key to blue and red. I have tried: barchart(Rate~Digit,Ben,groups=Cat, horizontal=FALSE,ylab=Rate

Re: [R] Move the x-axis labels to the top of the dotplot

2011-09-16 Thread Deepayan Sarkar
On Thu, Sep 15, 2011 at 2:29 PM, markm0705 markm0...@gmail.com wrote: Dear R helpers I would like to move the x-axis labels, which plot automatically at the base of a dot plot to the top of the plot. Is there a way to do this? Use 'alternating=2' in scales: scales = list(x = list(log =

Re: [R] Move the main titel to the left of the plot

2011-09-16 Thread Deepayan Sarkar
On Thu, Sep 15, 2011 at 2:26 PM, markm0705 markm0...@gmail.com wrote: Dear R helpers I wish to move the main title, which appears on a dotplot to be right aligned with the left axis. It's horizontally centered in the full plot area by default. Is there are parameter associated with dotplot

Re: [R] Lattice xyplot log scale labels help!

2011-09-16 Thread Deepayan Sarkar
On Fri, Sep 16, 2011 at 2:17 AM, Cram Rigby cram.ri...@gmail.com wrote: I have a problem with lattice log scales that I could use some help with. I'm trying to print log y-axis scales without exponents in the labels.  A similar thread with Deepayan' recommendation is here:

Re: [R] Superimposing titles on dotcharts

2011-09-16 Thread Deepayan Sarkar
On Mon, Sep 12, 2011 at 8:54 PM, Mikkel Grum mi2kelg...@yahoo.com wrote: I've created a chart with times that employees have entered data on named tasks as in the following example: Employee - c(rep(Tom, 127), rep(Dick, 121), rep(Sally, 130) ) Time - c(seq(as.POSIXct(2011-09-12 07:00:00),

Re: [R] Adding groups to regression line panel function in Lattice

2011-09-11 Thread Deepayan Sarkar
On Fri, Sep 9, 2011 at 9:38 PM, Bigelow, Seth sbige...@fs.fed.us wrote: I wish to display a single-panel Lattice figure with grouped data and fitted regression lines. I don't seem to be able to get the individual regression lines to display, e.g.; d - data.frame(q = rep(1:6, each=10), cc =

Re: [R] Getting the values out of histogram (lattice)

2011-09-05 Thread Deepayan Sarkar
On Thu, Sep 1, 2011 at 10:29 AM, Rolf Turner rolf.tur...@xtra.co.nz wrote: 'Scuse me, but I don't see anything in your example relating to what the OP asked for. She wanted to get at the ``actual data defining the histogram'', which I interpret as meaning the bar heights (the percentages,

Re: [R] Sorting order of reorder with multiple variables

2011-08-27 Thread Deepayan Sarkar
On Thu, Aug 25, 2011 at 6:15 PM, markm0705 markm0...@gmail.com wrote: I've been building a ranked dot plot for several days now and am sorting the data using the reorder command.  What I don't understand is how reorder works when mutiple varibles are plotted by grouping.  In the example below

Re: [R] Suppressing error messages printed in xyplot() with panel function

2011-08-24 Thread Deepayan Sarkar
On Thu, Aug 25, 2011 at 1:00 AM, Adam Zeilinger zeil0...@umn.edu wrote: Hello, I am using the xyplot() function to create a series of scatterplot panels with lines of best fit.  To draw the lines of best fit for each panel, I am using a panel function.  Here's an example: species -

Re: [R] Auto key legend does not match plot

2011-08-22 Thread Deepayan Sarkar
On Sat, Aug 20, 2011 at 3:53 AM, markm0705 markm0...@gmail.com wrote: Dear R-help members.  I am an 'R-learner' (about 6 hours so far) using the lattice library to create a ranked dotplot and am colour coding the dots by a variable called Commodity.  However when i use autokey to make a legend

Re: [R] dotchart vs. dotplot ... groups

2011-08-18 Thread Deepayan Sarkar
On Wed, Aug 17, 2011 at 11:59 PM, mkzo...@comcast.net wrote: I'm trying to create a dotplot with some grouping. I've been able to create what I want using dotchart (basic graphics), but can't quite get it using dotplot (lattice). I prefer to use lattice (or ggplot2) because I think it's a

Re: [R] Constructing an additional key inside of a lattice panel

2011-08-17 Thread Deepayan Sarkar
On Tue, Aug 16, 2011 at 4:35 PM, Fredrik Karlsson dargo...@gmail.com wrote: Hi, I would like to add an additional key inside of a panel based on a factor that is not the groups argument. I've tried using the panel.key function in latticeExtras, but I cannot get the line types the way I want

Re: [R] lattice: How to get log base for each axis inside panel function?

2011-08-15 Thread Deepayan Sarkar
On Mon, Aug 15, 2011 at 10:34 PM, Mikhail Titov m...@gmx.us wrote: Hello! I'd like to have a function to draw correct grid while using log axis with xyplot from lattice package. Right now I have the following code inside of my panel function: lim - current.panel.limits() v -

Re: [R] current.panel.limits() of lattice returning NaN limits - why?

2011-08-12 Thread Deepayan Sarkar
On Fri, Aug 12, 2011 at 12:15 PM, Fredrik Karlsson dargo...@gmail.com wrote: Hi, I need a custom axis function for a plot, but it seems that current.panel.limits() sometimes returns NaN limits for the plot, which it much harder to calculate anything sensible. An illustration: Given this

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 saalemad...@gmail.com 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

Re: [R] Lattice xyplot to group by two parameters

2011-06-24 Thread Deepayan Sarkar
On Thu, Jun 23, 2011 at 10:15 PM, Guy Jett gj...@itsi.com wrote: My thanks to this mailing list and its members for their great help in the past.  I have yet another question per the following code and comments: # I need individual graphs grouped by PARLABEL AND Event, with PARLABEL #  

Re: [R] Accessor functions in lattice graphics

2011-06-20 Thread Deepayan Sarkar
On Mon, Jun 20, 2011 at 9:22 PM, David Winsemius dwinsem...@comcast.net wrote: On Jun 20, 2011, at 10:49 AM, Bert Gunter wrote: Hi all: Thanks, David. This is a good example of knowledgeable R forensic investigation. I leave it to Frank whether it meets his criteria. However, I would

Re: [R] xyplot Legend Title and Position

2011-06-20 Thread Deepayan Sarkar
On Wed, Jun 15, 2011 at 6:32 PM, Justin McBride crazyhaw...@gmail.com wrote: Dennis, Thanks for your suggestion, but that is not exactly what I was after. I was trying to get the legend in the margin on the top right of the page and not in the plot frame.  Is there a way to do this? One

Re: [R] giving factor names

2011-06-20 Thread Deepayan Sarkar
On Fri, Jun 10, 2011 at 10:27 PM, Ethan Brown ethancbr...@gmail.com wrote: Hi Kieran, I'm not very familiar with lattice, but here's a workaround that works for me. Basically, I just created a new data.frame column that was a factor (combo$zf), and forced its levels to be what you're looking

Re: [R] Cleveland dot plots

2011-06-07 Thread Deepayan Sarkar
On Wed, Jun 8, 2011 at 5:00 AM, Colin Wahl biow...@gmail.com wrote: I would rather use cleveland dot plots than bar charts to display my study results. I have not been able to find (or figure out) an R package that is capable of producing the publication quality dot charts Im looking for. I

Re: [R] Using dates on axis with Grid plots

2011-06-03 Thread Deepayan Sarkar
On Thu, May 26, 2011 at 4:34 AM, Paul Murrell p.murr...@auckland.ac.nz wrote: Hi On 15/05/2011 2:01 a.m., Larry White wrote: Hi, I'm trying to use Grid plots and would like to have an X axis that represents dates. I have several years of data so I would like to be able to have labeled

Re: [R] splom Tick Location

2011-06-03 Thread Deepayan Sarkar
On Tue, May 31, 2011 at 6:45 PM, Elliot Joel Bernstein elliot.bernst...@fdopartners.com wrote: When using the 'splom' function of the 'lattice' packge, is it possible to get all the tick marks in the outer margins of the plot? No. -Deepayan X - as.data.frame(matrix(rnorm(1000), 100, 10))

Re: [R] Weighted box or violin plots in Lattice?

2011-05-09 Thread Deepayan Sarkar
On Mon, May 9, 2011 at 5:42 PM, David Winsemius dwinsem...@comcast.net wrote: On May 9, 2011, at 12:35 AM, Deepayan Sarkar wrote: On Mon, May 9, 2011 at 2:20 AM, Thomas Lumley tlum...@uw.edu wrote: On Mon, May 9, 2011 at 6:35 AM, Deepayan Sarkar deepayan.sar...@gmail.com wrote: On Sat

Re: [R] How to alter circle size

2011-05-09 Thread Deepayan Sarkar
say.) On Sun, May 8, 2011 at 3:00 PM, Deepayan Sarkar deepayan.sar...@gmail.com wrote: On Fri, May 6, 2011 at 10:21 PM, Dat Mai dat.d@gmail.com wrote: Hello all, I'm trying  to create a heatmap using 2 matrices I have: z and v. Both matrices represent different correlations

Re: [R] Weighted box or violin plots in Lattice?

2011-05-08 Thread Deepayan Sarkar
On Sat, May 7, 2011 at 1:55 AM, Raphael Mazor rapha...@sccwrp.org wrote: Is it possible to create weighted boxplots or violin plots in lattice? It seems that you can specify weights for panel.histogram() and panel.densityplot(), but not for panel.bwplot or panel.violin(). Not for

Re: [R] Cumsum in Lattice Panel Function

2011-05-08 Thread Deepayan Sarkar
On Fri, May 6, 2011 at 9:24 PM, Elliot Joel Bernstein elliot.bernst...@fdopartners.com wrote: I'm trying to create an xyplot with a groups argument where the y-variable is the cumsum of the values stored in the input data frame. I almost have it, but I can't get it to automatically adjust the

Re: [R] How to alter circle size

2011-05-08 Thread Deepayan Sarkar
On Fri, May 6, 2011 at 10:21 PM, Dat Mai dat.d@gmail.com wrote: Hello all, I'm trying  to create a heatmap using 2 matrices I have: z and v. Both matrices represent different correlations for the same independent variables. The problem I have is that I wish to have the values from matrix

Re: [R] Weighted box or violin plots in Lattice?

2011-05-08 Thread Deepayan Sarkar
On Mon, May 9, 2011 at 2:20 AM, Thomas Lumley tlum...@uw.edu wrote: On Mon, May 9, 2011 at 6:35 AM, Deepayan Sarkar deepayan.sar...@gmail.com wrote: On Sat, May 7, 2011 at 1:55 AM, Raphael Mazor rapha...@sccwrp.org wrote: Is it possible to create weighted boxplots or violin plots in lattice

Re: [R] Panels order in lattice graphs

2011-05-05 Thread Deepayan Sarkar
On Wed, May 4, 2011 at 9:20 PM, Cristina Silva csi...@ipimar.pt wrote: Hi all, In lattice graphs, panels are drawn from left to right and bottom to top. The flag as.table=TRUE changes to left to right and top to bottom. Is there any way to change to first top to bottom and then left to right?

[R] Bug in lattice that shipped with R 2.13.0

2011-05-05 Thread Deepayan Sarkar
Hi all, I had meant to make this announcement earlier but had forgotten (a recent bug report reminded me). The version of lattice that ships with R 2.13.0 has a fairly serious bug in panel.abline (which would neglect to draw many negative slope lines). If you use lattice with R 2.13.0, you

Re: [R] different colors in a segplot centers (package latticeExtra)

2011-04-18 Thread Deepayan Sarkar
On Mon, Apr 18, 2011 at 4:10 AM, barbara costa rbarbar...@gmail.com wrote: Hi, how can I change colors in the centers of my segplot? I'm not interested in coloring the lines (Standard error limits) but the centers (means)?  here's my code: segplot(reorder(factor(Species), MeanBiom)  ~

Re: [R] Define ylim in lattice plot based upon panel function output

2011-04-18 Thread Deepayan Sarkar
On Tue, Apr 19, 2011 at 7:38 AM, Sébastien Bihorel pomc...@free.fr wrote: Dear R-users, By default, the xyplot function automatically defines the axis ranges based upon the content of y and x variables. However, when one includes some calls to other panel.something functions in the panel

Re: [R] Adding text labels to lattice plots with multiple panels

2011-04-12 Thread Deepayan Sarkar
On Mon, Apr 11, 2011 at 12:49 AM, Jeff Stevens stev0...@gmail.com wrote: Many thanks, Peter.  This works brilliantly, and I prefer to have the labels assigned outside of panel function as well. You could also consider using which.packet(). You haven't explicitly told us how the labels are

Re: [R] Override col.lines and col.symbol in panel.xyplot with type='b'

2011-04-12 Thread Deepayan Sarkar
On Mon, Apr 11, 2011 at 9:27 PM, Szumiloski, John john_szumilo...@merck.com wrote: Dear useRs, I have a longitudinal experiment with several treatment groups, ~20 subjects per group, ~6 timepoints and a continuous dependent variable.  I have been successfully been using lattice::xyplot with

Re: [R] Adding margin text to lattice graphics

2011-04-12 Thread Deepayan Sarkar
On Mon, Apr 11, 2011 at 3:53 AM, baptiste auguie baptiste.aug...@googlemail.com wrote: Yes, very sorry about this -- I had subconsciously ignored the hypothetical possibility that anyone wouldn't have ggplot2 loaded in their .Rprofile ;) Replacing mpg with beaver1 (datasets) should be more

Re: [R] dotplot as a background for multiple barchart plots (with Lattice)

2011-04-07 Thread Deepayan Sarkar
On Thu, Apr 7, 2011 at 7:16 PM, Christian Charles christian.char...@inrialpes.fr wrote: Hi R users, I'm kind stuck in my R experience... I want to have a multiple barchart with n windows, but with the same background for each window, and I want that background to be a recorded dotplot.

Re: [R] lattice: par.settings: custom axis.line by panel

2011-04-07 Thread Deepayan Sarkar
On Fri, Apr 8, 2011 at 6:10 AM, Benjamin Tyner bty...@gmail.com wrote: Hello, In lattice, is there a way to customize the axis.line by panel? For example, say I have two panels: Data - data.frame(x=runif(10),                  y=rnorm(10),                  f=gl(2,5)                  )

Re: [R] lattice: how to center a subtitle?

2011-04-05 Thread Deepayan Sarkar
On Tue, Apr 5, 2011 at 6:12 AM, David Scott d.sc...@auckland.ac.nz wrote: [...] I am not sure where I read it and I can't find it again, but my understanding is that expressions using bquote with lattice need to be enclosed in as.expression() to work. That is in contrast to what happens in

Re: [R] lattice xscale.components: different ticks on top/bottom axis

2011-04-05 Thread Deepayan Sarkar
On Sat, Apr 2, 2011 at 1:29 AM, boris.vasil...@forces.gc.ca wrote: On Fri, Mar 11, 2011 at 12:28 AM, boris.vasil...@forces.gc.ca wrote: Good afternoon, I am trying to create a plot where the bottom and top axes have the same scale but different tick marks.  I tried user-defined

Re: [R] how to label customized y axis when using lattice parallel parameter common.scale=TRUE

2011-04-05 Thread Deepayan Sarkar
On Tue, Apr 5, 2011 at 4:39 PM, Pengcheng Yang peng...@gmail.com wrote: Dear all, When I use parallel function in lattice package, I want to label the y-axis with customized numbers. Like this: parallel(~iris[1:4] | Species, iris,horiz=FALSE,common.scale=TRUE,    

Re: [R] Arrangement of Lattice Histograms - Top to bottom and then left to right?

2011-04-05 Thread Deepayan Sarkar
On Wed, Apr 6, 2011 at 12:34 AM, Bert Gunter gunter.ber...@gene.com wrote: Look for the index.cond argument at the bottom of the Help page for xyplot. -- Bert Also ?print.trellis and ?packet.panel.default for a more general (non-example-specific) approach. -Deepayan On Tue, Apr 5, 2011 at

Re: [R] lattice: wireframe eats up points; how to make points on wireframe visible?

2011-04-01 Thread Deepayan Sarkar
On Thu, Mar 31, 2011 at 3:26 AM, Marius Hofert m_hof...@web.de wrote: Dear Deepayan, thanks for answering. It's never too late to be useful. I see your point in the minimal example. I checked the z-axis limits in my original problem for the point to be inside and it wasn't there. I can't

Re: [R] lattice xscale.components: different ticks on top/bottom axis

2011-04-01 Thread Deepayan Sarkar
On Fri, Mar 11, 2011 at 12:28 AM, boris.vasil...@forces.gc.ca wrote: Good afternoon, I am trying to create a plot where the bottom and top axes have the same scale but different tick marks.  I tried user-defined xscale.component function but it does not produce desired results.  Can anybody

Re: [R] lattice (panel.3dscatter): how to make plot symbol thicker?

2011-04-01 Thread Deepayan Sarkar
On Fri, Mar 11, 2011 at 12:29 PM, Marius Hofert m_hof...@web.de wrote: Dear Deepayan, many thanks for answering. Another thing I am wondering is the following: I know you can have (3d-like) crosses in the wireframe plot. But are there any other 3d-like plot symbols? Of course one can use

Re: [R] XYPlot Conditioning Variable in Specific, Non-Alphanumeric Order. -- Resending with corrected .txt file

2011-04-01 Thread Deepayan Sarkar
On Sat, Mar 19, 2011 at 2:53 AM, Guy Jett gj...@itsi.com wrote: Due to an error on my part, I have renamed the previously attached file from  T_5-04b_LTC-SE-SO-Compared.csv to  T_5-04b_LTC-SE-SO-Compared.txt. It remains a comma-delimited file so the extension can be changed and used per the

Re: [R] lattice histogram function and groups

2011-04-01 Thread Deepayan Sarkar
On Sat, Mar 19, 2011 at 6:11 AM, Evans, David G (DFG) david.ev...@alaska.gov wrote: Hi, From the following code (tweaked from another user): variable-sample(rep(1:2,100)) individual-rep(1:3, length(variable)) group-rep(LETTERS[1:2],length(variable)/2)

Re: [R] Colour makes my life; but not my bwplot (panel.violin)

2011-04-01 Thread Deepayan Sarkar
On Fri, Mar 25, 2011 at 3:59 PM, JP jeanpaul.ebe...@inhibox.com wrote: Hi there David, Many thanks for your time and reply I created a small test set, and ran your proposed solution... and this is what I get http://i.imgur.com/vlsSQ.png This is not what I want - I want separate grp_1 and

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 m_hof...@web.de 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

Re: [R] lattice: wireframe eats up points; how to make points on wireframe visible?

2011-03-30 Thread Deepayan Sarkar
On Fri, Mar 4, 2011 at 1:47 PM, Marius Hofert m_hof...@web.de wrote: Dear expeRts, I would like to add two points to a wireframe plot. The points have (x,y,z) coordinates where z is determined to be on the wireframe [same z-value]. Now something strange happens. One point is perfectly

Re: [R] Bug in lattice auto.key argument

2011-03-17 Thread Deepayan Sarkar
On Wed, Mar 16, 2011 at 12:52 AM, jlu...@ria.buffalo.edu wrote: The Lattice auto.key argument has a bug in R.12.2. R version 2.12.2 (2011-02-25) Platform: i386-pc-mingw32/i386 (32-bit) other attached packages: [1] lattice_0.19-17 loaded via a namespace (and not attached): [1]

Re: [R] Lattice: Feature Request

2011-03-13 Thread Deepayan Sarkar
On Sat, Mar 12, 2011 at 1:30 AM, Jim Price price...@hotmail.com wrote: Thanks Peter. This is true, but consider this continuation of my example (which is probably what I should have written originally): my.opts - list(default.args = list(                       as.table = TRUE,            

Re: [R] lattice (panel.3dscatter): how to make plot symbol thicker?

2011-03-10 Thread Deepayan Sarkar
On Wed, Mar 9, 2011 at 7:57 AM, Peter Ehlers ehl...@ucalgary.ca wrote: On 2011-03-08 17:07, Jannis wrote: Searching the archive of the mailing list points to the following thread: https://stat.ethz.ch/pipermail/r-help/2009-March/193338.html Perhaps it helps you... On 03/08/2011 11:48 PM,

Re: [R] wireframe() display a graph with two colors, not a gradient.

2011-03-07 Thread Deepayan Sarkar
On Sun, Feb 27, 2011 at 1:29 AM, James Platt james-pl...@hotmail.co.uk wrote: Hi all, I'm quite new to wireframe, essentially what I want to do is display a graph, and z-values 1 would be yellow and those 1 would be blue. This is a bit of my data. 0.334643563     0.350913807    

Re: [R] Same color key for multiple lattice contour plots

2011-03-07 Thread Deepayan Sarkar
On Mon, Feb 21, 2011 at 5:29 AM, joepvanderzanden joep_vd_zan...@hotmail.com wrote: Hi all, I'm trying to make multiple lattice contour plots which have the same color key, to allow good comparisons. However, I run into some problems when fitting the plots to the color key. Basically my

Re: [R] how can I connect paired points within lattice bwplot?

2011-02-22 Thread Deepayan Sarkar
On Wed, Feb 23, 2011 at 8:01 AM, Peter Ehlers ehl...@ucalgary.ca wrote: On 2011-02-22 11:52, Cory Champagne wrote: Hello all, my first post to this list.  I do a lot of experiments using a paired sampling design and I would get a lot of mileage out of figures like this, if I can make it

Re: [R] Scaling Lattice Graphics for tikzDevice

2011-02-20 Thread Deepayan Sarkar
On Sun, Feb 20, 2011 at 5:23 AM, Elliot Joel Bernstein elliot.bernst...@fdopartners.com wrote: On Feb 18, 2011 11:02 PM, Deepayan Sarkar deepayan.sar...@gmail.com wrote: On Fri, Feb 18, 2011 at 11:04 PM, Elliot Joel Bernstein elliot.bernst...@fdopartners.com wrote: I'm trying to use

Re: [R] Scaling Lattice Graphics for tikzDevice

2011-02-18 Thread Deepayan Sarkar
On Fri, Feb 18, 2011 at 11:04 PM, Elliot Joel Bernstein elliot.bernst...@fdopartners.com wrote: I'm trying to use lattice graphics to produce some small plots for inclusion in a LaTeX file. I want the LaTeX fonts to be used in the plots, but to be scaled down to match the size of the plot. I

Re: [R] Use of panel.segments

2011-02-17 Thread Deepayan Sarkar
On Tue, Feb 15, 2011 at 9:44 PM, Lancaster, Vicki vicki.lancas...@fda.hhs.gov wrote: First I have read all the previous post on error bars segments as well as the  Lattice book by Sarkar. I am using xyplot, there are 2 panels, each panel displays the measurements from 5 matrices over

Re: [R] Adding labels into lattice's barchart

2011-02-14 Thread Deepayan Sarkar
On Wed, Feb 9, 2011 at 11:04 PM, Luca Meyer lucam1...@gmail.com wrote: *** APOLOGIZES FOR THOSE READING THE LIST THROUGH NABBLE THIS WAS ALREADY POSTED THERE BUT NOT FORWARDED TO THE LIST FOR SOME UNKNOWN REASON *** I have a dataset that looks like: $ V1: factor with 4 levels $ V2: factor

Re: [R] Adding labels into lattice's barchart

2011-02-14 Thread Deepayan Sarkar
On Mon, Feb 14, 2011 at 5:16 PM, Luca Meyer lucam1...@gmail.com wrote: Thanks Deepayan, What you suggest is quite fine, but provides the overall number of cases for the entire dataset splitted into V2 levels. What about if I need to show panel specific's values? For instance I want to

Re: [R] lattice auto.key gives mismatch colors

2011-02-13 Thread Deepayan Sarkar
On Fri, Feb 11, 2011 at 9:26 PM, John Smith zmr...@gmail.com wrote: Hello All, I am using the following code to draw a figure. But the legend given buy auto.key has mismatched colors. Could any one help me? See ?simpleTheme -Deepayan I am using R2.12.1 and most current lattice on windows

Re: [R] lattice: Synchronizing key and lines; or: why is lty used as lwd in legend?

2011-02-08 Thread Deepayan Sarkar
On Mon, Feb 7, 2011 at 1:10 PM, Dieter Menne dieter.me...@menne-biomed.de wrote: Dear latticists, Getting legend and graph line types synchronized has been a challenge in lattice; the last example below that works looks ridiculously ugly for such a simple job, I am sure there is a more

Re: [R] Suppress only Z axis tick marks and numbers in wireframe statement

2011-02-08 Thread Deepayan Sarkar
On Fri, Feb 4, 2011 at 9:21 PM, Matthew A. H. Walters walte...@ufl.edu wrote: I actually have several questions revolving around the generation of wireframe plots. The most pressing is that which is described by the subject line. I am trying to produce a figure with x, y, and z labels,

Re: [R] text labels in Trellis plot

2011-01-29 Thread Deepayan Sarkar
On Wed, Jan 26, 2011 at 4:24 PM, Markus Damian m.dam...@bristol.ac.uk wrote: Dear all, I need to generate plots in which the points of the plot are replaced by text labels, such as dog and cat. The usual way of specifying the plotting symbol with pch works only if the labels are single

Re: [R] adding text to y-axis per row of panels (lattice)

2011-01-28 Thread Deepayan Sarkar
On Thu, Jan 20, 2011 at 2:04 PM, E Hofstadler e.hofstad...@gmail.com wrote: Dear all, Being a newbie to R, I've trawled through many old posts on this list looking for a solution to my problem, but unfortunately couldn't quite figure it out myself. I'd be very grateful if someone here on this

Re: [R] circular reference lines in splom

2011-01-28 Thread Deepayan Sarkar
On Thu, Jan 20, 2011 at 9:45 AM, Max Kuhn mxk...@gmail.com wrote: Hello everyone, I'm stumped. I'd like to create a scatterplot matrix with circular reference lines. Here is an example in 2d: library(ellipse) set.seed(1) dat - matrix(rnorm(300), ncol = 3) colnames(dat) - c(X1, X2, X3)

Re: [R] Help for lattice. par(new=TRUE)

2011-01-28 Thread Deepayan Sarkar
On Fri, Jan 21, 2011 at 8:22 PM, Fabrice Tourre fabrice.c...@gmail.com wrote: Hi list, I want to plot two plot in the same figure. I set par(new=TRUE). But it does not work. library(lattice) myPanel - function(x,...) {       panel.histogram(x,alpha=0.4,...)      

Re: [R] adding text to y-axis per row of panels (lattice)

2011-01-28 Thread Deepayan Sarkar
On Fri, Jan 28, 2011 at 5:21 PM, E Hofstadler e.hofstad...@gmail.com wrote: Hello Deepayan, many thanks for your reply and help. Does this solution with ylab.right require a newer version of lattice (somewhere in the archives I noted ylab.right being mentioned in the context of a development

Re: [R] rootogram for normal distributions

2011-01-18 Thread Deepayan Sarkar
)        }        lines(z, dens, lwd=2)        points(h$mids, normdens) } set.seed(17*13) y - rnorm(500, 10,3) rootonorm(y) Deepayan Sarkar deepayan.sar...@gmail.com 17/01/2011 05:06:54 On Sun, Jan 16, 2011 at 11:58 AM, Hugo Mildenberger hugo.mildenber...@web.de wrote: Thank you very much for your

Re: [R] rootogram for normal distributions

2011-01-16 Thread Deepayan Sarkar
On Sun, Jan 16, 2011 at 11:58 AM, Hugo Mildenberger hugo.mildenber...@web.de wrote: Thank you very much for your qualified answers, and also for the link to the Tukey paper. I appreciate Tukey's writings very much. Yes, thanks to Hadley for the nice reference, I hadn't seen it before. Looking

Re: [R] how to change strip text of effect plot

2011-01-12 Thread Deepayan Sarkar
On Wed, Jan 12, 2011 at 10:36 AM, Joshua Wiley jwiley.ps...@gmail.com wrote: Hmm, I felt like it was the clearest, most direct way.  Then again, things of this nature (overide defaults using arguments rather than changing what you feed the functions) do seem to be a common request both for

Re: [R] Rectangle height in lattice xyplot key

2011-01-10 Thread Deepayan Sarkar
On Sun, Jan 9, 2011 at 9:31 AM, Duncan Mackay mac...@northnet.com.au wrote: Dear All I have a problem with the height of the boxes in the key in the following. (The text is over 2 lines to  accentuate the problem of no space between the rectangles.) Is there an easy way to put a space

Re: [R] lattice: strip panel function question

2011-01-05 Thread Deepayan Sarkar
On Mon, Dec 6, 2010 at 6:22 PM, Maarten van Iterson m.van_iterson...@lumc.nl wrote: Thanks Chris Campbell, I didn't though about that. Cheers, Maarten On Mon, 2010-12-06 at 10:08 +, Chris Campbell wrote: data$subjectID - paste(data$groups, data$subjects) # create a character label

Re: [R] lattice: how to center a title?

2011-01-04 Thread Deepayan Sarkar
On Tue, Jan 4, 2011 at 9:32 PM, Dieter Menne dieter.me...@menne-biomed.de wrote: mhofert wrote: trellis.device(pdf, width = 5, height = 5)   print(xyplot(0 ~ 0, main = This title is not 'centered' for the human's eye, scales = list(alternating = c(1,1), tck = c(1,0 dev.off() ... the

Re: [R] Condional Density Plot from different data

2010-12-09 Thread Deepayan Sarkar
On Thu, Dec 9, 2010 at 10:11 AM, Doran, Harold hdo...@air.org wrote: Perhaps I found a solution as: datA$type - gl(1, nrow(datA), label = 'PopA') datB$type - gl(1, nrow(datB), label = 'PopB') dat - rbind(datA, datB) Or, slightly shorter dat - make.groups(datA, datB)

Re: [R] plot vs print ??

2010-11-21 Thread Deepayan Sarkar
2010/11/20 Uwe Ligges lig...@statistik.tu-dortmund.de: On 18.11.2010 11:30, skan wrote: Hello everybody. My question arised from the output of lattice's histogram. But might be extended to any other object that could be printed. I think I've understood your answers,  print calls the plot

Re: [R] Lattice: xyplot group title format

2010-11-09 Thread Deepayan Sarkar
On Tue, Nov 9, 2010 at 2:06 AM, Marcus Drescher dresc...@tum.de wrote: Dear all, if I plot a lattice xyplot like: library(lattice); require(stats); Depth - equal.count(quakes$depth, number=8, overlap=.1) xyplot(lat ~ long | Depth, data = quakes) How can I manipulate the group title

Re: [R] Colour filling in panel.bwplot from lattice

2010-11-03 Thread Deepayan Sarkar
On Wed, Nov 3, 2010 at 4:11 AM, Dennis Murphy djmu...@gmail.com wrote: Hi: I don't know why, but it seems that in bwplot(voice.part ~ height, data = singer, main = NOT THE RIGHT ORDER OF COLOURS\n'yellow' 'blue' 'green' 'red' 'pink' 'violet' 'brown' 'gold',

Re: [R] Colour filling in panel.bwplot from lattice

2010-11-03 Thread Deepayan Sarkar
On Wed, Nov 3, 2010 at 4:25 PM, Rainer Hurling rhur...@gwdg.de wrote: Am 03.11.2010 10:23 (UTC+1) schrieb Deepayan Sarkar: On Wed, Nov 3, 2010 at 4:11 AM, Dennis Murphydjmu...@gmail.com  wrote: Hi: I don't know why, but it seems that in bwplot(voice.part ~ height, data = singer, main

Re: [R] Lattice plots for images

2010-11-03 Thread Deepayan Sarkar
On Wed, Nov 3, 2010 at 8:13 AM, Neba Funwi-Gabga fusigabsm...@gmail.com wrote: Hello UseRs, I need help on how to plot several raster images (such as those obtained from a kernel-smoothed intensity function) in a layout such as that obtained from the lattice package. I would like to obtain

Re: [R] removing margin space between columns in lattice plots

2010-10-28 Thread Deepayan Sarkar
On Sat, Oct 23, 2010 at 9:25 AM, Stephen T. obsessiv...@hotmail.com wrote: Hi list, From the xyplot() documentation I'm guessing this may not be possible, but is there a way to specify a scale definition something between relation=free and relation=same such that the scales are fixed across

Re: [R] lattice key subtitle

2010-10-28 Thread Deepayan Sarkar
On Tue, Oct 26, 2010 at 2:49 AM, Alexandru Dumitrescu alexandru.dumitre...@gmail.com wrote: Hello everybody, Is there a way to add a subtitle to a lattice key? None specifically for that purpose, but latticeExtra does have a mergedTrellisLegendGrob() function that may help: mylegend -

Re: [R] Control of axis limits in multiple panel lattice plots

2010-10-28 Thread Deepayan Sarkar
On Wed, Oct 27, 2010 at 6:45 AM, Peter Davenport pwdavenp...@gmail.com wrote: I've found the solution to this in an old post of Deepayan's: lattice.options(axis.padding = list(numeric=0)) Or xyplot(a~b|c,data=test.df, scales = list(axs = i)) -Deepayan Best, Peter On 27 October 2010

Re: [R] lattice: dots from xyplot to xscale.components

2010-10-20 Thread Deepayan Sarkar
On Wed, Oct 13, 2010 at 3:46 AM, Mikhail Titov m...@gmx.us wrote: Hello! I posted a feature request at lattice page on r-forge at https://r-forge.r-project.org/tracker/index.php?func=detailaid=1127group_id=638atid=2570 , but I decided to duplicate it here to make sure that I understand

Re: [R] superpose.polygon, panel.polygon and their colors

2010-10-20 Thread Deepayan Sarkar
On Wed, Oct 20, 2010 at 7:53 AM, ottorino ottorino-luca.pant...@unifi.it wrote: Il giorno mer, 20/10/2010 alle 03.05 -0700, Dennis Murphy ha scritto: Works for me!  Thanks, Dieter! Hi all. Thanks again to you both for the help. It was a problem due to a lack in updating ubuntu. After the

Re: [R] dot plot by group

2010-10-20 Thread Deepayan Sarkar
On Mon, Oct 11, 2010 at 12:55 PM, casperyc caspe...@hotmail.co.uk wrote: And now I just wonder why the ' bty='n' ' won't work? I did dotplot(BATCH~RESPONSE,data=d,subset=Type=='SHORT',bty='n') and tried other bty parameters, none is working As David says, par settings don't work in

Re: [R] Lattice: type=p stopped working in panel.average

2010-10-19 Thread Deepayan Sarkar
On Tue, Oct 19, 2010 at 4:18 PM, Alexandr Malusek alexandr.malu...@gmail.com wrote: Hi, The behavior of panel.average has changed.  In March 2010, I plotted the attached r_plotViolinOfAnnualE_old.eps. (I don't know the version of R). Today, I plotted the attached r_plotViolinOfAnnualE_new.eps

Re: [R] own TAB expansion

2010-10-09 Thread Deepayan Sarkar
On Fri, Oct 8, 2010 at 6:19 AM, Sebastian Gibb li...@sebastiangibb.de wrote: Hello Duncan, thank for your advice, but it doesn't work like expected: setClass(Class=A, representation=representation(slotA=numeric, slotB=numeric)); setMethod($, A, function(x, name) {return(slot(x, name));})

Re: [R] point characters THICKER in xyplot()

2010-10-09 Thread Deepayan Sarkar
On Fri, Oct 8, 2010 at 5:19 PM, array chip arrayprof...@yahoo.com wrote: Hi, how can I make the point characters thicker (NOT larger) in xyplot when groups= argument is used? dat-data.frame(x=1:100,y=1:100,group=rep(LETTERS[1:5],each=20))    ### lwd=2 doesn't work here

Re: [R] how to retrieve user coordinates in xyplot

2010-10-09 Thread Deepayan Sarkar
On Fri, Oct 8, 2010 at 3:52 PM, array chip arrayprof...@yahoo.com wrote: Hi, is there a way to retrieve the extremes of the user coordinates of the plotting region, like what par(usr) does in general graphics? I'd like to use them to print additional texts at certain place inside each panel.

Re: [R] conditional assignment of colors in xyplot()

2010-09-30 Thread Deepayan Sarkar
On Mon, Sep 27, 2010 at 7:11 AM, nathan pellegrin nathan.pelleg...@gmail.com wrote: # Dear R Community, # I have this data frame: df1 - data.frame(        F1 = factor( c( rep(D1,12),rep(D2,12),rep(D3,12) ) ),        F2 = factor( rep( rep( paste(O,1:6,sep=), rep(2,6) ), 3) ),        F3 =

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 christophe@gmail.com 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

Re: [R] scientific vs. fixed notation in xyplot()

2010-09-27 Thread Deepayan Sarkar
On Mon, Sep 27, 2010 at 5:28 PM, array chip arrayprof...@yahoo.com wrote: I found where the problem is with y-axis, the yscale.components.log10 should be yscale.components.log10 - function(lim, ...) {    ans - yscale.components.default(lim = lim, ...)    tick.at - logTicks(10^lim,loc=1)    

Re: [R] how to make point character thicker in the legend of xyplot?

2010-09-24 Thread Deepayan Sarkar
On Fri, Sep 24, 2010 at 7:39 AM, Peter Ehlers ehl...@ucalgary.ca wrote: On 2010-09-23 17:57, array chip wrote: Yes, it does what I want. Thank you Peter! Just wondering what else grid.pars controls? not just the symbol in legend, right? John You can have a look at ?gpar (after loading

Re: [R] Lattice xyplot and groups

2010-09-24 Thread Deepayan Sarkar
On Wed, Sep 22, 2010 at 12:21 AM, Axel axelg...@gmail.com wrote: Hi, I'm trying to plot many (x, y) data files using the xyplot function from the lattice package. Each file can be classified by set name (s1, s2,...) and data type (A, B, ...). Each data set contains a different number of

Re: [R] lattice centre a diverging colour scale

2010-09-23 Thread Deepayan Sarkar
On Thu, Sep 23, 2010 at 12:33 PM, baptiste auguie baptiste.aug...@googlemail.com wrote: Dear list, I'm using lattice::levelplot to plot a coloured image of 3D data. The range of the z values goes from negative to positive, but is not exactly centred around 0. I would however like to map a

Re: [R] xyplot axis line width

2010-09-14 Thread Deepayan Sarkar
On Tue, Sep 14, 2010 at 4:26 AM, array chip arrayprof...@yahoo.com wrote: Hi, another question: is there any argument that controls the line width of axis box of xyplot()? I tried lwd=2 or lwd.axis=2 in xyplot() or within scales=list() argument, without success. xyplot(1:10 ~ 1:10,

Re: [R] lattice package - wireframe plot : adding more than one surface and addiding a curve overlaid on the plot

2010-09-14 Thread Deepayan Sarkar
On Sat, Sep 11, 2010 at 2:28 AM, Raffaello Vardavas r_varda...@hotmail.com wrote: Dear R help, Suppose I have a dataframe with three columns named  p, v and C. Here C is a function of both p and v.  I can plot the surface C(p,v) using the package lattice using the function wireframe. Now

Re: [R] Sweave: infelicities with lattice graphics

2010-09-12 Thread Deepayan Sarkar
On Sun, Sep 12, 2010 at 8:47 AM, Duncan Murdoch murdoch.dun...@gmail.com wrote: On 12/09/2010 11:41 AM, Michael Friendly wrote: Just a follow-up on this thread, now with R 2.11.1. I was happy back then to use Deepayan's solution for this, under earlier R versions; but it now gives an error

Re: [R] lattice: layout and number of pages

2010-09-09 Thread Deepayan Sarkar
On Wed, Sep 8, 2010 at 5:49 AM, Philipp Pagel p.pa...@wzw.tum.de wrote:        Dear expeRts, ?xyplot says: In general, giving a high value of ‘layout[3]’ is not wasteful because blank pages are never created. But the following example does generate blank pages - well except for the ylab:

<    1   2   3   4   5   6   7   8   >