Description Usage Arguments Value

View source: R/glm.iscluster.R

This function constructs all the clusters with start date equal to
minDateCluster, end date equal to maxDateCluster, and with center specified
by the first element of idxorder, so that the maximum fraction of the total
population inside the cluster is less than fractpop, and the maximum
distance to the center is less than radius.
For each one of these clusters, the log-likelihood ratio test statistic
for comparing the alternative model with the cluster versus the null model
of no clusters (if model is glm, glmer or zeroinfl),
or the DIC (if model is `inla`

) is calculated.
The cluster with maximum value of the log-likelihood ratio or
minimum DIC is returned.

1 2 | ```
glmAndZIP.iscluster(stfdf, idxorder, minDateCluster, maxDateCluster, fractpop,
model0, ClusterSizeContribution)
``` |

`stfdf` |
a spatio-temporal class object containing the data. |

`idxorder` |
a permutation of the regions according to their distance to the current center. |

`minDateCluster` |
start date of the cluster. |

`maxDateCluster` |
end date of the cluster. |

`fractpop` |
maximum fraction of the total population inside the cluster. |

`model0` |
Initial model (including covariates). |

`ClusterSizeContribution` |
Variable used to check the fraction of the
population at risk in the cluster
This can be "glm" for generalized linear models (glm stats),
"glmer" for generalized linear mixed model (glmer lme4),
"zeroinfl" for zero-inflated models (zeroinfl pscl), or
"inla" for generalized linear, generalized linear mixed or zero-inflated models fitted with |

vector containing the size, the start and end dates, the log-likelihood ratio or DIC, the p-value and the risk of the cluster with the maximum log-likelihood ratio or minimum DIC.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.