search for: superpose

Displaying 20 results from an estimated 386 matches for "superpose".

2006 Jun 01
3
Key titles in Lattice
...sort(unique(groups)) for (i in seq(along=group.values)) { id <- (groups[subscripts] == group.values[i]) current.val <- group.values[i] panel.stripplot(x[id], y[id], jitter.data = FALSE, horizontal = FALSE, col = trellis.par.get()$superpose.symbol$col[i], pch = trellis.par.get()$superpose.symbol$pch[i]) panel.linejoin( x[id], y[id], horizontal=F, col = trellis.par.get()$superpose.symbol$col[i], lty = trellis.par.get()$superpose.line$lty[i], lwd = trellis.par.get()...
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 we use the panel.superpose function...
2005 Jul 25
1
order of panels in xyplot
...eft instead of left to right, as it says in the help files, which is what I would like. Does anyone know if this has been changed? OR has anybody encountered this problem and a way of fixing it? Below is the code I'm using (ctry_pfi and v291 are factors, with 16 and 2 levels, respectively)): superpose.line <- trellis.par.get("superpose.line") superpose.line$lwd <- 3 superpose.line$lty <- c(1,2) trellis.par.set("superpose.line", superpose.line) trellis.strip.blank() trellis.par.set(list(background = list(col = "white"))) xyplot(pfi~age|ctry_pfi,groups...
2001 Nov 28
3
trellis plot
Hi, I'd like to plot 4 groups of data using xyplot and panel.superpose so that the points are overlayed on a single plot. For each group of data I'd also like a loess smoothed function (using panel.loess). I have tried the following: xyplot(series ~ time | gr, data=etable, panel = function(x,y, ...) { panel.superpose(x,y, ...) pan...
2011 Mar 15
1
Bug in lattice auto.key argument
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] grid_2.12.2 If I set up my plot parameters as require(lattice) superpose.line.settings <- trellis.par.get("superpose.line") str(superpose.line.settings) superpose.line.settings$col <- 1 superpose.line.settings$lty <- c(1,2,5) ***** superpose.line.settings$lwd <- 2 trellis.par.set("superpose.line",superpose.line.settings) and then se...
2003 Aug 29
2
Lattice plot questions
...ription of what is needed is vague. It is possible to address (a) by duplicating the data set twelve times and cbind()ing a factor variable so that each of the duplicated data sets is associated with exactly one of the subject id's. I have done this, and the code subjects <- foo$subject.id superpose.symbol <- trellis.par.get("superpose.symbol") xyplot(log.response ~ week | factor.variable, data = foo, panel = panel.superpose, groups = subjects, key = list(space = "top", columns = 6, transparent = TRUE, text = list(levels(subjects)), points = Rows(superpose.sym...
2008 Oct 15
2
Lattice key title color
Dear R users, is there a way to define the color of the title for the legend in lattice? The help page on xyplot has a lot of details on key options just as the new book, but no mentioning of a color attribute for the title. Should I use ltext or is there any other way? Best wishes, Erik [[alternative HTML version deleted]]
2002 May 17
1
Strange R CMD check \usage parse error
...par("lwd"), iter=ifelse(length(unique(y))>2, 3, 0), bass=0, trim, fun, group, prefix, xlim, ylim, label.curves=T, datadensity=F, lines=T, ...) xyplot(y ~ x | conditioningvars, groups, panel=panel.plsmo, type='b', label.curves=T, lwd = superpose.line$lwd, lty = superpose.line$lty, pch = superpose.symbol$pch, cex = superpose.symbol$cex, font = superpose.symbol$font, col = NULL, ...) } -- Frank E Harrell Jr Prof. of Biostatistics & Statistics Div. of Biostatistics & Epidem. Dept...
2010 Oct 19
2
superpose.polygon, panel.polygon and their colors
...per <- upper[subscripts] lower <- lower[subscripts] panel.polygon(c(x, rev(x)), c(upper, rev(lower)),...) } xyplot(est ~ x | cond, group = grp, data = data, type = 'b', upper = data$upper, lower = data$lower, panel = function(x, y, ...){ panel.superpose(x, y, panel.groups = 'panel.bands',...) panel.xyplot(x, y, ...) }) The result is a lattice object with the confidence bands painted in cyan and pink. These are the areas I would like to have in gray. I think that the cyan and pink colors come from trellis.par.get("...
2009 Jun 14
1
learning about panel functions in lattice
...p('A',30),rep('B',20)) subject<-c(rep('a',10),rep('b',10),rep('c',10),rep('d',10),rep('e',10)) myData <-data.frame(subject,group,time,y) head(myData) Plot 1 xyplot(y ~ time | group, data = myData, groups = subject, panel = panel.superpose, panel.groups = function(...) panel.loess(...) ) Plot 2 xyplot(y ~ time | group, data = myData, groups = subject, panel = function(...) { panel = panel.superpose(...) panel.groups = function(...) panel.loess(...) }) Why does Plot 2 not pro...
2003 Jan 10
1
Superposed histograms
...| o | oo o | o oo ** o o = observations of women | o o*o***o * = observations of men | *o******* |---------- (And I want this in a Trellis plot, and with more than two groups of observations.) How should I do this? I tried looking for imaginitive combinations of panel.superpose and panel.histogram. I suppose if I called panel.histogram for the cumulative data first, then panel.histogram for just the data on men, with a different colour, I could achieve the effect. But I'd need to superpose the accumulated data, and panel.superpose seems to only separate the data by g...
2005 Nov 07
2
lattice chart: different definitions for series
...should include two line diagrams(representing two of the groups) , with the third group represented only with symbols(no lines). Until now I was using white lines to eliminate the lines drawn in the third group, but this solution is not optimal, as the grids are sometimes not visible sp<-list(superpose.symbol=list(pch=c(1,2,1),col=c("blue","red","green")), superpose.line=list(col=c("blue","red","white"),lty=c(1,2,))) ... and then including print(xyplot(mct~trend.data$year,groups=clinic, scales=list(x=list(at=c(15:pno),labels=p...
2009 Feb 11
2
changing settings on a barchart (lattice)
Hello! I apologize - I never used lattice before, so my question is probably very basic - but I just can't find the answer in the archive nor in the documentation: I have a named numeric vector p of 6 numbers (of the type 6 numbers with people's names to whom those numbers belong). I want a simple bar chart. I am doing: library(lattice) trellis.par.set(fontsize=list(text=12)) #
2002 Dec 19
1
lattice and display
...but I have trouble applying colors. Here are the scripts xyplot(resultdata$Y~resultdata$X , data=resultdata,groups=resultdata$Block, panel="panel.xyplot", panel.groups="panel.xyplot", xlab="X",ylab="Y",pch="*", col.groups=trellis.par.get("superpose.symbol")$col[1:6],cex=2, key=list(space="right", points=list(pch="*", col=trellis.par.get("superpose.symbol")$col[1:6]), text=list(paste("Block",1:6))) ) xyplot(resultdata$Y~resultdata$X |resultdata$Block, data=resultdata, xlab="X",...
2009 May 08
2
display data ( text) on leveplot / Superpose panel
I am trying to display data ion top of colored rectangle on the same levelplot. While using superpose the shape and symbol for levelplot changes to small circle. I am unable to figure what exactly I am doing wrong... It may be straightforward solution... .I will appreciate help to fix this issue. brewer.div<-colorRampPalette(c("pink","green","blue","yellow&quo...
2005 Feb 10
1
xyplot() question
...symbols are used for subgroups (originally used within S-Plus, but hopefully it?s also applicable to R users). How can I fit separate regression lines for every subgroup? So far, I can only plot the overall fitted line. The code looks like this: trellis.device() sps<-trellis.par.get("superpose.symbol") sps$pch<-1:7 trellis.par.set("superpose.symbol",sps) spl <- trellis.par.get("superpose.line") ps$lty <- 1:7 trellis.par.set("superpose.line",spl) xyplot(a~b|factor+treatment, groups=external,data=ownframe,layout=c(2,2), panel=functio...
2011 Feb 21
1
wrong lines in auto.key xyplot
Hi all, I'm having a problem with the auto.key function in xyplot. I changed the symbols an lines styles using these commands trellis.par.set(superpose.symbol=list(pch=c(0,1,2,3,4,5,6,8,15,16))) trellis.par.set(superpose.symbol=list(col=c(rep("black",11)))) trellis.par.set(superpose.symbol=list(cex=c(rep(0.6,11)))) trellis.par.set(superpose.line=list(col=c(rep("black",11)))) trellis.par.set(superpose.line=list(lty=c(1,1,1,2,2,2...
2012 Apr 29
2
Xy plot help
...t;g", "p", "r"),              coef.list = df[,3:14],              panel = function(..., coef.list) {                  panel.xyplot(...)                  panel.abline(as.numeric(coef.list[packet.number(),]),                               col.line = trellis.par.get("superpose.line")$col[2],                               lty = trellis.par.get("superpose.line")$lty[2]                               )                  panel.abline(fixef(fm),                               col.line = trellis.par.get("superpose.line")$col[4],                      ...
2007 Nov 30
1
Set panel background color in a multi-group trellis plot
...the last one, as panel.fill overwrites all the previous ones. Is there any way to set the panel background color for the first panel to a color and keep the rest transparent? My code looks like this: #first set defaults for getting more distinct symbols superp.symbol <- trellis.par.get("superpose.symbol") superp.symbol$pch = 15:21 superp.symbol$cex = 1.5 trellis.par.set("superpose.symbol", superp.symbol) #set the default for the colors in the symbols superp.lines <- trellis.par.get("superpose.line") superp.lines$lty <- 1:6 superp.lines$lwd <- 1.5 trellis.p...
2006 Jul 10
2
Setting the colors of lines in a trellis plot...
...the actual plot use the colors I want. But I have been unable to find the correct incantation to make the lines of the actual plot use the colors I want. Here's the relevant section of code: mycolors <- c("black", "darkgreen", "red") mylines <- Rows(superpose.line, 1:numlines); mylines$col <- mycolors mysymbols <- Rows(superpose.symbol, 1:numlines); mysymbols$pch <- c(15:18)[1:numlines] mysymbols$col <- mycolors print(xyplot( panel = panel.superpose, log10(states) ~ size, groups=category, data=data, type='...