s-news
[Top] [All Lists]

list to data.frame

To: <s-news@lists.biostat.wustl.edu>
Subject: list to data.frame
From: "Heymans, MW" <mw.heymans@vumc.nl>
Date: Tue, 18 Apr 2006 07:35:03 +0200
References: <B8CF0F16EE1E1B42854D9ACCEB606864273F93@vumc-mb01.vumc.nl>
Thread-index: AcZiG7sIhGbdmbYeSZuGjtZXX8pSqQAjhygl
Thread-topic: list to data.frame
Dear s-list,
 
I have the following list as output, with different variable names and values within each list component:
[[1]]:
 Intercept          TS         BMI       PIB    RDQ.L.2
  3.234952 -0.03115679 -0.05632398 0.1436319 -0.8185403
[[2]]:
 Intercept       PIB    RDQ.L.2
 0.5690662 0.1674238 -0.9336926
[[3]]:
 Intercept   RDQ.L.2
  1.580426 -1.093511
[[4]]:
 Intercept      PIB   RDQ.L.2
 0.8709023 0.122212 -1.291859
[[5]]:
 Intercept       PIB  RDQ.L.2
 0.7874391 0.1582175 -1.43464
[[6]]:
 Intercept        BAE   RDQ.L.2
  3.526016 -0.2153779 -1.327692
 
Help is appreciated how to transfer this list into a data.frame / matrix with variable names on top of the data.frame / matrix. The order of the variable names has to be:

[1] "Intercept" "BAE" "TS" "BMI" "PIB" "RDQ.L.2"

Thanks!
 
Martijn
VUmc, Amsterdam
 
 
<Prev in Thread] Current Thread [Next in Thread>