Learn R Programming

smerc (version 1.8.6)

Statistical Methods for Regional Counts

Description

Implements statistical methods for analyzing the counts of areal data, with a focus on the detection of spatial clusters and clustering. The package has a heavy emphasis on spatial scan methods, which were first introduced by Kulldorff and Nagarwalla (1995) and Kulldorff (1997) .

Copy Link

Version

Install

install.packages('smerc')

Monthly Downloads

635

Version

1.8.6

License

GPL (>= 2)

Maintainer

Joshua French

Last Published

August 20th, 2026

Functions in smerc (1.8.6)

elliptic.sim.adj

Perform elliptic.test on simulated data
elbow_point

Compute Elbow Point
elliptic.nn

Nearest neighbors for elliptic scan
dc.zones

Determine zones for the Double Connected scan test
dc.test

Double Connection spatial scan test
elliptic.sim

Perform elliptic.test on simulated data
elliptic.penalty

Compute elliptic penalty
csg2

Construct connected subgraphs
dist.ellipse

Compute minor axis distance of ellipse
dc.sim

Perform dc.test on simulated data
edmst.test

Early Stopping Dynamic Minimum Spanning Tree spatial scan test
combine.zones

Combine distinct zones
elliptic.zones

Determine zones for elliptic.test
distinct

Distinct elements of a list
fast.sim

Perform fast.test on simulated data
edmst.zones

Determine zones for the early stopping dynamic Minimum Spanning Tree scan test
flex_test

Flexibly-shaped Spatial Scan Test
flex.zones

Determine zones for flexibly shaped spatial scan test
flex.sim

Perform flex.test on simualated data
mlf.test

Maxima Likelihood First Scan Test
morancr.stat

Constant-risk Moran's I statistic
dmst.sim

Perform dmst.test on simulated data
gedist

Compute distance for geographic coordinates
flex.test

Flexibly-shaped Spatial Scan Test
fast.zones

Determine sequence of fast subset scan zones
flex_zones

Determine zones for flexibly shaped spatial scan test
mlink.sim

Perform mlink.test on simulated data
dmst.test

Dynamic Minimum Spanning Tree spatial scan test
fast.test

Fast Subset Scan Test
mlink.test

Maximum Linkage spatial scan test
mlink.zones

Determine zones for the Maximum Linkage scan test
morancr.sim

Constant-risk Moran's I statistic
knn

K nearest neighbors
elliptic.test

Elliptical Spatial Scan Test
logical2zones

Convert logical vector to zone
lget

Apply getElement over a list
mlf.zones

Determine zones for the maxima likelihood first algorithm.
nn2zones

Convert nearest neighbors list to zones
mc.pvalue

Compute Monte Carlo p-value
morancr.test

Constant-risk Moran's I-based test
nndup

Determine duplicates in nearest neighbor list
noc_enn

Returned ordered non-overlapping clusters
nydf

Leukemia data for 281 regions in New York.
nypoly

SpatialPolygons object for New York leukemia data.
nysf

sf object for New York leukemia data.
nysp

SpatialPolygonsDataFrame for New York leukemia data.
print.smerc_cluster

Print object of class smerc_cluster.
nndist

Determine nearest neighbors based on maximum distance
noz

Determine non-overlapping zones
print.smerc_optimal_ubpop

Print object of class smerc_optimal_ubpop.
plot.tango

Plots an object of class tango.
noc_nn

Returned ordered non-overlapping clusters
precog.sim

Perform precog.test on simulated data.
nyw

Adjacency matrix for New York leukemia data.
rflex.midp

Compute middle p-value
neastw

Binary adjacency matrix for neast
nn.cumsum

Cumulative sum over nearest neighbors
optimal_ubpop

Optimal Population Upper Bound Statistics
mst.seq

Minimum spanning tree sequence
mst.all

Minimum spanning tree for all regions
print.tango

Print object of class tango.
print.smerc_similarity_test

Print object of class smerc_similarity_test.
plot.smerc_cluster

Plot object of class smerc_cluster.
prep.mst

Return nicely formatted results from mst.all
nclusters

Number of clusters
precog.test

PreCoG Scan Test
plot.smerc_optimal_ubpop

Plot object of class smerc_optimal_ubpop.
scan.stat

Spatial scan statistic
neast

Breast cancer mortality in the Northeastern United States
rflex.zones

Determine zones for flexibly shaped spatial scan test
rflex.test

Restricted Flexibly-shaped Spatial Scan Test
scan.test

Spatial Scan Test
rflex_zones

Determine zones for flexibly shaped spatial scan test
stat.poisson.adj

Compute Poisson test statistic
nnpop

Determine nearest neighbors with population constraint
sig_noc

Return most significant, non-overlapping zones
scan_stat

Spatial scan statistic
summary.smerc_cluster

Summary of smerc_cluster object
scan.zones

Determine zones for the spatial scan test
zones.sum

Sum over zones
w2segments

Returns segments connecting neighbors
rflex.sim

Perform rflex.test on simualated data
tango.stat

Tango's statistic
tango.test

Tango's clustering detection test
sig_prune

Prune significant, non-overlapping zones
tango.weights

Distance-based weights for tango.test
scan.sim

Perform scan.test on simulated data
smerc_cluster

Prepare smerc_cluster
uls.zones

Determine sequence of ULS zones.
smerc

smerc
scan.sim.adj

Perform scan.test on simulated data
uls.test

Upper Level Set Spatial Scan Test
seq_scan_test

Sequential Scan Test
seq_scan_sim

Perform scan test on simulated data sequentially
uls.sim

Perform uls.test on simulated data
bn.test

Besag-Newell Test
cepp.weights

Compute region weights for cepp.test
color.clusters

Color clusters
arg_check_dist_ellipse

Check argments if dist.ellipse
bn.zones

Determine case windows (circles)
cepp.sim

Perform cepp.test on simulated data
clusters

Extract clusters
cepp.test

Cluster Evalation Permutation Procedure Test
dmst.zones

Determine zones for the Dynamic Minimum Spanning Tree scan test
edmst.sim

Perform edmst.test on simulated data
all_shape_dists

Return all shapes and distances for each zone