[R-lang] apply through a list

Michael Cysouw cysouw at eva.mpg.de
Wed May 16 11:53:09 PDT 2007


a general question, not specific to linguistics...

I have a (large) set of same-size matrices M1,M2,M3,... which I  
stored in a list. How do I apply a function over the same position of  
all matrices? For example, take the sum M1+M2+M3+...

I have not found any "apply" like variant that would do the trick.  
Any suggestions?

best
michael


—————————————————————————
Michael Cysouw

Department of Linguistics
Max Planck Institute for Evolutionary Anthropology
Deutscher  Platz 6
D-04103 Leipzig

Room: U 1.14

phone:    +49 (0) 341 35 50 316
fax:          +49 (0) 341 35 50 333
home:       +49 (0) 341 22 59 488
mobile:      +49 (0) 172 18 33 507
e-mail:       cysouw at eva.mpg.de
homepage:  http://www.eva.mpg.de/~cysouw/
—————————————————————————





More information about the R-lang mailing list