| extract_fire | R Documentation |
This function takes a spotoroo object to produce a data frame which
contains information about the fire.
extract_fire(result, cluster = "all", noise = FALSE)
result |
|
cluster |
Character/Integer. If "all", extract all clusters. If an integer vector is given, extract corresponding clusters. |
noise |
Logical. Whether or not to include noise. |
A data.frame. The fire information
lon : Longitude.
lat : Latitude.
obsTime : Observed time.
timeID : Time indexes.
membership : Membership labels.
noise : Whether it is a noise point.
distToIgnition : Distance to the ignition location.
distToIgnitionUnit : Unit of distance to the ignition
location.
timeFromIgnition : Time from ignition.
timeFromIgnitionUnit : Unit of time from ignition.
type : Type of the entry, either "hotspot", "noise" or
"ignition"
obsInCluster : Number of observations in the cluster.
clusterTimeLen : Length of time of the cluster.
clusterTimeLenUnit : Unit of length of time of the
cluster.
# Time consuming functions (>5 seconds)
# Get clustering results
result <- hotspot_cluster(hotspots,
lon = "lon",
lat = "lat",
obsTime = "obsTime",
activeTime = 24,
adjDist = 3000,
minPts = 4,
minTime = 3,
ignitionCenter = "mean",
timeUnit = "h",
timeStep = 1)
# Extract all fires
all_fires <- extract_fire(result)
head(all_fires, 3)
# Extract cluster 4
fire_4 <- extract_fire(result, 4)
head(fire_4, 3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.