Skip to main content

Gaussian and Binomial distributions

Project description

Gaussian Theorem

Gaussian Theorem: A Python Package for Gaussian and Binomial Distributions

GAUSSIAN THEOREM

Table of Contents

Introduction

Gaussian Theorem is a Python package that provides classes for working with Gaussian and Binomial distributions. This package is designed to make it easy for developers and data scientists to perform calculations, visualize distributions, and integrate statistical functionality into their projects.

Features

  • Gaussian Distribution:

    • Calculate mean and standard deviation.
    • Generate probability density function (PDF) values.
    • Perform distribution addition.
  • Binomial Distribution:

    • Calculate mean and standard deviation from given probabilities and sample sizes.
    • Visualize distributions with histograms.
    • Plot PDFs for Binomial distributions.

Installation

From PyPI

You can install the package directly from PyPI using pip. Make sure you have Python 3.x installed on your machine.

pip install gaussian_theorems

From Source

If you prefer installing from the source, follow these steps:

1. Clone the repository:

git clone https://github.com/Dharren09/Gaussian_Theorem.git
cd Gaussian_Theorem

2. Install the required dependencies:

pip install -r requirements.txt

3. Install the Package:

python setup.py install

Usage

# Example code demonstrating how to use the Gaussian class
from Gaussian_Theorem.gaussiandistribution import Gaussian

# Create a Gaussian distribution instance
gaussian = Gaussian(25, 4)

# Read data from a file (replace 'data.txt' with your data file)
gaussian.read_data_file('datasets/numbers.txt')

# Calculate mean and standard deviation
mean = gaussian.calculate_mean()
stdev = gaussian.calculate_stdev()

# Print the Gaussian distribution characteristics
print(gaussian)

# Plot histogram and PDF
gaussian.plot_histogram_pdf()

Project Structure

The project is structured as follows:

GAUSSIAN_THEOREM/
|-- Gaussian_Theorem/
|   |-- __init__.py
|   |-- gaussiandistribution.py
|   |-- generaldistribution.py
|-- Binomialdistributions/
|   |-- __init__.py
|   |-- binomialdistributions.py
|-- tests/
|   |-- __init__.py
|   |-- tests.py
|-- setup.py
|-- License
|-- CODE_OF_CONDUCT.md
|-- contribution_guidelines.md
|-- requirements.txt
|-- datasets/
|   |-- numbers.txt
|   |-- numbers_binomial.txt
|-- build

Testing

To run tests, execute the following command:

python -m unittest tests.tests

Contributing

We welcome contributions! If you find a bug or have an enhancement idea, please open an issue or submit a pull request. Please check our Contribution Guidelines for details.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Acknowledgments

The project is inspired by the need for a simple yet powerful Python package for working with statistical distributions. Special thanks to the Matplotlib, Scikit-learn, Scipy teams for their excellent libraries Plus Udacity Data Science instructors for their immersive contributions towards my knowlegde base.

Contact

For any questions or feedback, feel free to reach out:

Email: dharrenpius@outlook.com Twitter: @iamdevdharrenzug GitHub: Dharren09

Project details


Release history Release notifications | RSS feed

This version

1.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gaussian_theorems-1.1.tar.gz (7.9 kB view details)

Uploaded Source

File details

Details for the file gaussian_theorems-1.1.tar.gz.

File metadata

  • Download URL: gaussian_theorems-1.1.tar.gz
  • Upload date:
  • Size: 7.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.12

File hashes

Hashes for gaussian_theorems-1.1.tar.gz
Algorithm Hash digest
SHA256 622c9d5dd7f7df8906f74ec4c0bb51139332b1e9eea64d153ecef491347f6663
MD5 35e86a3da64c3bba5f735c1c9d58c68a
BLAKE2b-256 6e7f3e222a1b4bbaad7240a9e7d09a8e223216bbfeb5a10dc307a940bcec33a4

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page