I've tried grouping the real and imaginary parts as a single complex number,
e.g.
> z1 <- complex(real=r1, imaginary=i1)
Although complex variables are not allowed in lm, I can run regsubsets just
fine:
> z <- cbind(z1, z2, z3, ..., z10)
> bestsubs <- regsubsets(z, y, nbest=1, nvmax=5, intercep
Hi,
I'd like to run regsubsets for model selection by exhaustive search. I have
a list with 20 potential explanatory variables, which represent the real and
the imaginary parts of 10 "kinds" of complex numbers:
x <- list(r1=r1, r2=r2, r3=r3, ..., r10=r10, i1=i1, i2=i2, i3=i3, ...,
i10=i10)
Is
This works:
as.expression(c(bquote(...),bquote(...)))
--
View this message in context:
http://r.789695.n4.nabble.com/superscript-tp3252881p3253145.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r-project.org mailing list
http
Thanks, jthetzel. That works. Can you plot a legend with 2 lines using
bquote? e.g.
r^2 = x
rmse = y
"," and "\n" don't seem to work.
--
View this message in context:
http://r.789695.n4.nabble.com/superscript-tp3252881p3253088.html
Sent from the R help mailing list archive at Nabble.com.
Hi there,
How can I superscript the "2" of "r2 =..." in the legend below?
legend(210, 110, paste("r2 = ",
format(summary(regression)$adj.r.squared,digits=3), sep=""))
I usually use "expression(paste(...", but it won't work this time because
"format(summary(..." needs to be evaluated.
Thank
5 matches
Mail list logo