model_dd: model_dd: Model data from Delay Discounting

View source: R/model_dd.R

model_ddR Documentation

model_dd: Model data from Delay Discounting

Description

This function models data from Delay Discounting using the miyamot0/discountingtools github package. This script will use approximate Bayesian model selection to identify the best best-performing model at the individual level. The model candidates include: the Exponential (Samuelson, 1937), the Hyperbolic (Mazur, 1987), the Generalized Hyperboloid (Rodriguez & Logue, 1997), the Quasi-Hyperbolic (Laibson, 1997), the Green & Myerson (Green & Myerson, 2004), the Ebert & Prelec Constant Sensitivity Model (Ebert & Prelec, 2007), the Bleichrodt et al. Constant Relative Decreasing Impatience Model (Bleichrodt et al., 2009), and a Noise model. More info can be found in fitting packages miyamot0/discountingtools: Delay Discounting Tools (https://github.com/miyamot0/discountingtools). Since individuals may differ in their 'true' model, only generalized indices are computed: Effective Delay 50 (ED50; Yoon & Higgins, 2008) and numerical integration performed upon the "true" model in normal and log10 scaling. Effective Delay 50 is the delay time needed for subjective value to decrease to 50 percent. The numerican integration approaches allow for calculation of model-based area under the curve with the log10 scaling computing AUC after scaling the delays by log10.

Usage

model_dd(dd_data, parID)

Arguments

dd_data

a data.frame all items for the Delay Discounting following the naming conventions described above

parID

(optional) name of participant ID column in intake_data. If included the output dataset will be matched by parID, if not included the output dataset will be in the order of intake_data but will have no participant identifier.

Details

Note: this approach does take a few minutes to compute

To use this function, the data must be prepared according to the following criteria: 1) The data must include all individual questionnaire items and child grade 2) The columns/variables must match the following naming convention: 'dd#' where # is the question number (1-69) 3) All questions must have the numeric value for the choice: 3a) Questions 1-66: 0 - delay chosen, 1 - now chosen 3b) Questions 67-69: 0 - $10 in 0 days, 1 - $X now

Note, as long as variable names match those listed, the dataset can include other variables

Value

A dataset with a score for the Delay Discounting

References

Wilson VB, Mitchell SH, Musser ED, Schmitt CF, Nigg JT. Delay discounting of reward in ADHD: application in young children: Delay discounting and ADHD. Journal of Child Psychology and Psychiatry. 2011;52(3):256-264. doi:10.1111/j.1469-7610.2010.02347.x (PubMed)

See Also

Raw data from Qualtrics was processed using the following script: qualtrics_child_v3dat and qualtrics_child_v3dat_home

Examples


# scoring for the dd with IDs
dd_score_data <- model_dd(dd_data, parID = 'ID')

## Not run: 



alainapearce/kellertools documentation built on Feb. 25, 2024, 7:16 a.m.