similar to: How to generate a xyplot with multiple panels using an empty data frame ?

Displaying 20 results from an estimated 5000 matches similar to: "How to generate a xyplot with multiple panels using an empty data frame ?"

2009 Jan 30
0
How to generate a xyplot with multiple panels using an empty data frame ?
Hi: I am coding some interactive interface using an xyplot from lattice. When a user clicks on a panel of the xyplot, a simulation is executed and the resulting data is plotted on the corresponding panel. The problem is that I start with an empty data frame and only fill it as the user request data from simulations. And, I have found it impossible to create a conditional plot that contains panels
2010 Apr 21
2
Help: formatting the result of 'cut' function
Dear list, I would like to format the result of the 'cut' function to perform a subsequent frequency distribution table (fdt) suitable for publications. Below an reproducible example: set.seed(1) x <- c(rnorm(1e3, mean=10, sd=1), 50, 100) start <- 0 end <- 110 h <-10 c1 <- cut(x, br=seq(start, end, h), right=TRUE) levels(c1) # I get: # [1] "(0,10]"
2016 Apr 17
3
Trying to understand cut
Jeff, Perhaps I was sloppy with my notation: I want groups >=0 <10 >=10 <20 >=20<30 ...... >=90 <100 In any event, my question remains, why did the four different versions of cut give me the same results? I hope someone can explain to me the function of include.lowest and right in the call to cut. As demonstrated in my example below, the parameters do not seem to alter
2008 Oct 23
1
Getting the panel location of a xyplot matrix using a mouse click in a GDCanvas
Hi: I would like to find out the panel of a xyplot matrix where a mouse clicked. I know this functionality is already bundled in trellis.focus but I can't use it because I am coding a stand alone application in Java using with GDCanvas as a graphics device. I tried calling trellis.focus from Java with: re.eval("t = trellis.focus()")); However it did not work for an embedded
2016 Apr 17
2
Trying to understand cut
I am trying to understand cut so I can divide a list of numbers into 10 group: 0-9.0 10-10.9 20-20.9 30-30.9, 40-40.9, 50-50.9 60-60.9 70-70.9 80-80.9 90-90.9 As I try to do this, I have been playing with the cut function. Surprising the following for applications of cut give me the exact same groups. This surprises me given that I have varied parameters include.lowest and right. Can someone
2016 Apr 17
0
Trying to understand cut
Have you read FAQ 7.31 recently, John? Your whole premise is flawed. You should be thinking of ranges [0,10), [10,20), and so on because numbers ending in 0.9 are never going to be exact. -- Sent from my phone. Please excuse my brevity. On April 16, 2016 7:38:50 PM PDT, John Sorkin <jsorkin at grecc.umaryland.edu> wrote: >I am trying to understand cut so I can divide a list of numbers
2008 Nov 19
1
Buggy trellis.focus() with xyplot ?
Hi: (Tried to find a bug report about this issue, but was unable to find it, let me know if this is a known issue) I have been working on an interface to highlight xyplot panels on mouse overs in JavaGD but I have stumbled with what seems to be a bug in trellis.focus. I am using R 2.8 with lattice 0.17-15 *** To replicate the bug: 1.- display an xyplot. For example, from the xyplot help page:
2009 Apr 27
1
Grouping multiple runs of multiple datasets in lattice's xyplot
Hi: I don't know if my explanation below is clear, so afterwards, I wrote a small a self contained annotated example that generates two plots. I execute simulations with different parameters settings that create several datasets, and for each parameter setting (or dataset) I can obtain different results by choosing a different random seed. I am stuck grouping data from the datasets and runs
2004 Mar 17
9
Frequency table
This must be FAQ, but I can't find it in archives or with a site search. I am trying to construct a frequency table. I guess this should be done with table. Or perhaps factor and split. Or prop.table. cut? findInterval? Argh! Please correct me if what I am looking for is not called a "frequency table". Perhaps it's called grouped data. > zz$x9 [1] 65 70 85 65 65 65 62 55
2008 Sep 29
3
count data with a specific range
Hi there, The data is data<-c(2,6,13,26,19,25,18,11,22,25) I want to count data for these rages: [0~10]: [11~20]: [21-30]: Is anyone can help me? Thank you in advance -- View this message in context: http://www.nabble.com/count-data-with-a-specific-range-tp19732290p19732290.html Sent from the R help mailing list archive at Nabble.com.
2009 Jan 21
1
Can I add a point to a pointsGrob from an xyplot without redrawing ?
Hi: I am a newbie using grid and lattice. I want to update a xyplot without redrawing and I was wondering if there is a way of adding a point to a pointsGrob ? For example, take the example from the "R Graphics Book" page 218-219: grid.newpage() angle <- seq(0, 2*pi, length=21)[-21] x <- cos(angle) y <- sin(angle) xyplot( y ~ x, aspect = 1) Lets say I take the pointsGrob
2009 Jul 31
1
xyplot with 2 panels and 2 different x-scales
Hi All, I have this data: type<-c("country","country","country","world","world","world") place<-c("A","B","C","A","B","C") rank<-c(1,3,5,512,420,320) df1<-data.frame(type,place,rank) and need to produce an xyplot with 2 panels, where the x-values are labelled:
2008 Sep 02
2
annotating individual panels produced by xyplot
Hi all, I'm new to R and lattice and panel functions. I've produced a lattice graph using xyplot. Now I would like to add various, and *different*, annotations to each individual panel. I tried something like this, using panel.text ... <code> xyplot(dent ~ era | vegzone, groups=seedtype, panel=function(...) { panel.xyplot(...)
2006 Aug 29
2
lattice/xyplot: plotting 4 variables in two panels - can this be done?
Hi, I would like to create a plot of y1,y2,y3,y4 against x for several subjects such that y1 and y2 are plotted against x in one panel and y3 and y4 against x in another panel. Thus if there are 3 subjects I should end up with 6 panels. Is there a simple way of doing so (i.e. without calling xyplot() several times, and then padding the results together)?? Regards S?ren
2005 Jul 25
1
order of panels in xyplot
I'm having trouble with the order of the panels using xyplot. I had used this bit of code before and received the desired plot (the code was not identical, but very similar; perhaps more importantly I was working with an older version of R) . Now the panels appear right to left instead of left to right, as it says in the help files, which is what I would like. Does anyone know if this has
2008 Aug 08
1
Lattice: regression lines within grouped xyplot panels
Dear community, I am looking for a possibility to draw 'regression lines' instead of 'smooth' lines in grouped xyplots. The following code should give you a small example of the data structure. library(lattice) data(Gcsemv, package = "mlmRev") # Creates artificial grouping variable ... Gcsemv$Groups <- ifelse(as.numeric(as.character(Gcsemv$school))>65000,
2010 Nov 30
2
xyplot : superimposed 2 groups in different panels
Hello, I would like to plot the following xyplot : for each date of fff (1 date per panel), bbb=f(aaa) for the two groups (ddd=1 and ddd=2) superimposed. I can do it by group (see below) but not together. I looked at http://lmdvr.r-forge.r-project.org/figures/figures.html but I haven't found what I was looking for (to be honest, I haven't understood all the examples). Any help will be
2008 May 18
1
How to change col and pch between panels in xyplot
Dear R-helpers, x <- rep(1:2, 4) y <- c(2, 4, 3, 5, 1, 3, 2, 4) w <- factor(rep(1:2, each = 4)) v <- rep(1:2, each = 2, 2) xyplot(y ~ x | w, groups = v, type = 'b') How do I tell xyplot to use four colors and four plot characters and four line types? And how do I set up an appropriate key in each? _____________________________ Professor Michael Kubovy University of Virginia
2007 May 08
1
Separate x-axis ticks for panels in xyplot()?
Dear r-helpers, In an xyplot I have xyplot(y ~ x | c, groups = g, scales = list( x = list( at = v1, labels = c('A', 'B', 'C', 'D'), rot = 45 ) ) ) g consists of two groups. How do I define a different set of x ticks and labels for the second panel? I'm looking for something like xyplot(y ~ x | c, groups = g, scales = list( x =
2005 Nov 22
2
change axis format for different panels in xyplot in lattice
Dear R users, My apologies for a simple question for which I suspect there is a simple answer that I have yet to find. I'd like to plot panels in lattice with different graphical parameters for the axes. For example, the code x<-rnorm(100) y<-rnorm(100) z<-c(rep(1,50), rep(2,50)) library(lattice) xyplot(y~x|z) plots two panels with the default black axes. Running the following