extract_summary_functions {mxfda} | R Documentation |
Extract Summary Functions
Description
Function to extract spatial summary functions from the Spatial
slot of an mxFDA
object
Usage
extract_summary_functions(
mxFDAobject,
r_vec = seq(0, 100, by = 10),
extract_func = c(univariate, bivariate),
summary_func = c(Kest, Lest, Gest),
markvar,
mark1,
mark2 = NULL,
edge_correction,
breaks = NULL
)
Arguments
mxFDAobject |
object of class |
r_vec |
Numeric vector of radii over which to evaluate spatial summary functions. Must begin at 0. |
extract_func |
Defaults to univariate, which calculates univariate spatial summary functions. Choose bivariate for bivariate spatial summary functions. |
summary_func |
Spatial summary function to calculate. Options are c(Kest, Lest, Gest) which denote Ripley's K, Besag's L, and nearest neighbor G function, respectively. |
markvar |
The name of the variable that denotes cell type(s) of interest. Character. |
mark1 |
Character string that denotes first cell type of interest. |
mark2 |
Character string that denotes second cell type of interest for calculating bivariate summary statistics. Not used when calculating univariate statistics. |
edge_correction |
Character string that denotes the edge correction method for spatial summary function. For Kest and Lest choose one of c("border", "isotropic", "Ripley", "translate", "none"). For Gest choose one of c("rs", "km", "han") |
breaks |
integer value for number of breaks in r_vec. Used only for entropy measure |
Details
Value
an object of class mxFDA
containing the corresponding spatial summary function slot filled. See make_mxfda()
for object structure details.
Author(s)
Julia Wrobel julia.wrobel@emory.edu
Alex Soupir alex.soupir@moffitt.org
References
Xiao, L., Ruppert, D., Zipunnikov, V., and Crainiceanu, C. (2016). Fast covariance estimation for high-dimensional functional data. Statistics and Computing, 26, 409-421. DOI: 10.1007/s11222-014-9485-x.
Examples
#load ovarian FDA object
data('ovarian_FDA')
#run function
ovarian_FDA = extract_summary_functions(ovarian_FDA, r_vec = 0:100,
extract_func = univariate,
summary_func = Kest,
markvar = "immune",
mark1 = "immune",
edge_correction = "trans")