November 2018
Beginner to intermediate
354 pages
6h 59m
English
Suppose we have the migration rates for each of the areas we have considered so far. This is the count data, and if it can be assumed that the migration rate is constant, we can use the Poisson model to get the probability of a specified rate of migration. In a Poisson model, the mean and variance are the same.
Using the glm() function, we can fit a different GLM model. Here we model the rate of migration, migration, on agri and density, as we have done before. The code for this is as follows:
migration_glm = glm(migration ~ agri+density, offset = pop, data=migration_spdf, family = poisson)summary(migration_glm)
The result of this model is as follows:
Well, the result is now surprising, as agri and ...
Read now
Unlock full access