weight_matrix_cpp: Calculate weight matrix

View source: R/RcppExports.R

weight_matrix_cppR Documentation

Calculate weight matrix

Description

Calculate weight matrix

Usage

weight_matrix_cpp(subsets, m, n, w)

Arguments

subsets

List. Each of the elements equals an integer vector representing a valid combination of features/feature groups.

m

Integer. Number of features/feature groups

n

Integer. Number of combinations

w

Numeric vector of length n, i.e. w[i] equals the Shapley weight of feature/feature group combination i, represented by subsets[[i]].

Value

Matrix of dimension n x m + 1

Author(s)

Nikolai Sellereite


NorskRegnesentral/shapr documentation built on April 19, 2024, 1:19 p.m.