sparrpowR-package {sparrpowR} | R Documentation |
The sparrpowR Package: Power Analysis to Detect Spatial Relative Risk Clusters
Description
Computes the statistical power for the spatial relative risk function.
Details
For a two-group comparison (e.g., cases v. controls) the 'sparrpowR' package calculates the statistical power to detect clusters using the kernel-based spatial relative risk function that is estimated using the 'sparr' package. Details about the 'sparr' package methods can be found in the tutorial: Davies et al. (2018) doi:10.1002/sim.7577. Details about kernel density estimation can be found in J. F. Bithell (1990) doi:10.1002/sim.4780090616. More information about relative risk functions using kernel density estimation can be found in J. F. Bithell (1991) doi:10.1002/sim.4780101112.
This package provides a function to compute the statistical power for the spatial relative risk function with various theoretical spatial sampling strategies. The 'sparrpowR' package also provides a function to compute the statistical power for the spatial relative risk function for scenarios where one group (e.g., cases) have been observed and a theoretical sampling strategy for the second group (e.g., controls) is desired. The 'sparrpowR' package also provides visualization of data and statistical power.
Key content of the 'sparrpowR' package include:
Theoretical Spatial Sampling
spatial_data
Generates random two-group data for a spatial relative risk function.
Statistical Power
spatial_power
Computes the statistical power of a spatial relative risk function using randomly generated data.
jitter_power
Computes the statistical power of a spatial relative risk function using previously collected data.
Data Visualization
spatial_plots
Visualizes multiple plots of output from spatial_data
, spatial_power
and jitter_power
functions.
Dependencies
The 'sparrpowR' package relies heavily upon sparr
, spatstat.random
, spatstat.geom
, and terra
for computing the statistical power and visualizing the output. Computation can be performed in parallel using doFuture
, multisession
, doRNG
, and foreach
. Basic visualizations rely on the plot.ppp
and image.plot
functions.
Author(s)
Ian D. Buller
Social & Scientific Systems, Inc., a division of DLH Corporation, Silver Spring, Maryland, USA (current); Occupational and Environmental Epidemiology Branch, Division of Cancer Epidemiology and Genetics, National Cancer Institute, National Institutes of Health, Rockville, Maryland, USA (original)
Maintainer: I.D.B. ian.buller@alumni.emory.edu.gov