Learn R Programming

ShapleyValue (version 0.2.0)

shapleyvalue: ShapleyValueRegression -- to calculate the relative importance of attributes in linear regression

Description

Shapley Value Regression for calculating the relative importance of independent variables in linear regression with avoiding the collinearity.

Arguments

Value

The structure of the output is a datatable, with two rows:the unstandardized and standardized relative importance of each attributes using shapley value regression method.

Examples

Run this code
# NOT RUN {
library(MASS)
library(tidyverse)
data <- Boston
y <- data$medv
x <- as.data.frame(data[,5:8])
shapleyvalue(y,x)
# }

Run the code above in your browser using DataLab