pysyncon


Namepysyncon JSON
Version 1.5.2 PyPI version JSON
download
home_pagehttps://github.com/sdfordham/pysyncon/
SummaryNone
upload_time2025-01-08 16:33:57
maintainerNone
docs_urlNone
authorStiofán Fordham
requires_python>=3.8
licenseMIT License
keywords synth augsynth synthetic-control-method causal-inference
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            

# pysyncon ![](https://img.shields.io/badge/python-3.8+-blue.svg) [![codecov](https://codecov.io/gh/sdfordham/pysyncon/graph/badge.svg?token=hmi7xHQ4OT)](https://codecov.io/gh/sdfordham/pysyncon)

A python module for the synthetic control method that provides implementations of:

- Synthetic Control Method (Abadie & Gardeazabal 2003)
- Robust Synthetic Control Method (Amjad, Shah & Shen 2018)
- Augmented Synthetic Control Method (Ben-Michael, Feller & Rothstein 2021)
- Penalized Synthetic Control Method (Abadie & L'Hour 2021)

The package also provides methods for performing placebo tests and generating confidence intervals.

The implementation of the synthetic control method aims to be reconcilable with the R package [Synth](https://CRAN.R-project.org/package=Synth) and similarly the implementation of the Augmented synthetic control method and the R package [augsynth](https://github.com/ebenmichael/augsynth).

## Installation
Install it from PyPI using pip:

````bash
python -m pip install pysyncon
````

## Usage

Documentation is available on [github-pages](https://sdfordham.github.io/pysyncon/). In the examples folder are notebooks reproducing the weights from:

- The Economic Costs of Conflict: A Case Study of the Basque Country, Alberto Abadie and Javier Gardeazabal; The American Economic Review Vol. 93, No. 1 (Mar., 2003), pp. 113-132. ([notebook here](examples/basque.ipynb))
- The worked example 'Prison construction and Black male incarceration' from the last chapter of 'Causal Inference: The Mixtape' by Scott Cunningham. ([notebook here](examples/texas.ipynb))
- Comparative Politics and the Synthetic Control Method, Alberto Abadie, Alexis Diamond and Jens Hainmueller; American Journal of Political Science Vol. 59, No. 2 (April 2015), pp. 495-510. ([notebook here](examples/germany.ipynb))

## Citation

If you use this package in your research, you can cite it as below.

```
@software{pysyncon,
  author = {Fordham, Stiofán},
  month = dec,
  title = {{pysyncon: a Python package for the Synthetic Control Method}},
  url = {https://github.com/sdfordham/pysyncon},
  year = {2022}
}
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/sdfordham/pysyncon/",
    "name": "pysyncon",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "Synth, augsynth, synthetic-control-method, causal-inference",
    "author": "Stiof\u00e1n Fordham",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/a5/00/fb5bcd0bcd54243fc7dc9c2bd70b06c652e631a6f686942864cf5729e04c/pysyncon-1.5.2.tar.gz",
    "platform": null,
    "description": "\n\n# pysyncon ![](https://img.shields.io/badge/python-3.8+-blue.svg) [![codecov](https://codecov.io/gh/sdfordham/pysyncon/graph/badge.svg?token=hmi7xHQ4OT)](https://codecov.io/gh/sdfordham/pysyncon)\n\nA python module for the synthetic control method that provides implementations of:\n\n- Synthetic Control Method (Abadie & Gardeazabal 2003)\n- Robust Synthetic Control Method (Amjad, Shah & Shen 2018)\n- Augmented Synthetic Control Method (Ben-Michael, Feller & Rothstein 2021)\n- Penalized Synthetic Control Method (Abadie & L'Hour 2021)\n\nThe package also provides methods for performing placebo tests and generating confidence intervals.\n\nThe implementation of the synthetic control method aims to be reconcilable with the R package [Synth](https://CRAN.R-project.org/package=Synth) and similarly the implementation of the Augmented synthetic control method and the R package [augsynth](https://github.com/ebenmichael/augsynth).\n\n## Installation\nInstall it from PyPI using pip:\n\n````bash\npython -m pip install pysyncon\n````\n\n## Usage\n\nDocumentation is available on [github-pages](https://sdfordham.github.io/pysyncon/). In the examples folder are notebooks reproducing the weights from:\n\n- The Economic Costs of Conflict: A Case Study of the Basque Country, Alberto Abadie and Javier Gardeazabal; The American Economic Review Vol. 93, No. 1 (Mar., 2003), pp. 113-132. ([notebook here](examples/basque.ipynb))\n- The worked example 'Prison construction and Black male incarceration' from the last chapter of 'Causal Inference: The Mixtape' by Scott Cunningham. ([notebook here](examples/texas.ipynb))\n- Comparative Politics and the Synthetic Control Method, Alberto Abadie, Alexis Diamond and Jens Hainmueller; American Journal of Political Science Vol. 59, No. 2 (April 2015), pp. 495-510. ([notebook here](examples/germany.ipynb))\n\n## Citation\n\nIf you use this package in your research, you can cite it as below.\n\n```\n@software{pysyncon,\n  author = {Fordham, Stiof\u00e1n},\n  month = dec,\n  title = {{pysyncon: a Python package for the Synthetic Control Method}},\n  url = {https://github.com/sdfordham/pysyncon},\n  year = {2022}\n}\n```\n",
    "bugtrack_url": null,
    "license": "MIT License",
    "summary": null,
    "version": "1.5.2",
    "project_urls": {
        "Homepage": "https://github.com/sdfordham/pysyncon/"
    },
    "split_keywords": [
        "synth",
        " augsynth",
        " synthetic-control-method",
        " causal-inference"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a4e7b46aebb012b889167013087aa1ef8f5363440aeb0cb0c6be0fd7b5c63f44",
                "md5": "1309db523bff3003313749b4cabd95ac",
                "sha256": "622651cb75201843563f47d0712c88bd6394f24ab5b7f2ad7767e53e48d719f2"
            },
            "downloads": -1,
            "filename": "pysyncon-1.5.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "1309db523bff3003313749b4cabd95ac",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 27914,
            "upload_time": "2025-01-08T16:33:53",
            "upload_time_iso_8601": "2025-01-08T16:33:53.831248Z",
            "url": "https://files.pythonhosted.org/packages/a4/e7/b46aebb012b889167013087aa1ef8f5363440aeb0cb0c6be0fd7b5c63f44/pysyncon-1.5.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a500fb5bcd0bcd54243fc7dc9c2bd70b06c652e631a6f686942864cf5729e04c",
                "md5": "2d1c0646aa4443a9996cdb7557ba3e3b",
                "sha256": "ce4f6f0f77b39eef152854be98be16786a798f541b2f50512f0535fa92195784"
            },
            "downloads": -1,
            "filename": "pysyncon-1.5.2.tar.gz",
            "has_sig": false,
            "md5_digest": "2d1c0646aa4443a9996cdb7557ba3e3b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 35202,
            "upload_time": "2025-01-08T16:33:57",
            "upload_time_iso_8601": "2025-01-08T16:33:57.381067Z",
            "url": "https://files.pythonhosted.org/packages/a5/00/fb5bcd0bcd54243fc7dc9c2bd70b06c652e631a6f686942864cf5729e04c/pysyncon-1.5.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-08 16:33:57",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "sdfordham",
    "github_project": "pysyncon",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "pysyncon"
}
        
Elapsed time: 1.03349s