Skip to content

Search Archives

Search tips
from:Name Search by author name, e.g. from:Duncan Murdoch "exact phrase" Match an exact phrase word1 word2 Match messages containing both words Date range Use the date pickers to filter results to a time period

Use the list dropdown to narrow results to a specific mailing list. Combine from: with other terms to filter by author and content.

25 results for “from:Jim Price”

Lattice: useOuterStrips and axes
Jim Price · Mar 1, 2011 · r-help

Thank you, that's exactly what I needed. -- View this message in context: http://r.789695.n4.nabble.com/Lattice-useOuterStrips-and-axes-tp3330338p3330613.html Sent from the R help mailing list archive at Nabble.com.

layout is to xyplot as ??? is to qplot
Jim Price · Jul 10, 2008 · r-help

Playing with ggplot, something I'd promised myself I'd get around to. I've the following scenario: library(lattice) library(ggplot2) myData <- data.frame( x = rnorm(100), y = rnorm(100), group = 1:4 ) xyplot(y ~ x | factor(group), data...

Ceiling to the nearest ten?
Jim Price · Jan 14, 2008 · r-help

A suggestion for a family of such functions: ceilGenerator <- function(num) function(x) num * ceiling(x / num) ceil10 <- ceilGenerator(10) ceil20 <- ceilGenerator(20) ceil10(1:10 * 4) ceil20(1:10 * 4) Lauri Nikkinen wrote: > > R-users, > > Is there a function...

enable object name to be called as object (a dataset)
Jim Price · Sep 7, 2007 · r-help

a <- 1:3 b <- 11:13 c <- 21:23 names <- c('a','b','c') do.call(data.frame, list(sapply(names, function(x) get(x)))) runner wrote: > > What I am trying to do is as follows: > > - I have listed names...

Lattice: useOuterStrips and axes
Jim Price · Mar 1, 2011 · r-help

Consider the following: library(lattice) library(latticeExtra) temp <- expand.grid( subject = factor(paste('Subject', 1:3)), var = factor(paste('Variable', 1:3)), time = 1:10 ) temp$resp <- rnorm(nrow(temp), 10 * as.numeric(temp$var), 1) ylimits <- by(temp$resp...

Month end calculations
Jim Price · Aug 29, 2007 · r-help

A simple example (avoiding using dates, just to show the principle) - this assumes that your data are already sorted (?order). temp <- data.frame(subject = rep(1:2, each = 5), response = 1:10) print(temp) last <- do.call(rbind, by(temp...

setHook and lattice
Jim Price · Feb 29, 2008 · r-help

Hi, I am trying to find a way to automate production of page numbers in plots produced using the lattice package. To do this, I started playing around with setHook which works fine with vanilla plot, but the hook 'plot...

Lattice: Feature Request
Jim Price · Mar 11, 2011 · r-help

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, between = list(x = 0.2, y = 0.2), scales = list...

Re membering the last time an event occurred within a dataframe
Jim Price · Jul 3, 2008 · r-help

All, I am constructing a pharmacokinetic dataset and have hit a snag. The dataset can be demonstrated in the following way: myData <- data.frame( evid = c(1, 0, 0, 0, 1, 0, 1, 1, 1, 0), time = 1:10, last...

Fitting large titles in a plot
Jim Price · Dec 6, 2007 · r-help

I wrote a little utility function for exactly this reason, which I use with long titles. You may want to add calls to par to adjust the upper margin if you are using raw graphical functionality (plot et al) - but...

Bold greek letters using plotmath
Jim Price · Mar 23, 2010 · r-help

I'm trying to annotate some graphics using plotmath and finding out that the code I'm using isn't bolding the greek letters - it bolds the rest (once I adjusted the numerics to characters), it's just failing on...

Fitting large titles in a plot
Jim Price · Dec 6, 2007 · r-help

I have learned something new - thanks for the strwrap info. The problem with posting from Nabble is that by the time your post actually gets to the list (2 hours after you posted it in this case) and you've...

xyplot: subscripts, groups and subset
Jim Price · May 16, 2008 · r-help

I have stumbled across something in the Lattice package that is vexing me. Consider the code below: __________________________________________________________ library(lattice) myData <- expand.grid(sub = factor(1:16), time = 1:10) myData$observed <- rnorm(nrow(myData)) myData$fitted <- with(myData, ave(observed...

Plotting lines to sets of points
Jim Price · Sep 7, 2007 · r-help

# Create a matrix of ball locations # You'd do this using the calls within your points function balls <- matrix(c(0,50,25,-150,-100,-50), ncol=2, byrow=F) # Draw a line from the origin to each ball location...

testInstalledBasic question
Jim Price · May 5, 2010 · r-help

Hi, I'm currently in the process of writing an R-installation SOP for my company. As part of that process I'm using the recommendations from the 'R Installation and Administration' document, section 3.2, "Testing an installation". This...

summarizing dataframe at variable/factor levels
Jim Price · Jul 5, 2007 · r-help

my.data <- data.frame( trts <- rep(c('Drug 1','Drug2'), each = 10), doses <- rep(c('Low dose','High dose'), 10), resp <- rnorm(20) ) tapply(my.data$resp, list(my.data$trts, my.data$doses), mean) Jim Afshartous, David wrote: > > > All...

Changing graphics height when using grid and lattice
Jim Price · Jun 28, 2007 · r-help

Hi, I have recently been playing with the grid package in an attempt to create some pages containing multiple lattice plots on the same page. However, when I specify a grid layout with different widths, such as: pushViewport(viewport(layout...

Splitting device for ggplots?
Jim Price · Nov 3, 2008 · r-help

You could write a function to get rid of a lot of the grunt work; for example (this using lattice instead of ggplot, but should be pretty much the same): library(lattice) library(grid) graphics.off() myPlot1 <- xyplot(1 ~ 1...

Adding text to page margin with lattice graphics
Jim Price · Apr 7, 2011 · r-help

Hey Dennis, As you've undoutedly discovered, par and lattice don't play well together, because they're different graphics systems. Most of the par-esque functionality can be found in: library(lattice) names(trellis.par.get()) You can then...

Lattice: Feature Request
Jim Price · Mar 10, 2011 · r-help

Hi, I'm currently designing some global themes for use with lattice, and have hit a snag. There doesn't appear to be (in xyplot at least) a way of setting a lattice option for the 'scales' parameter at a...

Can't find what you're looking for? Try searching with Google .