ImportanceTable: Create formattable table of importance scores

View source: R/importancetable.R

ImportanceTableR Documentation

Create formattable table of importance scores

Description

Creates a pretty formattable table for relative/Shapley importance output.

Usage

ImportanceTable(
  driver.analysis.output,
  row.labels,
  title = "",
  subtitle = "",
  footer = "",
  p.cutoff = 0.05,
  output.type
)

Arguments

driver.analysis.output

A list containing the relative importance scores, output coefficients and significance test values. The list needs to contain the following elements:

  • importance: A numeric vector of relative importance values based off the raw.importance

  • raw.importance: A numeric vector of coefficients, these could be the output coefficients from a Shapley Regression or Relative Importance Analysis or the Jaccard Coefficients or Correlation coefficients if the output.type (see below) is "Shapley Regression", "Relative Importance Analysis", "Jaccard Coefficient" or "Correlation" respectively.

  • p.values: The resulting p values from the statistics (see below).

For "Shapley Regression" and "Relative Importance Analysis", two more list elements are required,

  • standard.errors: The standard errors of the estimated coefficients

  • statistics: The computed statistics

For "Jaccard Coefficient" or "Correlation" outputs, the following single extra elements is required instead.

  • sample.size The sample size count used in the calculation of significance tests for each driver.

row.labels

The row labels corresponding to the predictor variable names/labels.

title

The title for the table.

subtitle

Subtitle for the table.

footer

Text to place in the footer of the table.

p.cutoff

The alpha level used when formatting the p-value column.

output.type

A character string denoting the output type

  • "Relative Importance Analysis"

  • "Shapley Regression"

  • "Jaccard Coefficient"

  • "Correlation"

References

This is based on code written by Kenton Russell.


Displayr/flipFormat documentation built on Feb. 26, 2024, 12:37 a.m.