Dear all,
Is there a reason, why there is no +-operator for aes (i.e. uneval) objects (as
there is for themes and gg objects)? I had a couple of cases where such an
operator would be useful, for instance to combine the result of aes and
aes_string in functions. Any flaws with the following prop
Dear all,
Today I figured out that the formula interface of plot.design is kind of
counter intuitive. Suppose the following setting
ddf <- expand.grid(a=factor(1:3), b=factor(1:3))
ddf$y <- rnorm(9)
plot.design(y ~ a + b, data=ddf)
which does what it should do, basically printing the means for t
> In regard to "should", I think it is a
> very very bad idea.
>
> The result that someone gets depends on
> whether or not the new package is attached
> in the session. That is a recipe for hours
> (or days) of trying to figure out mysterious
> behavior.
I fully agree. However, there are 2 reas
Dear all,
I am developing a package, which bundles my most frequently used
functions. One of those is a modified version of droplevels from the
base package (basically, it preserves any contrast function which was
used to create the factor, contrast matrices are not kept, for they
could be wrong i
> > I think this behaviour is annoying, because if one does not look
> > carefully enough, one looses the contrasts silently. Hence may I
> suggest
> > to change the code of droplevels to something like the following:
>
> This silently changes the contrasts -- eg, if the first level of the
> facto
Dear all,
Today I figured out that there is a neat function called droplevels,
which, well, drops unused levels in a data frame. I tried the function
with some of my data sets and it turned out that not only the unused
levels were dropped but also the contrasts I set via "C". I had a look
into the
> mm <- function(datf) {
>lm(y ~ x, data = datf)
> }
> mydatf <- data.frame(x = rep(1:2, 10), y = rnorm(20, rep(1:2, 10)), z
=
> rnorm(20))
>
> l <- mm(mydatf)
> update(l, . ~ . + z) # This fails, z is not found
Good point. So let me rephrase the initial problem:
1.) An lm object is fitted
Dear all,
Suppose the following code:
--8<--
mm <- function(datf) {
lm(y ~ x, data = datf)
}
mydatf <- data.frame(x = rep(1:2, 10), y = rnorm(20, rep(1:2, 10)))
l <- mm(mydatf)
-->8--
If I want to update l now without providing the data argument
Dear all,
>From the documentation of biplot.prcomp:
scale: The variables are scaled by 'lambda ^ scale' and the
observations are scaled by 'lambda ^ (1-scale)' where
'lambda' are the singular values as computed by 'princomp'.
>From the source code of prcomp:
lam <- x$sdev[choi
> Martin Maechler writes
> I have now committed the amended proposal (rev 53925);
> thank you for the feedbacks..
I had a look at it and there is a typo:
stop(gettextf("'%s' not defined for \"difftime\" objects", .Generic),
domain = NA)
should rather be
stop(gettextf("'%s' not defined f
Kurt Hornik writes
> >> if (!all(sapply(args, is.ordered)) ||
> >> !all(sapply(level.list, identical, y = level.set))) {
>
> I think it would be better to use something like
>
> ll <- lapply(args, levels)
>
> !all(sapply(ll, identical, ll[[1L]]))
>
> [using union() is not quite right]
Yes
Hi everybody,
Is there a particular reason, why this code does not work as intended:
z <- factor(LETTERS[1:3], ordered = TRUE)
u <- 4:6
min(z[u > 4])
Error in Summary.factor(2:3, na.rm = FALSE) :
min not meaningful for factors
I agree that min is indeed not meaningful for not
Hi everybody,
Currently I'm in the process of developing an R library, where I make
use of "pointLabel" in the "maptools" package. I've defined the
dependency on package "maptools" via the DESCRIPTION file in the root
directory of my library.
Since the loading of package "maptools" issues
Hi everybody,
as you may be aware the function augPred.lme does not work as soon as
the covariate is a factor. The problem lies in the line
newprimary <- seq(from = minimum, to = maximum, length.out = length.out)
which does not make sense for factors. I think augPred.lme can be useful
for models
Hello everybody,
Currently I'm developing a library, which uses some functions from
another package (namely plotrix). Consequently, I listed this dependency
in the DESCRIPTION file. When I try to run "R CMD check mypackage", the
check fails, for the library plotrix cannot be found on the system. A
Message-
From: Uwe Ligges [mailto:lig...@statistik.tu-dortmund.de]
Sent: samedi 12 juin 2010 18:21
To: Thaler,Thorn,LAUSANNE,Applied Mathematics
Cc: r-devel@r-project.org
Subject: Re: [Rd] CHM help does not find help docs in package stats
Which version of R is this?
CHM help is R < 2.10.0.
Hi all,
currently I'm working on an R package bundling some frequently used
functions. When I load my package and type
?one_of_my_functions
I get the particular help file. If I try to get help on another
function, which is part of package stats (prcomp say), I get "This
program cannot display th
17 matches
Mail list logo