search for: stripplot

Displaying 20 results from an estimated 55 matches for "stripplot".

2010 Jun 17
2
Multiple plots in a single page and stripplot()
I want to make a 2x2 plot on a single page, using stripplot() and boxplot(). I tried the following two alternatives with mfrow() and layout(), but none of them worked. library(lattice) par(mfrow=c(2,2)) boxplot(X1 ~ Y, data=tst1, horizontal=T, las=1) boxplot(X2 ~ Y, data=tst1, horizontal=T, las=1) stripplot(Y ~ X1, data=tst1) stripplot(Y ~ X2, data=tst1) p...
2011 Jan 27
1
How to xyplot without borders
...#39;,'FG','FH','FI'))) library(lattice) graf.my.label <- xyplot(my.factor ~ quantil, data = my.label, aspect = 'fill',xlab = "",ylab='',xlim=c(0,103), scales=list(x=list(alternating=0 ),tick.number = 2,tck=0), panel = function(x, y) { panel.stripplot(x[1], y[1], pch=19, col='skyblue',cex=1.3,xaxt='n') panel.stripplot(x[2], y[2], pch=19, col='red',cex=1.3,xaxt='n') panel.stripplot(x[3], y[3], pch=19, col='chocolate',cex=1.3,xaxt='n') panel.stripplot(x[4], y[4], pch=19, col='blue',cex=1.3,x...
2012 Jun 29
3
Data scaled by lattice::stripplot
For the following example, > library(lattice) > df<-data.frame(i=1:100,p=runif(100),id=rep(c('a','b'),100)) > summary(df[,'p']) Min. 1st Qu. Median Mean 3rd Qu. Max. 0.01165 0.33580 0.57520 0.53290 0.74540 0.98610 > stripplot(p~i|id,df) The plot that is output is as expected with the exception that the values are scaled by a factor of 100 in the plot (and the yaxis has too many labels) -- see attached screenshot. I'm running R.2.10 under Ubuntu 10.04. Why does this happen and how do I get the stripplot to plot t...
2003 Jan 15
2
[lattice] lines for stripplot (like dotplot) or jitter for dotplot?
I'd like to use stripplot for some plots because I want to use the jitter parameter. On the other hand, I'd like to use dotplot because I'd like to have the horizontal lines that it includes. dotplot doesn't have a jitter option and I'm not having any success with getting panel.grid(h=-1) with stripplot. C...
2006 Dec 05
1
Horizontal stripplot
I have a plot similar to the following library(lattice) stripplot(1:15, rep(1:3, each=5)) In order to save space for a presentation, I would like to have horizontal strips instead of vertical. The argument 'horiz' turns the arguments around, but not the plot. The documentation for 'stripplot' ('xyplot'), 'panel.stripplot' and the...
2004 May 04
1
Simple lattice graphics question
Dear all, I am using panel graphics to do a stripplot of a variable versus a shingle and putting a loess curve on the stripplot. I want the data jittered, but I can't seem to get the panel function to work. This jitter's the data, but of course doesn't give me the loess: > stripplot((g[,3]) ~ c,jitter=T,pch=".",scales=list(...
2009 Sep 26
1
Lattice, stripplot (xyplot), plotting data with median line, numeric x-axis
All, On p.52 of Deepayan Sarkar's Lattice book there is a nice plot of showing residuals with median lines superimposed or various groups: library("lattice") stripplot(sqrt(abs(residuals(lm(yield~variety+year+site)))) ~ site, data = barley, groups = year, jitter.data = TRUE, type = c("p", "a"), fun = median) Suppose we wanted to make a similar plot for a numeric x-axis. Is there any way to do this with stripplot or does one have to xyplot...
1999 May 12
0
Problem with stripplot
I have had a problem with stripplot. Documentation does say that method ="stack" is only appropriate for granular data, but I don't think that means it should fall over. > difference [1] 2.0 1.3 2.8 -2.6 -0.4 -0.4 -1.2 -1.4 -1.0 1.2 -2.6 -1.9 > stripplot(difference) > stripplot(difference,method="jit...
2011 Apr 23
1
Vertical bwplot and stripplot
Hi, I'd like to change the default orientation of bwplot() and stripplot() so the plots are displayed vertically. Passing horizontal=FALSE into stripplot in the simple code below doesn't seem to be the answer. library(lattice); x <- rnorm(100); y <- as.factor(sapply(1:100, function(k) sample(c("A","B","C"), 1, prob=c(1/2, 1/3, 1...
2004 Sep 24
2
bwplot panels like stripplot
I would like to plot horizontal box-and-whisker plots in lattice where each factor has its own panel and scales are "free." Below is a stripplot version of what I have in mind. Substituting "bwplot" doesn't work. I know it's gotta be simple but I can't find the way . . . x <- c(runif(100, 0, 1), runif(100, 1, 2), runif(100, 2, 3)) y <- c(rep("First", 100), rep("Second", 100), rep("Thir...
2008 Nov 14
1
Splitting a lattice stripplot across several pages
Hello, I have a stripplot with 200+ labels i.e i have network connections. The y-axis are the server port numbers and am graphing the number of packets in a connection. Roughly stripplot(totpacks~portnum,data=network) Due to the large number of server ports in my dataset, the y-axis labels overlap so I would like to...
2006 Dec 16
1
Seeking advice on lattice package in R2.4.0 concerning stripplot
Dear all, I am using the R 2.4.0 environment on Windows XP SP2 machine and trying to use the lattice package version 0.14-9 which you have kindly written to share with the R community. I have a question concerning the stripplot which I'd be very grateful if you can kindly advise me on: I used the dataset called trydata to plot a graph using stripplot (dataset attached), and the scripts used to procude the plot is as follows: trydata<-dget("trydata") stripplot(Position~Count|y*Grouping,jitter=T,group=su...
2001 Apr 02
0
Stripplot - multiple plotting characters
Hello I'm using R 1.2.1 on Windows. I can't understand how to set up two different plotting characters within a stripplot graph. I would use plot(), but I want to use the 'stacking' option in stripplot as the overplotting is quite severe: patch <- factor(rep(c("S", "M", "B"), c(7, 7, 7))) struc <- c(4,6,6,8,8,8,12,4,6,6,6,8,10,10,6,6,6,8,8,8,8) occur <- c(0,0,0,1,1,0,1,...
2005 Jun 28
3
Help with stripplot
...hom', 67,'hom'), .Dim=c(2,98)))); colnames(dataFrame) <- c('marbles_buried', 'genotype'); dataFrame[c("marbles_buried")] <- lapply(dataFrame[c("marbles_buried")], function(x) as.numeric(levels(x)[x])); trellis.par.set(theme = col.whitebg()); stripplot(jitter(marbles_buried) ~ genotype, data = dataFrame, aspect = 1, jitter = TRUE, xlab='Genotype', ylab = "Marbles Buried", main='MBA WTs Vs HOMs'); Thanks, Sandeep Kumar Ghosh Lexicon Genetics, Inc., 8800 Technology Forest, The Woodlands, TX 77380 (281) 863-3479 Internal...
2010 May 27
1
stripplot, lattice
hello, i can't figure out how to set position of panels of my stripplot - i`d like the panels of one level of the factor stage (nr. of panels within each stage, A: 12, B: 12, C: 12, D: 4, each panel representing a site) to be in one column, with A to D from left to right and with descending site.nr at each row. like: A1 B1 C1 D1 A2 B2 .. .. A3 .. .. .. how is thi...
2006 Jun 01
3
Key titles in Lattice
...eature, but I might be abusing the title arg for key. I'm using R Version 2.3.0 (2006-04-24) on Windows XP and lattice V0.13-8 Thanks, Max library(lattice) testData <- expand.grid( A = letters[1:2], B = letters[3:4], C = letters[5:6]) testData$y <- rnorm(dim(testData)[1]) stripplot( y ~ A|B, data = testData, groups = C, panel = function(x, y, groups, subscripts) { group.values <- sort(unique(groups)) for (i in seq(along=group.values)) { id <- (groups[subscripts] == group.values[i]) current.val <- group.values[i]...
2007 Mar 20
1
lattice key (legend) with both points and lines
Hello, I'm running into a frustrating problem with the legend on a lattice plot I'm working with. The plot is a stripplot with a panel.linejoin () line running through the mean of each of the categories. Thus there are both points and lines in the plot. In trying to make a key for the plot, I can't figure out how to make a legend for both the points and the lines. What I'd like is something like: price...
2008 May 01
1
Locale problem with umlauts in factor levels in 2.7.0 (patched) from grid or lattice
With 2.7.0 patched (not tested with 2.0.0), I get an error message in a program that ran correctly in R 2.6.2 when the grouping factor of a stripplot contains an Umlaut: I am aware that there are a few locale-changes in R 2.7.0, but I could not easily locate who's at fault Dieter library(lattice) dt = data.frame(x=rnorm(100),y=1:100,levs= as.factor(c("Gru","Gr?"))) stripplot(x ~ y|levs, data = dt) #Error in grid.Call.g...
2011 Jan 26
1
text labels in Trellis plot
...adding the labels with the text() function. Hence, the following does what I want: a <- runif(3) plot(a, type="n") text(a, labels = c("dog", "cat", "mouse")) Here is the problem - I need to do this in a Trellis plot. So, something like library(lattice) stripplot(a ~ b | c) The question is how to get the points replaced by the text labels. Certainly the following works, and generates an empty Trellis plot: stripplot(a ~ b | c, type="n") but now I can't seem to figure out how to use the text() function to add in the labels, specifically, how...
2008 May 06
2
Lattice problems / cannot load lattice
...t.table?, ?bwplot.formula?, ?bwplot.numeric?, ?densityplot.formula?, ?densityplot.numeric?, ?dotplot.formula?, ?dotplot.array?, ?dotplot.default?, ?dotplot.matrix?, ?dotplot.numeric?, ?dotplot.table?, ?histogram.formula?, ?histogram.factor?, ?histogram.numeric?, ?qqmath.formula?, ?qqmath.numeric?, ?stripplot.formula?, ?stripplot.numeric?, ?qq.formula?, ?xyplot.formula?, ?levelplot.formula?, [... truncated] Error: package/namespace load failed for 'lattice' --- cut here --- R-System info: arch x86_64 os linux-gnu system x86_64, linux-gnu status major 2 m...