ProcessAndStackDataForRegression: Helper function to stack data for a regression model.

View source: R/stackingutilities.R

ProcessAndStackDataForRegressionR Documentation

Helper function to stack data for a regression model.

Description

Takes the input unstacked data, interaction, subset, weights and formula terms, processes the unstacked data, and stacks it. If the stacking is successful, the interaction, subset, weights are also updated to be the appropriate size

Usage

ProcessAndStackDataForRegression(
  unstacked.data,
  formula,
  interaction,
  subset,
  weights
)

Arguments

unstacked.data

A named list of two data frames. Element "X" is the data frame containing containing the outcome variable (usually a Numeric - Multi or Nominal/Ordinal - Multi variable set in Displayr), and element "Y" is the data frame containing the predictor variables (a Binary - Grid or Numeric - Grid variable set in Displayr).

formula

A formula object for the regression.

interaction

Optional variable to test for interaction with other variables in the model.

subset

An optional vector specifying a subset of observations to be used in the fitting process.

weights

An optional vector of sampling weights.


Displayr/flipTransformations documentation built on Feb. 26, 2024, 12:47 a.m.