Learn R Programming

mfp2 (version 1.0.0)

calculate_df: Helper to calculates the final degrees of freedom for the selected model

Description

To be used in fit_mfp().

Usage

calculate_df(p)

Value

returns numeric value denoting the number of degrees of freedom (df).

Arguments

p

power of a variable.

Details

An example calculation: if p is the power(s) and p = c(1,2), then df = 4 but if x = NA then df = 0.