similar to: help with formatting legend in xyplot

Displaying 20 results from an estimated 9000 matches similar to: "help with formatting legend in xyplot"

2003 Sep 09
2
lattice.xyplot: adding grid lines
Hallo, I'd like to add grid lines to a lattice graph having 2 series of Y data. See these 2 examples: data(iris) [1] xyplot(Sepal.Length + Sepal.Width ~ Petal.Length , data = iris, allow.multiple = TRUE, scales = "same",type="l", ) [2] xyplot(Sepal.Length + Sepal.Width ~ Petal.Length , data = iris, allow.multiple = TRUE, scales =
2007 Apr 20
1
xyplot: Combining 'subscripts' and 'allow.multiple=T'
Dear all, Consider this plot xyplot(Sepal.Length + Sepal.Width ~ Petal.Length | Species, data = iris, allow.multiple=T, outer=F, panel = function(x,y,...) { panel.xyplot(x,y,...) } ) I want to *add* some things to each panel and what I want to add involves using the data for each panel, so I try to take this subset of data out with subscripts:
2006 Nov 15
1
trellis.par.set and grid : how to set by default that I want a grid on my graphes ?
Hello all, I want to draw a grid behind my graphes, using lattice package. I manage to do it with instructions like this one : xyplot(Sepal.Length + Sepal.Width ~ Petal.Length , data = iris, allow.multiple = TRUE, scales = "same",type="l", panel = function(...) { panel.grid(h=-1, v= -1) ; panel.superpose(...) } ) I was wondering if there were a way to do it
2004 Jan 15
5
Lattices: Cloud: Background
Hi, There's probably some simple way of doing this, but I'm just not seeing it - How do I get the background to be white instead of grey when I have a cloud plot (using the lattices package)? par(bg="white") isn't working. I'm assuming par commands won't work on lattice plots. What should I use instead? Thanks, Adrienne [[alternative HTML version deleted]]
2009 Oct 25
1
different plot symbols in key using xyplot
I'm using xyplot in a very simple way---a scatter plot of several data sets. I'm having a problem getting auto.key to display different point characters. The following produces a plot that employes different colors, all with pch(1), for the different groups, with a matching key. xyplot(Force~Time, rawData, groups=Sample, panel = panel.superpose, auto.key=TRUE) The following
2009 Apr 07
1
Lattice Groups
Hi all, I'm trying to achieve a few things using the lattice package but am failing miserably. I am plotting side by side box plots and using a grouping variable, e.g. cols <- c("Sepal.Width", "Petal.Length", "Petal.Width") stackedData <- stack(iris[, cols]) df <- data.frame(y = stackedData$values, x = rep(iris$Species, 3), which = gl(3,
2011 Jul 28
2
not working yet: Re: lattice overlay
Hi Dieter and R community: I tried both of these three versions with ylim as suggested, none work: I am getting only single (pch = 16) not overlayed (pch =3) everytime. *vs 1* require(lattice) xyplot(Sepal.Length ~ Sepal.Width | Species , data= iris, panel= function(x, y, subscripts) { panel.xyplot(x, y, pch=16, col = "green4", ylim = c(0, 10)) panel.lmline(x, y, lty=4, col =
2010 Jan 06
1
xyplot: adjusting the scale (min, max & tick)
Hi, I'm terribly sorry but it seems it cannot figure this one out by myself so, please, if somebody could help I would be very grateful. So, when I plot with xyplot() I get an y-axis that is very ugly... starting from a random number and having so many ticks that it becomes unreadable. How do I tell xyplot how to draw the axis? E.g., start from 100, end at 200 with 25 units between
2010 Mar 07
1
xyplot: strip size
Hi, I was wondering if there is a way to control the strip size in xyplot for example using the strip.default function. Or do I need to redraw the strips by myself? I would like to make the strip slimmer and I have reduced the font size using cex. However, I don't know how to change the size of the strip. Thanks for any tips. Hadassa [[alternative HTML version deleted]]
2004 Sep 01
1
Tick marks in cloud (lattice)
Hi! Probably a simple question, but I can't get any tick marks in the 3d scatterplot I created using the cloud function. The following works to display the three groups using different symbols: data(iris) cloud(Sepal.Length ~ Petal.Length * Petal.Width, data = iris, cex = 1.2, groups = Species, pch = c(16,1,1), col = c("black","black","red"), subpanel =
2008 Apr 22
2
cloud plot has white(transparent?) background
I am using the code example from the R graph gallery to look at a cloud plot: require(lattice) data(iris) print(cloud(Sepal.Length ~ Petal.Length * Petal.Width, data = iris, groups = Species, screen = list(z = 20, x = -70), perspective = FALSE, key = list(title = "Iris Data", x = .15, y=.85, corner = c(0,1), border = TRUE,
2008 Jul 31
1
strip names lattice graphics
R-helpers, I'm having difficulty with customizing strip names for a lattice graphic. Here is an example using the iris data set : xyplot(Sepal.Length+Sepal.Width~Petal.Length,groups=Species,data=iris) ## I'd like to change the 2 strip names to "Length" and "Width" for example, this is what I've tried :
2011 Feb 10
2
Calling symbols from dataframe for xyplot
Hello, I am trying to make a xyplot plot with points that are different symbols. I want to call the symbol type (pch) from a column in my dataframe. Here is a simplified example. In my real example I also have groups, which I have not included here. This example doesn't change the symbols or colors. Any help you can provide would be appreciated. Thanks, John x<-c(1:12)
2011 Jul 26
2
Lattice: choice of symbol and symbol position in legend
I am making final adjustments to a multi-plot figure using basic and lattice. In the lattice plot, I would like to include a legend that matches the format of the legends in the other plots, which consist of appropriately colored squares (pch 22) followed by text. In lattice, I was able to get a legend using auto.key = list(x = .6, y = .6, corner = c(0, 0), pch=22) but my request for pch=22 was
2012 Jul 30
1
lattice legen and auto.key conflict
Hello R-helpers, I'm trying to customize a graphic in lattice using the 'legend' argument to add labels on my plot but in the process I'm losing the legend drawn by 'auto.key', despite the fact that I'm actually not sticking these on the same sides of the graphic. I worked up a quick and simple example with the iris data : ### here's the basic graph
2012 Aug 01
3
Neuralnet Error
I require some help in debugging this codeĀ  library(neuralnet) ir<-read.table(file="iris_data.txt",header=TRUE,row.names=NULL) ir1 <- data.frame(ir[1:100,2:6]) ir2 <- data.frame(ifelse(ir1$Species=="setosa",1,ifelse(ir1$Species=="versicolor",0,""))) colnames(ir2)<-("Output") ir3 <- data.frame(rbind(ir1[1:4],ir2))
2006 May 31
2
a problem 'cor' function
Hi list, One of my co-workers found this problem with 'cor' in his code and I confirm it too (see below). He's using R 2.2.1 under Win 2K and I'm using R 2.3.0 under Win XP. =========================================== > R.Version() $platform [1] "i386-pc-mingw32" $arch [1] "i386" $os [1] "mingw32" $system [1] "i386, mingw32" $status
2008 Oct 13
2
split data, but ensure each level of the factor is represented
Hello, I'll use part of the iris dataset for an example of what I want to do. > data(iris) > iris<-iris[1:10,1:4] > iris Sepal.Length Sepal.Width Petal.Length Petal.Width 1 5.1 3.5 1.4 0.2 2 4.9 3.0 1.4 0.2 3 4.7 3.2 1.3 0.2 4 4.6 3.1 1.5
2012 Jun 11
1
saving sublist lda object with save.image()
Greetings R experts, I'm having some difficulty recovering lda objects that I've saved within sublists using the save.image() function. I am running a script that exports a variety of different information as a list, included within that list is an lda object. I then take that list and create a list of that with all the different replications I've run. Unfortunately I've been
2012 Jul 31
1
kernlab kpca predict
Hi! The kernlab function kpca() mentions that new observations can be transformed by using predict. Theres also an example in the documentation, but as you can see i am getting an error there (As i do with my own data). I'm not sure whats wrong at the moment. I haven't any predict functions written by myself in the workspace either. I've tested it with using the matrix version and the