Re: R-sig-ecology Digest, Vol 2, Issue 4

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Re: R-sig-ecology Digest, Vol 2, Issue 4

Nicholas Lewin-Koh

 Hi Melanie,
It has been a long time since i looked at gravity models but if I
remember correctly,
they are formulated as log linear models with a particular weight
matrix. I would guess
that that could be written as a generalized linear mixed model, and fit
with lme, or lmer, though if a parameterized covariance matrix matrix is
needed, lmer will not work. The geoRglm package is also worth a look.
And doing a search on Rseek I found that the package nettheory fits
several gravity models, I think the command is CONSTRUCT. And look at
though I don't think gravity models per say are addressed in that

You may get more mileage sending your query to R-sig-geo.

hope this helps


> ------------------------------
> Message: 3
> Date: Mon, 5 May 2008 16:35:25 -0700
> From: "Melanie Murphy" <[hidden email]>
> Subject: [R-sig-eco] Gravity (spatial interaction) models in R
> To: <[hidden email]>
> Message-ID: <000701c8af08$b29ea640$3c19a8c0@dru>
> Content-Type: text/plain
> Hi All,
> I am constructing "gravity" (spatial interaction) models in R for
> ecological application.  I have linearized the unconstrained model and
> solved using OLS.  However, I would like to do some further, more
> in-depth, analyses.
> 1)     Is there an R package actually designed for gravity models?  I
> have done several searches on the CRAN site with no luck.  My preference
> would be to use R for this manuscript versus commercially available
> software.  
> 2)     I would like to estimate my linearized unconstrained model using
> maximum likelihood.  This may be a simple solution, but I have yet to
> figure out how to do this (my apologies if this is something I should
> have been able to figure out on my own).
> 3)     For a production (origin) constrained model, I can linearize the
> equation as in the unconstrained model.  The models are similar, accept
> I need to estimate a constant (k) for each origin, but with only one
> estimate of the remaining parameters.  Any ideas on how to
> operationalize this?  I have tried exploring options with multiple
> regression, but am not finding a solution with the appropriate
> mechanics.  This would also be an ML estimate.  
> 4)     Any feedback/experience from people who have used gravity models
> in R and/or ecological application would be appreciated.
> 5)     I have tried to keep this posting as brief as possible.  Please
> let me know if you need further information to answer my questions.
> Thank you all in advance
> Melanie Murphy
> EPA-STAR Fellow
> School of Biological Sciences
> Washington State University
> e-mail: [hidden email]
> [[alternative HTML version deleted]]
> ------------------------------
> _______________________________________________
> R-sig-ecology mailing list
> [hidden email]
> End of R-sig-ecology Digest, Vol 2, Issue 4
> *******************************************

R-sig-ecology mailing list
[hidden email]