Displaying 20 results from an estimated 2000 matches similar to: "Titles on lattice colorkey"
2012 Jun 16
2
Adding title to colorkey
A recent paper on visualisation (in Neuron, a leading neuroscience
journal) surveyed how well previous articles in this journal labelled their
graphs (e.g. axis labelling and describing their error bars).  Of
particular interest is that (only) 40% of plots labelled what their
colorkey was showing (variable and units).
The paper is at http://dx.doi.org/10.1016/j.neuron.2012.05.001
R is not yet
2007 Oct 23
1
Custom colourkey spacing in levelplot, contourplot
Dear R gurus,
I have got stuck on how to customise the colorkey generated by
levelplot and contourplot, in the lattice package. This best
illustrated by an example:
library(lattice)
levelplot(volcano^20/1e45,at=c(0,0.001,0.01,0.1,1,10))
The reason for raising the volcano dataset to the 20th power is to
create a dataset with a large vertical exaggeration - this is similar
in nature to the data
2004 Feb 11
1
levelplot colorkey
Dear R'ers,
I've scanned available documentation and the web, but I can't seem to 
figure out where I've gone wrong in adding numbers to scale the colorkey in 
levelplot (Lattice package).  For example,
levelplot(z, contour=T, labels=T, cuts=10, region=T,...
            colorkey=list(T, space="bottom",
                           at=seq(0,2000,length=20),
               
2012 Jun 16
2
aligning axis labels in a colorkey from levelplot
R does a great job with the fine details regarding plots.  e.g in the
following:
library(lattice)
y <- -4:4/10
xyplot(y~1, las=1)
the y axis is labelled with numbers -0.4, -0.2, 0.0, 0.2, 0.4 with the 
numbers aligned on the decimal point.
How do I get the same behaviour in the colorkey of a levelplot?  e.g.
levelplot(matrix(y,3,3))
the numbers in the colorkey seem left-aligned, and
2010 Mar 19
1
One main title and One legend for multiple lattice plots
Hi All,
Can anyone please help me with getting a "single title" and "legend" for
both the plots in the following R code. I'll eventually be using .wmf file.
# R code:
library(lattice)
p1 <- xyplot(decrease ~ treatment, OrchardSprays, groups = rowpos,
       type = "a", main="Same title / legend",
       auto.key = list(space = "right",
2008 Jun 13
1
Level Plot and Scale of Colorkey
I am drawing level plots but I would like to specify the range of the colorkey, I am not having any success figuring this out so any help would be greatly appreciated!
Here is an example of what I am trying to do:
disp<-1
x <- seq(1, 10,by=1) 
y <- seq(1,10,by=1)
g <- expand.grid(x = x, y = y)
g$z <- 1/exp((abs(g$x-5)+abs(g$y-5))*disp)
g$z<-g$z/sum(g$z)
levelplot(z ~ x * y,
2012 Jan 06
1
Can levelplot colorkeys display a logarithmic scale evenly?
I'm using the {lattice} "levelplot" function to make a (more or less) 2-d 
histogram, and for the most part it's working fine with my data.  However, I 
can't get the color key to do what I need.  I can give it labels and custom 
cutoffs, but my cutoff lines (and hence my labels) aren't evenly spaced, instead 
they're more-or-less logarithmic, starting at
2010 Sep 29
1
move colorkey
When using a wireframe, I need to move the colorkey from the "right"
position (default0 towards the plot.  I have also needed to adjust the
height and used the code
colorkey=list(T,space='right',height=.5)
I have looked at documents (within levelplot) but cannot find a way to
move the colorkey other than right, left, bottom and top.  I do not
understand corner interacts with x,
2012 May 29
1
lattice: add a marginal histogram on top of the colorkey of a levelplot?
Lattice experts:
Can you think of a way to produce a levelplot as below and then add a histogram of the z variable to the top margin of the plot that would sit on top of the color key?
x <- seq(pi/4, 5 * pi, length.out = 100)
y <- seq(pi/4, 5 * pi, length.out = 100)
r <- as.vector(sqrt(outer(x^2, y^2, "+")))
grid <- expand.grid(x=x, y=y)
grid$z <- cos(r^2) *
2002 Aug 13
1
interaction.plot() legend too narrow when mfcol > 2 (PR#1899)
Here is an example:
 The legends (mainly the factor level names) are cut off on the
 right.  Somehow the internal calculation which computes
 horizontal space for the legend is not flexible enough.
## Call a new graphics window {with default par()s !}:
get(getOption("device"))()
par(mfrow = c(2,2))
## part of  example(interaction.plot)  _improved_ using with() :
data(OrchardSprays)
2013 Feb 04
1
is it possible to create a trellis object with multiple colorkeys/z-scale axis?
Dear R users-
Do the lattice/latticeExtra packages support multiple tileplots with unique
colorkeys? I am trying to create a visualization of the encounter rate of
certain stocks of salmon across two years. The issue I am having is that
some stocks are encountered at much higher rates than others.the high
encounter rate for one stock washes out the patterns I'm hoping to visualize
across the
2010 Mar 25
4
3 levelplots and 1 colorbar
I want to create a simple plot containing three levelplots with one colorbar.
I used the "Three levelplots" code below, but the third levelplot is drawn
smaller than the first two. However, if I try the "Two levelplots" code below
it works well. Can anybody tell me how could I draw three levelplots (of the
same size) with one colorbar.
Thanks in advance, Joaquin
### Three
2014 Jun 10
2
Como controlar la altura de "colorkey" en levelplot de RatserVis
Hola miembros de la lista,
Estoy utilizando la función levelplot del paquete rasterVis para graficar
un raster y quiero controlar la altura de la referencia de color (colorkey)
del mapa, pero cuando cambio valores en el argumento "height" no parece
provocar cambios.  Alguna idea de por qué no está funcionando?
> cobertura
class       : RasterLayer
dimensions  : 780, 1296, 1010880 
2010 May 24
1
lattice 'scales' option help
Hi All,
I'm trying to draw boxplots. I'm having a hard time to get "ticks labels" on
multiple panels using 'alternating' option.
# R Code:
# May not be the best example, please just look into 'scales' option
library(lattice)
data(OrchardSprays)
dta <- subset(OrchardSprays, OrchardSprays$rowpos %in% c(1,2,3))
# Original
# This works fine, as you can see
2010 Jan 06
1
How do I upside down colorkey of levelplot?
Hi, all.
I made the main figure of levelplot upside down by transposing and
proper indexing; upper left corner is the biginning of matrix.
However, I can't figure out how I can upside down the vertical
colorkey right side of the main figure.
Any help will be greatly appreciated.
Minho
2011 Sep 13
1
stupid lm() question
I feel bad even asking, but:
Rgames> data(OrchardSprays)
Rgames> model<-lm(decrease~.,data=OrchardSprays)
Rgames> model
Call:
lm(formula = decrease ~ ., data = OrchardSprays)
Coefficients:
(Intercept)       rowpos       colpos   treatmentB   treatmentC
      22.705       -2.784       -1.234        3.000       20.625
  treatmentD   treatmentE   treatmentF   treatmentG   treatmentH
  
2012 Oct 10
2
se's and CI's for fitted lines in multivariate regression analysis
I?m entirely stumped on this particular issue and really hoping someone has
some advice for me.
 
I am running a covariant model in lm I would like to give the standard
errors or the confidence intervals for the fitted lines. I?ve been using the
dataset OrangeSprays where I want lines for each level of treatment over the
covariant ?colpos?. I?ve been able to calculate intercepts and slopes for
2004 Apr 27
1
helps on levelplot
I'm a new user of levelplot, and are not familiar with the terminology 
very well. Is the bar alongside the levelplot indicating color or shade 
call "colorkey"? I have to adjust the size of its label, but couldn't 
make it so far. This is how I did:
levelplot(z~x*y, grid, at=seq(0,1,by=0.1), 
colorkey=list(labels=list(cex=2)))
But I got error message "Error in
2013 May 03
1
print multiple plots to jpeg, one lattice and one ggplot2
hello everybody,
I want to print two plots in one png file, I tried several options but i
didn't succeed
the first plot (bwplot) print to the defined position, but the second
(ggplot) doesn't
Any idea?
Thanks a lot
Christophe
#   Example:
#-------------------------------------
library(ggplot2)
library(lattice)
library(grid)
one <- bwplot(decrease ~ treatment, OrchardSprays, groups
2006 Mar 04
0
"Continuously colored" colorkey
Hi,
I use the levelplot function of the lattice library with the option  
col.regions=gray(200:400/400) in order to get a "color-grid" of 201  
different gray colors (actually if you look at the vector, some  
consecutive colors are the same). In order to make the colors in the  
colorkey as "smooth/continuous" as possible I use the maximal number  
which is possible for the