IDEAS home Printed from https://ideas.repec.org/p/arx/papers/2307.10694.html

PySDTest: a Python/Stata Package for Stochastic Dominance Tests

Author

Listed:
  • Kyungho Lee
  • Yoon-Jae Whang

Abstract

We introduce PySDTest, a Python/Stata package for statistical tests of stochastic dominance. PySDTest implements various testing procedures such as Barrett and Donald (2003), Linton et al. (2005), Linton et al. (2010), and Donald and Hsu (2016), along with their extensions. Users can flexibly combine several resampling methods and test statistics, including the numerical delta method (D\"umbgen, 1993; Hong and Li, 2018; Fang and Santos, 2019). The package allows for testing advanced hypotheses on stochastic dominance relations, such as stochastic maximality among multiple prospects. We first provide an overview of the concepts of stochastic dominance and testing methods. Then, we offer practical guidance for using the package and the Stata command pysdtest. We apply PySDTest to investigate the portfolio choice problem between the daily returns of Bitcoin and the S&P 500 index as an empirical illustration. Our findings indicate that the S&P 500 index returns second-order stochastically dominate the Bitcoin returns.

Suggested Citation

  • Kyungho Lee & Yoon-Jae Whang, 2023. "PySDTest: a Python/Stata Package for Stochastic Dominance Tests," Papers 2307.10694, arXiv.org, revised Aug 2024.
  • Handle: RePEc:arx:papers:2307.10694
    as

    Download full text from publisher

    File URL: http://arxiv.org/pdf/2307.10694
    File Function: Latest version
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Lee, Kyungho & Linton, Oliver & Whang, Yoon-Jae, 2023. "Testing for time stochastic dominance," Journal of Econometrics, Elsevier, vol. 235(2), pages 352-371.
    2. Garry F. Barrett & Stephen G. Donald, 2003. "Consistent Tests for Stochastic Dominance," Econometrica, Econometric Society, vol. 71(1), pages 71-104, January.
    3. Anderson, Gordon, 1996. "Nonparametric Tests of Stochastic Dominance in Income Distributions," Econometrica, Econometric Society, vol. 64(5), pages 1183-1193, September.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Hooi Hooi Lean & Michael McAleer & Wing-Keung Wong, 2013. "Risk-averse and Risk-seeking Investor Preferences for Oil Spot and Futures," Documentos de Trabajo del ICAE 2013-31, Universidad Complutense de Madrid, Facultad de Ciencias Económicas y Empresariales, Instituto Complutense de Análisis Económico, revised Aug 2013.
    2. Jesus Gonzalo & Jose Olmo, 2014. "Conditional Stochastic Dominance Tests In Dynamic Settings," International Economic Review, Department of Economics, University of Pennsylvania and Osaka University Institute of Social and Economic Research Association, vol. 55(3), pages 819-838, August.
    3. Maasoumi, Esfandiar & Almas Heshmati, 2003. "Evaluating Dominance Ranking of PSID Incomes by various Household Attributes," Departmental Working Papers 0509, Southern Methodist University, Department of Economics.
    4. David Lander & David Gunawan & William Griffiths & Duangkamon Chotikapanich, 2020. "Bayesian assessment of Lorenz and stochastic dominance," Canadian Journal of Economics/Revue canadienne d'économique, John Wiley & Sons, vol. 53(2), pages 767-799, May.
    5. Lean, Hooi Hooi & McAleer, Michael & Wong, Wing-Keung, 2015. "Preferences of risk-averse and risk-seeking investors for oil spot and futures before, during and after the Global Financial Crisis," International Review of Economics & Finance, Elsevier, vol. 40(C), pages 204-216.
    6. Tsang, Chun-Kei & Wong, Wing-Keung & Horowitz, Ira, 2016. "A stochastic-dominance approach to determining the optimal home-size purchase: The case of Hong Kong," MPRA Paper 69175, University Library of Munich, Germany.
    7. Marcel Voia, 2008. "A Distributional Analysis Of Treatment Effects In Randomized Experiments," Economics Bulletin, AccessEcon, vol. 3(36), pages 1-9.
    8. Grönqvist, Charlotta, 2009. "Empirical studies on the private value of Finnish patents," Bank of Finland Scientific Monographs, Bank of Finland, volume 0, number sm2009_041, December.
    9. Miguel A. Delgado & Juan Carlos Escanciano, 2013. "Conditional Stochastic Dominance Testing," Journal of Business & Economic Statistics, Taylor & Francis Journals, vol. 31(1), pages 16-28, January.
    10. Wong, Wing-Keung & Phoon, Kok Fai & Lean, Hooi Hooi, 2008. "Stochastic dominance analysis of Asian hedge funds," Pacific-Basin Finance Journal, Elsevier, vol. 16(3), pages 204-223, June.
    11. Lee, Kyungho & Linton, Oliver & Whang, Yoon-Jae, 2023. "Testing for time stochastic dominance," Journal of Econometrics, Elsevier, vol. 235(2), pages 352-371.
    12. Khaled, Mohamad A. & Makdissi, Paul & Yazbeck, Myra, 2018. "Income-related health transfers principles and orderings of joint distributions of income and health," Journal of Health Economics, Elsevier, vol. 57(C), pages 315-331.
    13. David Lander & David Gunawan & William E. Griffiths & Duangkamon Chotikapanich, 2016. "Bayesian Assessment of Lorenz and Stochastic Dominance Using a Mixture of Gamma Densities," Department of Economics - Working Papers Series 2023, The University of Melbourne.
    14. Ozkan Eren & Daniel L. Millimet, 2008. "Time to learn? The organizational structure of schools and student achievement," Studies in Empirical Economics, in: Christian Dustmann & Bernd Fitzenberger & Stephen Machin (ed.), The Economics of Education and Training, pages 47-78, Springer.
    15. Mehmet Pinar & Thanasis Stengos & M. Ege Yazgan, 2012. "Is there an Optimal Forecast Combination? A Stochastic Dominance Approach to Forecast Combination Puzzle," Working Paper series 17_12, Rimini Centre for Economic Analysis.
    16. Pinar, Mehmet & Stengos, Thanasis & Topaloglou, Nikolas, 2020. "On the construction of a feasible range of multidimensional poverty under benchmark weight uncertainty," European Journal of Operational Research, Elsevier, vol. 281(2), pages 415-427.
    17. Guo, Xu & Wong, Wing-Keung & Zhu, Lixing, 2013. "Make Almost Stochastic Dominance really Almost," MPRA Paper 49745, University Library of Munich, Germany.
    18. Grönqvist, Charlotta, 2009. "Empirical studies on the private value of Finnish patents," Scientific Monographs, Bank of Finland, number 2009_041.
    19. Ian Crawford, 2005. "A nonparametric test of stochastic dominance in multivariate distributions," School of Economics Discussion Papers 1205, School of Economics, University of Surrey.
    20. Gordon Anderson & Teng Wah Leo, 2014. "Ranking Alternative Non-Combinable Prospects: A Stochastic Dominance Based Route to the Second Best Solution," Working Papers tecipa-520, University of Toronto, Department of Economics.

    More about this item

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:arx:papers:2307.10694. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: arXiv administrators (email available below). General contact details of provider: http://arxiv.org/ .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.