Giter Club home page Giter Club logo

pysdtest's Introduction

PySDTest

A Python Package for Stochastic Dominance Tests

PySDTest is a Python 3 implementation of routines for Stochastic Dominance tests. This package was created by Kyungho Lee in collaboration with Yoon-Jae Whang.

This package implements stochastic dominance tests proposed by Barrett and Donald (2003, BD), Linton, Maasoumi and Whang (2005, LMW), Linton, Song and Whang (2010, LSW), Donald and Hsu (2014, DH). PySDTest also contains stochastic dominance tests by applying the numerical delta method (Hong and Li (2018, HL)).

Installation

PySDTest is listed on the Python Package Index (PyPI) which is a repository of software for the Python programming language. If Python is installed on your computer, you can install PySDTest by entering:

pip install PySDTest

in Windows cmd or Mac (or Linux) terminal. For detailed information about installing a Python package, see Python Package User Guide in PyPI.

Importation

After installing PySDTest, an user can import it through the following code:

import pysdtest

Features

  • Stochastic dominance (SD) testing via imposing the least favorable case (BD, LMW)
  • SD testing via Contact-set approach (LSW)
  • SD testing via Selective recentering approach (DH)
  • SD testing via Numerical delta method (HL)
  • Advanced hypotheses testing (Joint hypotheses testing)
  • Plotting (s-th order) CDFs
  • Resampling: bootstrap, subsampling, and paired-bootstrap

Integration with Other Software

Python provides significant advantage regarding interaction with other programming languages and statistical software. Our package can be used in MATLAB, R, Julia, and Stata.

In MATLAB, an user can implement PySDTest as:

% Calling PySDTest in MATLAB
py.pysdtest

The reticulate library in R and the PyCall package in Julia serve similar feature, which calls Python modules in R and Julia, respectively:

# Calling PySDTest in R

library(reticulate)
pysdtest <- import("pysdtest")
# Calling PySDTest in Julia

using PyCall
pysdtest = pyimport("pysdtest")

In Stata, an user can call PySDTest by plugging python codes in between Python: and end. For example, the following codes work for importing PySDTest:

" Calling PySDTest in Stata "
python:
import pysdtest
end

In addition, a user can use python command in Stata to activate Python environment in Stata. For more detailed information, please refer to the Using MATLAB with Python in MATLAB, reticulate library in R, PyCall package in Julia and Python integration feature in Stata.

pysdtest's People

Contributors

lee-kyungho avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.