similar to: Lattice Panel Print Order

Displaying 20 results from an estimated 10000 matches similar to: "Lattice Panel Print Order"

2010 Jun 04
1
tapply help
Dear R gurus, I am trying perform what I believe will be a pretty simple task, but I'm struggling to figure out how to do it. I have two vectors of the same length, the first is numeric and the second is factor. I understand that tapply is perfect for applying a function to the numeric vector by subsets of the factors in the second vector. My issue is trying to make use of two other vectors
2010 Sep 15
3
aggregate, by, *apply
Dear R gurus, I regularly come across a situation where I would like to apply a function to a subset of data in a dataframe, but I have not found an R function to facilitate exactly what I need. More specifically, I'd like my function to have a context of where the data it's analyzing came from. Here is an example: ### BEGIN ### func<-function(x){ m<-median(x$x) if(m > 2 &
2011 May 21
1
'apply' with additional class variable
Dear R gurus, I'm trying to solve what I assume is a fairly simple problem, but I'm having trouble finding the proper approach. I have a matrix where each column is some object (e.g. a car) and each row is a numeric measurement of a feature of said object (e.g. horse power, top speed, etc.). Let's also suppose that I know what make the car is (e.g. toyota, ford, etc.), stored in a
2011 Aug 04
3
source() or OS X Lion?
Dear R Gurus, I'm seeing some strange behavior that I can't explain. I'm generating a figure for a paper and I like to save the script (no matter how simple) for future reference. My practice is to write the script and run it using the 'source()' function. What's weird is that the resultant figure is not readable by OS X 10.7.0 (Lion). While trying to figure out what I did
2002 Dec 16
1
Lattice: panel.superpose function does not pass subscripts and groups arguments (PR#2377)
Full_Name: Volker Franz Version: 1.5.1 OS: Debian-Linux Submission from: (NULL) (134.176.77.64) Hi, working with the panel.superpose function, I found out that this function does not pass the subscripts and groups arguments to panel.groups functions. In my view, this seems an unnecessary restriction, because the subscripts-mechanism which allows to access the original data should also work if
2012 Jan 01
2
Lattice: Understanding How Points Connected by Lines
A data frame has one factor, one date, and one numeric column. When I plot these using the default pch of the open circle (first attachment), xyplot(TDS ~ sampdate | she.s, data = sheep.cast, main = 'TDS in Sheep Creek', ylab = 'Concentration (mg/L)', xlab = 'Time') I see the higher concentration points toward the right on several panels. But, when I change to using a
2011 Dec 30
1
Lattice: Setting Conditioning Panel Order in Trellis Plots
I've looked in Deepayan Sarkar's book without finding how to specify the order of conditioning panels in a trellis plot. Here's the issue I'm trying to resolve: Sampling locations along a stream channel are not sequentially numbered. For example, the panel order for one plot (lower left to upper right, 4 panels per row): SC, SC-1, SC-100, SC-139, SC-140, SC-141, SC-145. SC-2,
2009 Oct 08
1
problem understanding factor levels for use lattice panel order
Hello all, In order to get the desired order of panels within lattice I realized I needed to define my factor levels. I now see how to properly do it (attached code), but: 1. I don't understand why I have to use factor() on a variable that is already a factor, and why levels() alone doesn't work to readjust the level order. 2. I just noticed that if I do use levels(xx$v1), it's
2007 Jan 02
1
lattice panel.linejoin type question
Hello R Users! I'm trying to use the panel.linejoin function to draw points and lines (type="o") but it wouldn't do it. Modifying the panel.linejoin function as such (adding type argument to the panel.lines call). *original* panel.lines(vals[xx], yy, col = col.line, lty = lty, lwd = lwd, ...) *modified panel.lines(vals[xx], yy, col = col.line, lty
2007 Jul 10
1
Formatting panel borders in lattice package
Hello all -- I would like to thicken the borders between panels -- or more generally, all borders -- in a plot generated using lattice (specifically, levelplot). Something similar perhaps to box() function in graphics. I haven't been successful in reviewing available documentation. The problem stems from using a grayscale colorscheme that puts black colors near the borders, thus
2005 Jul 23
1
Lattice: reversing order of panel placement in conditional histograms
Hi R-people, I have a question about lattice in general, and histogram specfically. How do you control the ordering of factors that controls the placement of the conditional panels. I have a dataset with factors that go 'Q1','Q2',"Q3','Q5' and of course I want the plot to place Question Q1 at the top and Question Q5 at the bottom of the graphical output.
2004 Aug 06
1
Lattice: how to index in a custom panel function?
Hi, I have a lattice xyplot that contains panels according to FactorA, and curves for the 2 levels of Factor B within a panel. I try to add text in the panels of a lattice graph. I suppose I have to write a custom function (panel.txt). What I really would like is to adapt the text in the panel according to the levels of FactorA. In the manuals, I find examples for the strips using which.given
2011 Jan 10
2
Calculating Portfolio Standard deviation
Dear R helpers I have following data stocks <- c("ABC", "DEF", "GHI", "JKL") prices_df <- data.frame(ABC = c(17,24,15,22,16,22,17,22,15,19),                                          DEF = c(22,28,20,20,28,26,29,18,24,21),                                           GHI = c(32,27,32,36,37,37,34,23,25,32),                                          
2012 Mar 16
2
Changing axis labels depending on panel in lattice
Hello, I am lattice scatterplot that has 2 panels (could be a few more). Both panels have a y-axis label that is different on the left and right sides. However the right hand side axis labelling depends on which panel i'm in . (I am plotting two curves in one panel, the left y-axis has the scale for the red line and the right y-axis has the scale for the blue line I need to convert the
2007 Jan 28
1
extra panel arguments to plot.nmGroupedData {nlme}
Greetings, I have a groupedData (nmGroupedData) object created with the following syntax: Soil <- groupedData( ksat ~ conc | soil_id/sar/rep, data=soil.data, labels=list(x='Solution Concentration', y='Saturated Hydraulic Conductivity'), units=list(x='(cmol_c)', y='(cm/s)') ) the original data represents longitudinal observations in the form of:
2009 Jul 07
1
How to re-order panels and y-axis values in trellis display using lattice
Hi, I have been trying to re-order several items in a trellised barchart display in lattice, but can't seem to figure it out. ###sample code, Stage and Colony have 2 and 3 levels respectively. barchart(Activity ~ Percent | Stage + Colony, data = Percent.df, horizontal = TRUE, layout = c(2,3), xlab = "Percent Time Engaged in Activity", ylab = "Activity") This
2009 Aug 23
2
Surpress one panel in lattice plot..?
Dear list, I have a two character vector with two different values in them (two each, that is). Naturally, when I use these vectors as grouping factors in a lattice plot, I get four panels. Now, one of the possible four combinations will never have data, so one panel will always be empty. So now my question is: can I force R / Lattice not to print it, and give me only the 3 filled panels? I have
2007 Feb 18
0
Lattice graphics: minor tick marks and panel.axis() question(s)
Hello, I have been a long-time Traditional graphics user and now moving to try Lattice graphics. At the moment I cannot figure out how to place minor tick marks in a figure made with Lattice's xyplot(). In Traditional graphics, after calling plot() I would make two calls to axis(). >From the manuals and help documentation I learned that 'scales' takes multiple 'at'
2008 May 27
2
Lattice zoo plot: no x ticks on first panel
Hi all, I want to use lattice v0.17-4 on R 2.6.2 to draw a panel of time series of zoo objects (zoo v1.5-0). Everything works until I try to separate panels a bit and show only the bottom axis line with tick marks on every panel (but not axis labels, which I want only on the bottom panels). I've tried several approachs, and the best I've got for showing only the bottom axis line and
2007 Sep 10
1
lattice panel.lmline problem
I am wanting to generate panels showing scatterplots with the linear fitted line for two groups within each panel superimposed. I have two conditioning factors, "variable" and "Group" and I want separate panels for each level of "variable" with different symbols and "lmline"s for each level of "Group". However all observations for a group are