Skip to contents

Fits a binary-group function-on-scalar model for one variable stored in a run_fda_analysis() result. The group contrast is created automatically from the reference and comparison groups used in the FDA workflow.

Usage

fit_fda_group_model(
  analysis,
  value_col,
  reference_score = -1,
  comparison_score = 1,
  formula = y ~ x,
  ...
)

Arguments

analysis

A windcut_fda_analysis object returned by run_fda_analysis().

value_col

Weather variable to model.

reference_score

Numeric score assigned to the reference group.

comparison_score

Numeric score assigned to the comparison group.

formula

Formula passed to functional_on_scalar(). Defaults to y ~ x.

...

Additional arguments passed to functional_on_scalar().

Value

The fitted pffr model object.