[R] Covariance-Variance Matrix and For Loops

R. Michael Weylandt <michael.weylandt@gmail.com> michael.weylandt at gmail.com
Fri Sep 30 21:11:29 CEST 2011


I don't have access to older versions of R right now, but if you have a recent install you are probably running 2.13.1 or 2.13.0. Can you run the following:

X <- list(a= rnorm(5), b= rnorm(5))
sapply(X, min)

?

sapply calls simplify2array() so if this works take a look at the code for sapply (just type the name with no parentheses) and see if the function perhaps has a different name for some reason. 

Michael

On Sep 30, 2011, at 1:54 PM, sf1979 <simonfuller9 at gmail.com> wrote:

> Thank you Michael.
> 
> I think my initial problem may have been due to a 'clerical error' upriver,
> so I appreciate you taking the time to give me this help.
> 
> Unfortunately, my version of R does not contain simplify2array() and does
> not find it in help (?simplify2array) - which is strange because I just
> installed it recently. (RStudio on Linux64).
> 
> I am hoping that it is fully updated soon.
> 
> Thank you also for your reading suggestions - it had not even occurred to me
> to check S books as well as R.
> 
> 
> 
> --
> View this message in context: http://r.789695.n4.nabble.com/Covariance-Variance-Matrix-and-For-Loops-tp3859441p3860580.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list