Skip to contents

Get features with non-zero coefficients

Usage

non_zero_coefs(fit_obj)

# S3 method for class 'ptk_zerosum'
non_zero_coefs(fit_obj)

# S3 method for class 'nested_fit'
non_zero_coefs(fit_obj)

Arguments

fit_obj

S3 fit object.

Value

One-column matrix with non-zero coefficients and feature names as row names.

Details

Throws an error if method for a class is not implemented (e.g. for ptk_ranger because "non-zero coefficients" do not make sense with random forests).

Refers to the late model.