Skip to content
Prev 101 / 696 Next

[R-sig-dyn-mod] Vectorizing

This is all very helpful--thanks to both you and Thomas 

Believe me, I'm not going to try ABM with R--that seems way above my pay grade--I'll be happy if I can do some basic simulations of populations with R.  (I leave my ABM work to AnyLogic and commercial packages)

Thanks again --

E. Michael Foster
Professor, Department of Health Care Organization and Policy 
School of Public Health 
The University of Alabama at Birmingham 


-----Original Message-----
From: r-sig-dynamic-models-bounces at r-project.org [mailto:r-sig-dynamic-models-bounces at r-project.org] On Behalf Of Stephen Ellner
Sent: Monday, November 07, 2011 9:39 AM
To: r-sig-dynamic-models at r-project.org
Subject: [R-sig-dyn-mod] Vectorizing

Unfortunately, the only method I know for mastering vectorizing is practice, practice, practice, after looking at the pointers that Thomas suggested. The PDE application that I described worked in R because it was possible to compute once-and-for-all matrices such that all the calculations needed to compute approximate spatial derivatives were done with two matrix-vector multiplications (one each for first and second derivatives). I have very little experience with ABMs, so I don't know how frequently there are tricks like that which make loops go away. Maybe others on this list can provide some examples? 

Steve Ellner
Stephen P. Ellner (spe2 at cornell.edu)
Department of Ecology and Evolutionary Biology Corson Hall, Cornell University, Ithaca NY 14853-2701
Phone (607) 254-4221    FAX (607) 255-8088
* This is my work email. I try not to read it at other times *

_______________________________________________
R-sig-dynamic-models mailing list
R-sig-dynamic-models at r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-dynamic-models