risk_detector: risk detector

Description Usage Arguments Value Examples

View source: R/risk_detector.r

Description

This function calculates the average values in each stratum of explanatory variable (X), and presents if there exists difference between two strata.

Usage

1
risk_detector(y_column, x_column_nn, tabledata)

Arguments

y_column

The index or field name of explained variable in input dataset.

x_column_nn

The index or field name of explanatory variable(s) in input dataset.

tabledata

The dataset (dataframe) contains fields of explained variable and explanatory variables.

Value

Results of risk detector include the means of explained variable in each stratum derived from an explanatory variable and the t-test for difference between two strata.

Examples

1
2
3
4
5
data(CollectData)
risk_detector("incidence","soiltype",CollectData)
risk_detector(1,2,CollectData)
risk_detector(1,c(2,3,4),CollectData)
risk_detector("incidence",c("soiltype","watershed","elevation"),CollectData)

geodetector documentation built on March 31, 2020, 5:27 p.m.