View source: R/ChisquareTable.R
ChiSquareTable | R Documentation |
Chi-square Statistics Table
ChiSquareTable( trainingdata = NULL, nfeatureNames = NULL, outcome = NULL, level = NULL, ModelObject = NULL )
trainingdata |
A data set used for training |
nfeatureNames |
A vector of feature names that will be used for computing chi-square statistics |
outcome |
A character string with the name of the binary outcome variable. |
level |
A numerical value indicating the number of categories that the outcome contains |
ModelObject |
A model object containing tree-based models |
This function returns a table with five columns. The chi-square statistics were computed as described by He & von Davier (2015).
Feature: Features names
CvAverageChisq: Average chisquare statistics computed from 10-fold cross validation samples
Rank.CvAverageChisq: Ordem of the feature importance from the CvAverageChisq measures#'
OverallChisq: chisquare scores computed from the whole training sample
Rank.OverallChisq: Ordem of the feature importance from the OverallChisq measures
He, Q., & von Davier, M. (2015). Identifying feature sequences from process data in problem-solving items with N-grams. In Quantitative Psychology Research: The 79th Annual Meeting of the Psychometric Society (pp. 173–190). Madison, Wisconsin: Springer International Publishing.
colnames(training)[14] <- "perf" ensemblist <- TreeModels(traindata = training, methodlist = c("dt", "gbm"),checkprogress = TRUE) ChiSquareTable(trainingdata=training, nfeatureNames=colnames(training[,7:13]), outcome = "perf",level = 2, ModelObject = ensemblist$ModelObject)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.