Perspectives on Behavior Science

, Volume 42, Issue 1, pp 163–180 | Cite as

The R package beezdemand: Behavioral Economic Easy Demand

  • Brent A. KaplanEmail author
  • Shawn P. Gilroy
  • Derek D. Reed
  • Mikhail N. Koffarnus
  • Steven R. Hursh


beezdemand: Behavioral Economic Easy Demand, a novel Open image in new window package for performing behavioral economic analyses, is introduced and evaluated. beezdemand extends the Open image in new window statistical program to facilitate many of the analyses performed in studies of behavioral economic demand. The package supports commonly used options for modeling operant demand and performs data screening, fits models of demand, and calculates numerous measures relevant to applied behavioral economists. The free and open source beezdemand package is compared to commercially available software (i.e., GraphPad Prism™) using peer-reviewed and simulated data. The results of this study indicated that beezdemand provides results consistent with commonly used commercial software but provides a wider range of methods and functionality desirable to behavioral economic researchers. A brief overview of the package is presented, its functionality is demonstrated, and considerations for its use are discussed.


behavioral economics demand R programming language behavioral science purchase task free and open source software 



We would like to express our sincere gratitude to Paul E. Johnson (Center for Research Methods and Data Analysis, Lawrence, KS), Peter G. Roma (National Aeronautics and Space Administration Johnson Space Center, Houston, TX), W. Brady DeHart (Virginia Tech Carilion Research Institute, Roanoke, VA), and Michael Amlung (Cognitive Neuroscience of Addictions Laboratory, Hamilton, ON) for their helpful feedback and advice on early iterations of the beezdemand package.


  1. Amazon Mechanical Turk. (n.d.). [Computer software]. Retrieved from
  2. Aston, E. R., Metrik, J., Amlung, M., Kahler, C. W., & MacKillop, J. (2016). Interrelationships between marijuana demand and discounting of delayed rewards: Convergence in behavioral economic methods. Drug & Alcohol Dependence, 169, 141–147. Scholar
  3. Aston, E. R., Metrik, J., & MacKillop, J. (2015). Further validation of a marijuana purchase task. Drug & Alcohol Dependence, 152, 32–38. Scholar
  4. Baum, W. M. (1974). On two types of deviation from the matching law: Bias and undermatching. Journal of the Experimental Analysis of Behavior, 22(1), 231–242. Scholar
  5. Bickel, W. K., DeGrandpre, R. J., & Higgins, S. T. (1993). Behavioral economics: a novel experimental approach to the study of drug dependence. Drug & Alcohol Dependence, 33(2), 173–192. Scholar
  6. Bickel, W. K., DeGrandpre, R. J., Hughes, J. R., & Higgins, S. T. (1991). Behavioral economics of drug self-administration. II. A unit-price analysis of cigarette smoking. Journal of the Experimental Analysis of Behavior, 55(2), 145–154. Scholar
  7. Bickel, W. K., Johnson, M. W., Koffarnus, M. N., MacKillop, J., & Murphy, J. G. (2014). The behavioral economics of substance use disorders: Reinforcement pathologies and their repair. Annual Review of Clinical Psychology, 10(10), 641–677. Scholar
  8. Bickel, W. K., Madden, G. J., & Petry, N. M. (1998). The price of change: The behavioral economics of drug dependence. Behavior Therapy, 29(4), 545–565. Scholar
  9. Bickel, W. K., Marsch, L. A., & Carroll, M. E. (2000). Deconstructing relative reinforcing efficacy and situating the measures of pharmacological reinforcement with behavioral economics: A theoretical proposal. Psychopharmacology, 153(1), 44–56.Google Scholar
  10. Bickel, W. K., Odum, A. L., & Madden, G. J. (1999). Impulsivity and cigarette smoking: Delay discounting in current, never, and ex-smokers. Psychopharmacology, 146(4), 447–454. Scholar
  11. Bickel, W. K., & Vuchinich, R. E. (2000). Reframing health behavior change with behavioral economics. Mahwah, NJ: Erlbaum.Google Scholar
  12. Bidwell, L. C., MacKillop, J., Murphy, J. G., Tidey, J. W., & Colby, S. M. (2012). Latent factor structure of a behavioral economic cigarette demand curve in adolescent smokers. Addictive Behaviors, 37(11), 1257–1263. Scholar
  13. Bruner, N. R., & Johnson, M. W. (2014). Demand curves for hypothetical cocaine in cocaine-dependent individuals. Psychopharmacology, 231(5), 889–897. Scholar
  14. Epstein, L. H. (1995). Application of behavioral economic principles to treatment of childhood obesity. In D. B. Allison & F. X. Pi-Sunyer (Eds.), Obesity treatment: Establishing goals, improving outcomes, and reviewing the research agenda (pp. 113–119). Boston, MA: Springer.Google Scholar
  15. Epstein, L. H., Dearing, K. K., Roba, L. G., & Finkelstein, E. (2010). The influence of taxes and subsidies on energy purchased in an experimental purchasing study. Psychological Science, 21(3), 406–414. Scholar
  16. Epstein, L. H., Paluch, R. A., Carr, K. A., Temple, J. L., Bickel, W. K., & MacKillop, J. (2018). Reinforcing value and hypothetical behavioral economic demand for food and their relation to BMI. Eating Behaviors, 29, 120–127.Google Scholar
  17. Epstein, L. H., & Saelens, B. E. (2000). Behavioral economics of obesity: Food intake and energy expenditure. In W. K. Bickel & R. E. Vuchinich (Eds.), Reframing health behavior change with behavioral economics (pp. 293–311). Mahwah, NJ: Lawrence Erlbaum Associates.Google Scholar
  18. Foxall, G. R., Olivera-Castro, J., Schrezenmaier, T., & James, V. (2007). The behavioral economics of brand choice. London and New York: Palgrave Macmillan.Google Scholar
  19. Foxall, G. R., Wells, V. K., Chang, S. W., & Oliveira-Castro, J. M. (2010). Substitutability and independence: Matching analyses of brands and products. Journal of Organizational Behavior Management, 30(2), 145–160. Scholar
  20. Gilroy, S. P., Franck, C. T., & Hantula, D. A. (2017). The discounting model selector: Statistical software for delay discounting applications. Journal of the Experimental Analysis of Behavior, 107, 388–401. Scholar
  21. Gilroy, S. P., Kaplan, B. A., & Leader, G. (2018a). A systematic review of applied behavioral economics in assessments and treatments for individuals with developmental disabilities. Review Journal of Autism & Developmental Disorders, 5(3), 247–259. Scholar
  22. Gilroy, S. P., Kaplan, B. A., Reed, D. D., Koffarnus, M. N., & Hantula, D. A. (2018b). The Demand Curve Analyzer: Behavioral economic software for applied researchers. Journal of the Experimental Analysis of Behavior.
  23. GitHub. (n.d.). beezdemand. [Computer software]. Retrieved from
  24. Grace, R. C., Kivell, B. M., & Laugesen, M. (2014). Estimating cross-price elasticity of e-cigarettes using a simulated demand procedure. Nicotine & Tobacco Research, 17(5), 592–598.Google Scholar
  25. Greenwald, M. K. (2010). Effects of experimental Unemployment, Employment and Punishment analogs on opioid seeking and consumption in heroin-dependent volunteers. Drug & Alcohol Dependence, 111(1–2), 64–73. Scholar
  26. Greenwald, M. K., & Hursh, S. R. (2006). Behavioral economic analysis of opioid consumption in heroin-dependent individuals: Effects of unit price and pre-session drug supply. Drug & Alcohol Dependence, 85(1), 35–48. Scholar
  27. Greenwald, M. K., & Steinmiller, C. L. (2009). Behavioral economic analysis of opioid consumption in heroin-dependent individuals: Effects of alternative reinforcer magnitude and post-session drug supply. Drug & Alcohol Dependence, 104(1–2), 84–93. Scholar
  28. Grothendieck, G. (2013). nls2: Non-linear regression with brute force (Version 0.2). [Computer software].Google Scholar
  29. Henley, A. J., DiGennaro Reed, F. D., Kaplan, B. A., & Reed, D. D. (2016a). Quantifying efficacy of workplace reinforcers: An application of behavioral economic demand to evaluate hypothetical work performance. Translational Issues in Psychological Science, 2(2), 174–183.Google Scholar
  30. Henley, A. J., DiGennaro Reed, F. D., Reed, D. D., & Kaplan, B. A. (2016b). A crowdsourced nickel-and-dime approach to analog OBM research: A behavioral economic framework for understanding workforce attrition. Journal of the Experimental Analysis of Behavior, 106(2), 134–144. Scholar
  31. Herrnstein, R. J. (1961). Relative and absolute strength of response as a function of frequency of reinforcement. Journal of the Experimental Analysis of Behavior, 4, 267–272. Scholar
  32. Hursh, S. R. (1978). The economics of daily consumption controlling food- and water-reinforced responding. Journal of the Experimental Analysis of Behavior, 29(3), 475–491. Scholar
  33. Hursh, S. R. (1980). Economic concepts for the analysis of behavior. Journal of the Experimental Analysis of Behavior, 34(2), 219–238. Scholar
  34. Hursh, S. R. (1984). Behavioral economics. Journal of the Experimental Analysis of Behavior, 42(3), 435–452. Scholar
  35. Hursh, S. R. (1991). Behavioral economics of drug self-administration and drug abuse policy. Journal of the Experimental Analysis of Behavior, 56(2), 377–393. Scholar
  36. Hursh, S. R. (2014). Behavioral economics and the analysis of consumption and choice. In F. K. McSweeney & E. S. Murphy (Eds.), The Wiley Blackwell handbook of operant and classical conditioning (pp. 275–305). West Sussex, UK: Wiley.Google Scholar
  37. Hursh, S. R., & Bauman, R. A. (1987). The behavioral analysis of demand. In L. Green & J. H. Kagel (Eds.), Advances in behavioral economics (Vol. 1, pp. 117–165). Norwood, NJ: Ablex Publishing Company.Google Scholar
  38. Hursh, S. R., Raslear, T. G., Bauman, R., & Black, H. (1989). The quantitative analysis of economic behavior with laboratory animals. In K. G. Grunert & F. Ölander (Eds.), Understanding economic behaviour (pp. 393–407). Dordrecht, The Netherlands: Springer Netherlands.Google Scholar
  39. Hursh, S. R., Raslear, T. G., Shurtleff, D., Bauman, R., & Simmons, L. (1988). A cost-benefit analysis of demand for food. Journal of the Experimental Analysis of Behavior, 50(3), 419–440. Scholar
  40. Hursh, S. R., & Roma, P. G. (2013). Behavioral economics and empirical public policy. Journal of the Experimental Analysis of Behavior, 99(1), 98–124. Scholar
  41. Hursh, S. R., & Roma, P. G. (2014). Exponential model of demand in GraphPad Prism. [Software template]. Retrieved from:
  42. Hursh, S. R., & Silberberg, A. (2008). Economic demand and essential value. Psychological Review, 115(1), 186–198. Scholar
  43. Hursh, S. R., & Winger, G. (1995). Normalized demand for drugs and other reinforcers. Journal of the Experimental Analysis of Behavior, 64(3), 373–384. Scholar
  44. Jacobs, E. A., & Bickel, W. K. (1999). Modeling drug consumption in the clinic using simulation procedures: Demand for heroin and cigarettes in opioid-dependent outpatients. Experimental & Clinical Psychopharmacology, 7(4), 412–426. Scholar
  45. Jarmolowicz, D. P., Reed, D. D., Reed, F. D. D., & Bickel, W. K. (2016). The behavioral and neuroeconomics of reinforcer pathologies: Implications for managerial and health decision making. Managerial & Decision Economics, 37(4–5), 274–293. Scholar
  46. Johnson, P. S., & Johnson, M. W. (2014). Investigation of “bath salts” use patterns within an online sample of users in the United States. Journal of Psychoactive Drugs, 46(5), 369–378.Google Scholar
  47. Kagel, J. H., Battalio, R. C., & Green, L. (1995). Economic choice theory: An experimental analysis of animal behavior. Cambridge, UK: Cambridge University Press.Google Scholar
  48. Kaplan, B. A. (2018). beezdemand: Behavioral Economic Easy Demand. R package version 0.1.0. [Computer software]. Retrieved from:
  49. Kaplan, B. A., Foster, R. N. S., Reed, D. D., Amlung, M., Murphy, J. G., & MacKillop, J. (2018). Understanding alcohol motivation using the alcohol purchase task: A methodological systematic review. Drug & Alcohol Dependence, 191(1), 117–140. Scholar
  50. Kaplan, B. A., & Reed, D. D. (2014). Essential value, Pmax, and Omax automated calculator [Spreadsheet application]. Retrieved from:
  51. Kaplan, B. A., & Reed, D. D. (2018). Happy hour drink specials in the Alcohol Purchase Task. Experimental & Clinical Psychopharmacology, 26(2), 156–167. Scholar
  52. Katz, J. L. (1990). Models of relative reinforcing efficacy of drugs and their predictive utility. Behavioural Pharmacology, 1, 283–301.Google Scholar
  53. Koffarnus, M. N., Franck, C. T., Stein, J. S., & Bickel, W. K. (2015a). A modified exponential behavioral economic demand model to better describe consumption data. Experimental & Clinical Psychopharmacology, 23(6), 504–512. Scholar
  54. Koffarnus, M. N., Wilson, A. G., & Bickel, W. K. (2015b). Effects of experimental income on demand for potentially real cigarettes. Nicotine & Tobacco Research, 17(3), 292–298. Scholar
  55. Lea, S. E. (1978). The psychology and economics of demand. Psychological Bulletin, 85, 441–466.Google Scholar
  56. Liao, W., Luo, X., Le, C. T., Chu, H., Epstein, L. H., Yu, J., & Thomas, J. L. (2013). Analysis of cigarette purchase task instrument data with a left-censored mixed effects model. Experimental & Clinical Psychopharmacology, 21(2), 124–132. Scholar
  57. MacKillop, J. (2016). The behavioral economics and neuroeconomics of alcohol use disorders. Alcoholism-Clinical & Experimental Research, 40(4), 672–685. Scholar
  58. MacKillop, J., Brown, C. L., Stojek, M. K., Murphy, C. M., Sweet, L., & Niaura, R. S. (2012a). Behavioral economic analysis of withdrawal- and cue-elicited craving for tobacco: An initial investigation. Nicotine & Tobacco Research, 14(12), 1426–1434. Scholar
  59. MacKillop, J., Few, L. R., Murphy, J. G., Wier, L. M., Acker, J., Murphy, C., . . . Chaloupka, F. (2012b). High-resolution behavioral economic analysis of cigarette demand to inform tax policy. Addiction, 107(12), 2191–2200. doi: Google Scholar
  60. Mackillop, J., Murphy, C. M., Martin, R. A., Stojek, M., Tidey, J. W., Colby, S. M., & Rohsenow, D. J. (2016). Predictive validity of a cigarette purchase task in a randomized controlled trial of contingent vouchers for smoking in individuals with substance use disorders. Nicotine & Tobacco Research, 18(5), 531–537. Scholar
  61. MacKillop, J., & Murphy, J. G. (2007). A behavioral economic measure of demand for alcohol predicts brief intervention outcomes. Drug & Alcohol Dependence, 89(2–3), 227–233. doi:, 233
  62. MacKillop, J., Murphy, J. G., Ray, L. A., Eisenberg, D. T., Lisman, S. A., Lum, J. K., & Wilson, D. S. (2008). Further validation of a cigarette purchase task for assessing the relative reinforcing efficacy of nicotine in college smokers. Experimental & Clinical Psychopharmacology, 16(1), 57–65. Scholar
  63. MacKillop, J., Murphy, J. G., Tidey, J. W., Kahler, C. W., Ray, L. A., & Bickel, W. K. (2009). Latent structure of facets of alcohol reinforcement from a behavioral economic demand curve. Psychopharmacology, 203(1), 33–40. Scholar
  64. MacKillop, J., & Tidey, J. W. (2011). Cigarette demand and delayed reward discounting in nicotine-dependent individuals with schizophrenia and controls: An initial study. Psychopharmacology, 216(1), 91–99. Scholar
  65. Madden, G. J., & Kalman, D. (2010). Effects of bupropion on simulated demand for cigarettes and the subjective effects of smoking. Nicotine & Tobacco Research, 12(4), 416–422. Scholar
  66. Morris, V., Amlung, M., Kaplan, B. A., Reed, D. D., Petker, T., & MacKillop, J. (2017). Using crowdsourcing to examine behavioral economic measures of alcohol value and proportionate alcohol reinforcement. Experimental & Clinical Psychopharmacology, 25(4), 314–321. Scholar
  67. Murphy, J. G., & MacKillop, J. (2006). Relative reinforcing efficacy of alcohol among college student drinkers. Experimental & Clinical Psychopharmacology, 14(2), 219–227. Scholar
  68. Murphy, J. G., Yurasek, A. M., Dennhardt, A. A., Skidmore, J. R., McDevitt-Murphy, M. E., MacKillop, J., & Martens, M. P. (2013). Symptoms of depression and PTSD are associated with elevated alcohol demand. Drug & Alcohol Dependence, 127(1–3), 129–136. Scholar
  69. Nash, J. C. (2016). nlmrt: Functions for Nonlinear Least Squares Solutions (Version 2016.3.2). [computer software]. Retrieved from:
  70. O'Connor, R. J., Bansal-Travers, M., Carter, L. P., & Cummings, K. M. (2012). What would menthol smokers do if menthol in cigarettes were banned? Behavioral intentions and simulated demand. Addiction, 107(7), 1330–1338.Google Scholar
  71. O'Connor, R. J., June, K. M., Bansal-Travers, M., Rousu, M. C., Thrasher, J. F., Hyland, A., & Cummings, K. M. (2014). Estimating demand for alternatives to cigarettes with online purchase tasks. American Journal of Health Behavior, 38(1), 103–113. Scholar
  72. Open Science Collaboration. (2012). An open, large-scale, collaborative effort to estimate the reproducibility of psychological science. Perspectives on Psychological Science, 7(6), 657–660. Scholar
  73. Qualtrics® Research Suite. (n.d.) [Web service].
  74. Quisenberry, A. J., Koffarnus, M. N., Hatz, L. E., Epstein, L. H., & Bickel, W. K. (2015). The experimental tobacco marketplace I: Substitutability as a function of the price of conventional cigarettes. Nicotine & Tobacco Research, 18(7), 1642–1648.Google Scholar
  75. R Core Team. (2018). R: A language and environment for statistical computing (Version 3.5.1). [Computer software]. R Foundation for Statistical Computing.Google Scholar
  76. Reed, D. D. (2015). GraphPad Prism 7.0a template for exponentiated demand analyses. [Software template]. Retrieved from:
  77. Reed, D. D., Kaplan, B. A., Becirevic, A., Roma, P. G., & Hursh, S. R. (2016). Toward quantifying the abuse liability of ultraviolet tanning: A behavioral economic approach to tanning addiction. Journal of the Experimental Analysis of Behavior, 106(1), 93–106. Scholar
  78. Reed, D. D., Niileksela, C. R., & Kaplan, B. A. (2013). Behavioral economics: a tutorial for behavior analysts in practice. Behavior Analysis in Practice, 6(1), 34–54. Scholar
  79. Roma, P. G., Hursh, S. R., & Hudja, S. (2016). Hypothetical purchase task questionnaires for behavioral economic assessments of value and motivation. Managerial & Decision Economics, 37(4–5), 306–323. Scholar
  80. Samuelson, P. A., & Nordhaus, W. D. (2009). Economics New York and London: McGraw-Hill.Google Scholar
  81. Snider, S. E., Cummings, K. M., & Bickel, W. K. (2017). Behavioral economic substitution between conventional cigarettes and e-cigarettes differs as a function of the frequency of e-cigarette use. Drug & Alcohol Dependence, 177, 14–22. Scholar
  82. Spiga, R., Martinetti, M. P., Meisch, R. A., Cowan, K., & Hursh, S. (2005). Methadone and nicotine self-administration in humans: a behavioral economic analysis. Psychopharmacology, 178(2–3), 223–231. doi:, 223
  83. StackOverflow. (n.d.). [Computer software]. Retrieved from
  84. Stein, J. S., Koffarnus, M. N., Snider, S. E., Quisenberry, A. J., & Bickel, W. K. (2015). Identification and management of nonsystematic purchase task data: Toward best practice. Experimental & Clinical Psychopharmacology, 23(5), 377–386. Scholar
  85. Strickland, J. C., Lile, J. A., Rush, C. R., & Stoops, W. W. (2016). Comparing exponential and exponentiated models of drug demand in cocaine users. Experimental & Clinical Psychopharmacology, 24(6), 447–455. Scholar
  86. Strickland, J. C., & Stoops, W. W. (2018). Feasibility, acceptability, and validity of crowdsourcing for collecting longitudinal alcohol use data. Journal of the Experimental Analysis of Behavior, 110(1), 136–153. Scholar
  87. Swirl. (n.d.). Swirl: Learn R in R. [Computer software].
  88. Tabachnick, B. G., & Fidell, L. S. (2013). Using multivariate statistics (6th ed.). Boston, MA: Pearson.Google Scholar
  89. Tippmann, S. (2015). Programming tools: Adventures with R. Nature, 517(7532), 109–110. Scholar
  90. Use R! Series (n.d.) Use R! series. (R. Gentleman, K. Hornik, & G. Parmigiani, eds.). Boston, MA: Springer.Google Scholar
  91. Vincent, P. C., Collins, R. L., Liu, L., Yu, J., De Leo, J. A., & Earleywine, M. (2017). The effects of perceived quality on behavioral economic demand for marijuana: A web-based experiment. Drug & Alcohol Dependence, 170, 174–180. Scholar
  92. Wilson, A. G., Franck, C. T., Koffarnus, M. N., & Bickel, W. K. (2016). Behavioral economics of cigarette purchase tasks: Within-subject comparison of real, potentially real, and hypothetical cigarettes. Nicotine & Tobacco Research, 18(5), 524–530. Scholar
  93. Wine, B., Gilroy, S., & Hantula, D. A. (2012). Temporal (in)stability of employee preferences for rewards. Journal of Organizational Behavior Management, 32(1), 58–64. Scholar
  94. Xie, Y. (2016). Dynamic documents with R and knitr. Boca Raton, Florida: Chapman; Hall/CRC.Google Scholar
  95. Yu, J., Liu, L., Collins, R. L., Vincent, P. C., & Epstein, L. H. (2014). Analytical problems and suggestions in the analysis of behavioral economic demand curves. Multivariate Behavioral Research, 49(2), 178–192. Scholar
  96. Zhao, T., Luo, X., Chu, H., Le, C. T., Epstein, L. H., & Thomas, J. L. (2016). A two-part mixed effects model for cigarette purchase task data. Journal of the Experimental Analysis of Behavior, 106(3), 242–253. Scholar

Copyright information

© Association for Behavior Analysis International 2018

Authors and Affiliations

  1. 1.Virginia Tech Carilion Research InstituteVirginia Polytechnic Institute and State UniversityRoanokeUSA
  2. 2.Department of PsychologyLouisiana State UniversityBaton RougeUSA
  3. 3.Department of Applied Behavioral ScienceUniversity of KansasLawrenceUSA
  4. 4.Institutes for Behavior Resources, Inc.BaltimoreUSA
  5. 5.Department of Psychiatry and Behavioral SciencesJohns Hopkins University School of MedicineBaltimoreUSA

Personalised recommendations