[R] list to array
Maciej.Hoffman-Wecker@evotecoai.com
Maciej.Hoffman-Wecker at evotecoai.com
Wed Jun 20 12:01:16 CEST 2001
Hello everybody!
I have a problem, that might be a quite common one.
Often one has some statistics on subpopulations defined by several factors.
This is usualy done by tapply resulting in a list.
For presentation-tasks, the form of an array might be more advantageos,
as ftable in combination with aperm allows for quite nice print.
Moreover some html or ps output might be easier to produce.
So this is the question: How can i transform a list of the form
list $a1 $b1 = x1
$b2 = x2
$a2 $b1 = x3
$b2 = x4
into an multy-way array, with each list-level defining a dimension of the
array:
array[a1:a2 , b1:b2]
Maybe someone has already spend some time on this.
I would be pleased about some hints.
Maciej
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list