The function to apply multivariate quantile LISA statistics

local_multiquantilelisa(
  w,
  df,
  k,
  q,
  permutations = 999,
  permutation_method = "complete",
  significance_cutoff = 0.05,
  cpu_threads = 6,
  seed = 123456789
)

Arguments

w

An instance of Weight object

df

A data frame with selected variables only. E.g. guerry[c("TopCrm", "TopWealth", "TopLit")]

k

A vector of "k" values indicate the number of quantiles for each variable. Value range e.g. [1, 10]

q

A vector of "q" values indicate which quantile or interval for each variable used in local join count statistics. Value stars from 1.

permutations

(optional) The number of permutations for the LISA computation

permutation_method

(optional) The permutation method used for the LISA computation. Options are ('complete', 'lookup'). Default is 'complete'.

significance_cutoff

(optional) A cutoff value for significance p-values to filter not-significant clusters

cpu_threads

(optional) The number of cpu threads used for parallel LISA computation

seed

(optional) The seed for random number generator

Value

An instance of LISA-class

Examples

library(sf)
guerry_path <- system.file("extdata", "Guerry.shp", package = "rgeoda")
guerry <- st_read(guerry_path)
#> Reading layer `Guerry' from data source 
#>   `/Users/runner/work/_temp/Library/rgeoda/extdata/Guerry.shp' 
#>   using driver `ESRI Shapefile'
#> Simple feature collection with 85 features and 29 fields
#> Geometry type: MULTIPOLYGON
#> Dimension:     XY
#> Bounding box:  xmin: 47680 ymin: 1703258 xmax: 1031401 ymax: 2677441
#> Projected CRS: NTF (Paris) / Lambert zone II
queen_w <- queen_weights(guerry)
lisa <- local_multiquantilelisa(queen_w, guerry[c("Crm_prp", "Litercy")],
k=c(4,4), q=c(1,1))
clsts <- lisa_clusters(lisa)
clsts
#>  [1] 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> [39] 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> [77] 0 0 0 0 0 0 0 0 0