FinScan: Finalization of the scan procedures

View source: R/finalizing_scan_procedure.R

FinScanR Documentation

Finalization of the scan procedures

Description

This function finalizes the scan procedures.

Usage

FinScan(
  index_clusters_temp,
  index,
  filtering_post,
  type_minimaxi_post,
  mini_post,
  maxi_post,
  nb_sites,
  matrix_clusters,
  radius,
  areas,
  centres,
  pvals,
  maximize = TRUE
)

Arguments

index_clusters_temp

numeric vector. Indices of the significant clusters.

index

numeric vector. Index of concentration for each potential cluster.

filtering_post

logical. Is there an a posteriori filtering?

type_minimaxi_post

character. Type of minimum and maximum a posteriori: by default "sites/indiv": the mini_post and maxi_post are on the number of sites or individuals in the significant clusters. Other possible values are "area": the minimum and maximum area of the clusters, or "radius": the minimum and maximum radius.

mini_post

numeric. A minimum to filter the significant clusters a posteriori (see type_minimaxi_post). The default NULL is for no filtering with a a posteriori minimum.

maxi_post

numeric. A maximum to filter the significant clusters a posteriori (see type_minimaxi_post). The default NULL is for no filtering with a a posteriori maximum.

nb_sites

numeric. The number of considered sites or individuals.

matrix_clusters

matrix. The matrix of potential clusters taking the value 1 at lign i and column j if the cluster j contains the site i, 0 otherwise.

radius

numeric vector. The radius of the potential clusters.

areas

numeric vector. The areas of the potential clusters.

centres

numeric matrix. The coordinates of the centres of each potential cluster.

pvals

numeric vector. The pvalue of each potential cluster.

maximize

logical. Should the index be maximized? By default TRUE. If FALSE it will be minimized.

Value

The list of the following elements:

  • pval_clusters: pvalues of the selected clusters.

  • sites_clusters: the indices of the sites of the selected clusters.

  • centres_clusters: the coordinates of the centres of each selected cluster.

  • radius_clusters: the radius of the selected clusters.

  • areas_clusters: the areas of the selected clusters.


HDSpatialScan documentation built on May 31, 2023, 7:52 p.m.