Skip to contents

Run a regression without each feature and filter features that do not improve the model more than r2_threshold.

Usage

filter_traj_model(
  traj_model,
  r2_threshold = 0.0005,
  bits_threshold = 1.75,
  sample_frac = 0.1,
  seed = 60427
)

Arguments

traj_model

An instance of TrajectoryModel.

r2_threshold

minimal R^2 for a feature to be included in the model.

bits_threshold

minimal sum of bits for a feature to be included in the model.

sample_frac

The fraction of samples to use for computing the r2 without each model. When NULL, all samples are used.

seed

The seed to use for reproducibility when sampling the data.

Value

An instance of TrajectoryModel with the filtered model.