In fact by fiddling with the "at" and "colorkey" options, I was able to get
the result I expected. Now the colors are assigned correctly, as well as the
colorkey. Here's my code:
# see data in the original
data$level[is.na(data$level)] <- 10 # assign a value above the scale to NA
values
levelplo
Hi,
Thank you Duncan, you showed me how to assign a specific color NA values in
the levelplot. However, I'm still not satisfied with the result of the code
you provided. In the data frame I provided in the first post, there's one
plant with level=0 (at x=8, y=1), and many other plants have level=1
Hi
If you change the NA to a value either below or above the range of
values you can then use it.
Below is something that is cobbled together from some code I have.
The datacols argument may be necessary if you want to do something
fancy like I was doing
I used my own colours to see if all w
Dear R users,
I'm currently trying to make level plots of a longitudinal study of the
spatio-temporal spread of a plant disease in a field, but the results of the
color key assignment isn't what I expect.
Here's more info. I recorded the level of a disease on an ordinal scale from
0 (no disease)
On Jan 22, 2008 8:39 PM, dxc13 <[EMAIL PROTECTED]> wrote:
>
> useR's,
>
> I want to create a "movie" of a sin function (from 0 to pi/2) using
> levelplot() in the lattice package. I basically want to create 20 or so
> plots of the sin function starting with an amplitude of 0 and ending at
> amplit
useR's,
I want to create a "movie" of a sin function (from 0 to pi/2) using
levelplot() in the lattice package. I basically want to create 20 or so
plots of the sin function starting with an amplitude of 0 and ending at
amplitude 1. By using a loop and plotting these in succession, it will have
6 matches
Mail list logo