plotSummary.ResScanOutputMulti: Plots the mean or median spider chart of the clusters...

View source: R/HDSpatialScan_plotSummary.R

plotSummary.ResScanOutputMultiR Documentation

Plots the mean or median spider chart of the clusters detected by a multivariate scan function (MG or MNP)

Description

This function plots the mean or median spider chart of the clusters detected by a multivariate scan function (MG or MNP).

Usage

## S3 method for class 'ResScanOutputMulti'
plotSummary(x, type = "mean", colors = "red", only.MLC = FALSE, ...)

Arguments

x

ResScanOutputMulti. Output of a multivariate scan function (MG or MNP).

type

character. "mean" or "median". If "mean": the means in the clusters are plotted in solid lines, outside the cluster in dots, the global mean is in black. If "median": the medians in the clusters are plotted in solid lines, outside the cluster in dots, the global median is in black.

colors

character. The colors to plot the clusters' summaries. If length(colors)==1 then all the clusters will be plotted in this color. Else there must be the same number of elements in colors than the number of clusters

only.MLC

logical. Should we plot only the MLC or all the significant clusters?

...

Further arguments to be passed to or from methods.

Value

No value returned, plots the spider chart.

Examples


library(sp)
data("map_sites")
data("multi_data")
coords <- coordinates(map_sites)

res_mnp <- SpatialScan(method = "MNP", data=multi_data, sites_coord = coords,
system = "WGS84", mini = 1, maxi = nrow(coords)/2,
variable_names = c("NO2", "O3", "PM10", "PM2.5"))$MNP

plotSummary(x = res_mnp, type = "mean")



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