# smerc_cluster: Prepare 'smerc_cluster' In smerc: Statistical Methods for Regional Counts

## Description

smerc_cluster prepares a smerc_cluster.

## Usage

  1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 smerc_cluster( tobs, zones, pvalue, coords, cases, pop, ex, longlat, method, rel_param, alpha, w = NULL, d = NULL, a = NULL, shape_all = NULL, angle_all = NULL ) 

## Arguments

 tobs The vector of observed test statistics for each zone zones A list of zones pvalue The p-value associated with each test statistic coords An n \times 2 matrix of centroid coordinates for the regions. cases The number of cases observed in each region. pop The population size associated with each region. ex The expected number of cases for each region. The default is calculated under the constant risk hypothesis. longlat The default is FALSE, which specifies that Euclidean distance should be used. If longlat is TRUE, then the great circle distance is used to calculate the intercentroid distance. method A character string indicating the method used to construct the smerc_cluster. rel_param A names list with the relevant parameters associated with method. alpha The significance level of the test. w A binary spatial adjacency matrix for the regions. d A precomputed distance matrix based on coords a A single value >= 0 indicating the penalty to use for elliptic.test. shape_all A vector of shape parameters associated with zones. angle_all A vector of angle parameter associated with zones.

## Value

A smerc_cluster object. The object generally has the following components:

 clusters A list containing information about the significant clusters. See further details below. coords The matrix of centroid coordinates. number_of_regions The number of regions considered. total_population The total population in the regions. total_cases The total number of cases in the regions. cases_per_100k The rate of cases per 100,000 persons. method The name of the method applied. rel_param A list of relevant method parameters. alpha The significance level. longlat A logical value indicating which type of distance was used.

Each element of the clusters component has:

 locids The ids of the regions in the cluster. centroid The cluster centroid. r The radius of the region (from the starting region to last region of the cluster). max_dist The maximum intercentroid distance between all the regions in the cluster. population The total population in the cluster. cases The number of cases in the cluster. expected The expected number of cases in the cluster. smr Standardized mortality ratio (cases/expected) in the cluster. rr Relative risk in the cluster window. This is (cases/pop)/((total_cases - cases)/ (total_population - population)). loglikrat The log of the likelihood ratio test statistic for the cluster. Only valid for the scan-type tests. test_statistic The test statistic for the cluster. pvalue The p-value of the test statistic associated with the cluster. w The adjacency information for the cluster.

For elliptic.test, clusters additionally has:

 semiminor_axis The semi-minor axis length for the ellipse. semimajor_axis The semi-major axis length for the ellipse. angle The rotation angle of the ellipse. shape The shape of the ellipse.

smerc documentation built on Oct. 1, 2021, 5:07 p.m.