getLogFit: Get the Logistic Regression Fit

Description Usage Arguments Value

View source: R/logisticRegression.R

Description

This function takes in a training data set and performs a logistic regression model to predict the stay probability as a function of whether the last trial was rewarded or not, whether the last trial had a common or rare transition, and the interaction between the two. This can be run by itself, but is called by the function getLogPreds.

Usage

1

Arguments

data

The data can either be the output of logSetup or the output of generateData. If the latter, make sure that manipulateData is called on pure Q-learning simulations. Similarly, for DynaQ simulations, make sure the data has been processed and the Q table has been removed.

Value

This returns a tidymodels workflow object that has been fitted to predict the stay probability based on the reward and transition types.


jdtrat/dynaq documentation built on July 24, 2020, 7:18 a.m.