DClusterm (version 1.0-1)

get.stclusters: Gets areas in a spatio-temporal cluster

Description

This function is similar to get.knclusters but it also allows for spatio-temporal clusters.

Usage

get.stclusters(stfdf, results)

Arguments

stfdf

A sp or spacetime object with the information about the data.

results

Results from a call to DetectClustersModel

Value

A list with as many elements as clusters in 'results'

Examples

Run this code
# NOT RUN {
library("DClusterm")
library("RColorBrewer")

data("brainNM")
data("brainNM_clusters")

stcl <- get.stclusters(brainst, nm.cl0)
#Get first cluster
brainst$CLUSTER <- ""
brainst$CLUSTER[ stcl[[1]] ] <- "CLUSTER"

#Plot cluster
stplot(brainst[, , "CLUSTER"], at = c(0, 0.5, 1.5), col = "#4D4D4D",
  col.regions = c("white", "gray"))

# }

Run the code above in your browser using DataCamp Workspace