plotdisc: Plot spatial discretization matrix.

Description Usage Arguments Value Examples

View source: R/plotdisc.R

Description

Plot spatial discretization matrix.

Usage

1
plotdisc(discmatrix, group)

Arguments

discmatrix

A matrix of spatial discretization

group

A vector of groups

Value

A data frame of spatial discretization matrix, which includes mean Q values in each group.

Examples

1
2
3
4
5
6
7
8
library(GD)
f1 <- formula(NDVIchange ~ Tempchange + Precipitation + Popdensity)
odc1 <- optidisc(f1, ndvi_40, discmethod = "quantile", discitv = c(3:20))
xvar <- all.vars(f1)[-1]
nx <- length(xvar)
dm <- do.call(data.frame, lapply(1:nx, function(u) odc1[[u]]$qv.matrix))
names(dm) <- xvar
pd <- plotdisc(discmatrix = dm, group = rep(1:6, each = 3))

IDSA documentation built on April 18, 2021, 5:07 p.m.