Metadata-Version: 2.1
Name: pyMicroeconomics
Version: 0.0.6
Summary: Functions for microeconomic analysis
Author-email: J H <jhilton@wayne.edu>
Requires-Python: >=3.8.1
Description-Content-Type: text/markdown
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Requires-Dist: sympy>=1.13
Requires-Dist: numpy>=2.1.2
Requires-Dist: scipy>=1.14
Requires-Dist: IPython>=8.28
Requires-Dist: matplotlib>=3.9
Requires-Dist: ipywidgets>=8.1.5
Requires-Dist: pyspark>=3.0.0 ; extra == "spark"
Requires-Dist: bandit[toml]==1.7.5 ; extra == "test"
Requires-Dist: black==23.3.0 ; extra == "test"
Requires-Dist: check-manifest==0.49 ; extra == "test"
Requires-Dist: flake8-bugbear==23.5.9 ; extra == "test"
Requires-Dist: flake8-docstrings ; extra == "test"
Requires-Dist: flake8-formatter_junit_xml ; extra == "test"
Requires-Dist: flake8 ; extra == "test"
Requires-Dist: flake8-pyproject ; extra == "test"
Requires-Dist: pre-commit==3.3.1 ; extra == "test"
Requires-Dist: pylint==2.17.4 ; extra == "test"
Requires-Dist: pylint_junit ; extra == "test"
Requires-Dist: pytest-cov==4.0.0 ; extra == "test"
Requires-Dist: pytest-mock<3.10.1 ; extra == "test"
Requires-Dist: pytest-runner ; extra == "test"
Requires-Dist: pytest==7.3.1 ; extra == "test"
Requires-Dist: pytest-github-actions-annotate-failures ; extra == "test"
Requires-Dist: shellcheck-py==0.9.0.2 ; extra == "test"
Project-URL: Documentation, https://https://github.com/joshhilton/pyMicroeconomics/tree/main#readme
Project-URL: Source, https://https://github.com/joshhilton/pyMicroeconomics
Project-URL: Tracker, https://https://github.com/joshhilton/pyMicroeconomics/issues
Provides-Extra: spark
Provides-Extra: test

# pyMicroeconomics

pyMicroeconomics is a Python package designed for symbolic analysis and visualization of market equilibrium conditions. This package allows you to define various supply and demand curves, calculate market equilibrium points, and visualize these using interactive plots. It integrates several powerful libraries, such as Sympy and Matplotlib, making it a versatile tool for microeconomic analysis.

## Features
- Define different types of supply and demand curves (linear, power, exponential, quadratic).
- Calculate key market metrics, including equilibrium price and quantity.
- Compute consumer surplus, producer surplus, and total surplus.
- Visualize market equilibrium interactively with ipywidgets and Matplotlib.

## Table of Contents
1. [Getting Started](#getting-started)
2. [Installation](#installation)
3. [Usage Examples](#usage-examples)
4. [Documentation](#documentation)
5. [Contributing](#contributing)
6. [License](#license)
7. [Acknowledgments](#acknowledgments)

## Getting Started
To get started with pyMicroeconomics, follow these steps:

### Prerequisites
- Python 3.8 or later
- Jupyter Notebook or JupyterLab for interactive usage

### Installation
To install pyMicroeconomics, use pip:
```bash
pip install pyMicroeconomics
```

This package is intended to be used interactively within Jupyter Notebooks to visualize economic concepts dynamically.

### Setting Up the Environment
You can also use the provided **Dockerfile** and **devcontainer.json** to set up a complete development environment. This is especially useful if you use **Visual Studio Code** or **GitHub Codespaces**. To start developing with pyMicroeconomics, clone the repository and spin up a Docker container:
```bash
git clone https://github.com/joshhilton/pyMicroeconomics.git
cd pyMicroeconomics
docker build -t pymicroeconomics .
docker run -it -v $(pwd):/app pymicroeconomics
```

## Usage Examples
### Example 1: Basic Market Equilibrium
Below is a simple example of finding the market equilibrium using linear supply and demand curves:

```python
import pyMicroeconomics as pm

# Define demand and supply curves
demand = pm.linear_demand()
supply = pm.linear_supply()

# Calculate equilibrium
equilibrium = pm.market_equilibrium(demand, supply)

# Display equilibrium details
pm.display_equilibrium(equilibrium)
pm.plot_equilibrium(equilibrium)
```
This visualization allows users to adjust the parameters interactively and observe changes in real-time.

## Documentation
The complete documentation for pyMicroeconomics, including detailed guides, examples, and the API reference, is available [here](https://github.com/joshhilton/pyMicroeconomics/tree/main/docs).

If you need specific help on running tests or contributing, check out the **Developer Guide** and **Testing Guide** in the `docs/` directory.

## Contributing
We welcome contributions to the project! Please follow these steps to get involved:
1. Fork the repository.
2. Create a feature branch (`git checkout -b feature/AmazingFeature`).
3. Commit your changes (`git commit -m 'Add some AmazingFeature'`).
4. Push to the branch (`git push origin feature/AmazingFeature`).
5. Open a Pull Request.

Please refer to the **CONTRIBUTING.md** document for more detailed guidelines.

## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

## Acknowledgments
- Built using **SymPy**, **Matplotlib**, and **ipywidgets**.

If you have any questions or need further help, please feel free to open an issue on [GitHub](https://github.com/joshhilton/pyMicroeconomics/issues).

## Badges
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/pyMicroeconomics)
![Build Status](https://github.com/joshhilton/pyMicroeconomics/workflows/Build/badge.svg)
![License](https://img.shields.io/github/license/joshhilton/pyMicroeconomics)

---

