[R] array in version 2.8.0

Rolf Turner r.turner at auckland.ac.nz
Mon Nov 3 02:29:02 CET 2008


On 3/11/2008, at 2:11 PM, David Stoffer wrote:

>
> What happened?  TIA.
>
> In version 2.7.x:
>
>> (x <- array(1:4, c(2,2)))
>      [,1] [,2]
> [1,]    1    3
> [2,]    2    4
>
>> as.array(x)
>      [,1] [,2]
> [1,]    1    3
> [2,]    2    4
>
> In version 2.8.0:
>
>> (x <- array(1:4, c(2,2)))
>      [,1] [,2]
> [1,]    1    3
> [2,]    2    4
>
>> as.array(x)
> Error: evaluation nested too deeply: infinite recursion /
> options(expressions=)?

Doesn't happen to me:

  > x <- array(1:4,c(2,2))
  > x
      [,1] [,2]
[1,]    1    3
[2,]    2    4
  > class(x)
[1] "matrix"
  > as.array(x)
      [,1] [,2]
[1,]    1    3
[2,]    2    4

My sessionInfo() is:

  > sessionInfo()
R version 2.8.0 (2008-10-20)
i386-apple-darwin8.11.1

locale:
C

attached base packages:
[1] datasets  utils     stats     graphics  grDevices methods   base

other attached packages:
[1] misc_0.0-9     fortunes_1.3-5 MASS_7.2-44

Is there another array() function hanging around in your search path?

	cheers,

		Rolf Turner


######################################################################
Attention:\ This e-mail message is privileged and confid...{{dropped:9}}



More information about the R-help mailing list