prepare_regression_data: Prepare a data set containing predictor and response...

View source: R/prepare-predictive-data.R

prepare_regression_dataR Documentation

Prepare a data set containing predictor and response variables for regression modeling

Description

A wrapper around prepare_predictor_vars() and prepare_response_vars() for one-line regression data preparation.

Usage

prepare_regression_data(dates = NULL, na.omit = TRUE, ...)

Arguments

dates

Object of class "POSIXct/POSIXt"; vector of historical fishing dates to include. If NULL (the default) all dates included in the meta data set (?KuskoHarvData::openers_all) will be included.

na.omit

Logical; if TRUE (default), any rows with an NA value for any variable will be discarded.

...

Optional arguments passed to prepare_response_vars()

Value

Data frame with rows for individual dates and columns for several variables to be used in regression modeling. See prepare_predictor_vars() and prepare_response_vars() for variable definitions. In addition to those variables, there is also a period variable (see KuskoHarvUtils::get_period()).


bstaton1/KuskoHarvData documentation built on Aug. 15, 2024, 3:29 p.m.