Skip to main content

Gaussian and Binomial distributions

Project description

# MLND Probability Classes

This package exposes two probability distribution classes, Gaussian and Binomial, and was made as part of the Udacity Machine Learning Engineer Nanodegree.

This package was created for educational purposes.

# Use of Gaussian and Binomial

The classes can be imported as so: from typekev_mlnd_probability import Gaussian and from typekev_mlnd_probability import Binomial

Both classes are initialized with the following attributes:

  • mean: The mean or average

  • stdev: Standard deviation

  • data: The list of data in which to calculate the other attributes

Both classes also contain a read_data_file method.

The Gaussian and Binomial classes also contain unique attributes and methods. Though names may overlap, implementation will differ.

## Gaussian attributes and methods

The Gaussian class contains the following additional methods:

  • calculate_mean

  • calculate_stdev

  • plot_histogram

  • pdf

  • plot_histogram_pdf

The magic methods __add__ and __repr__ have also been implemented.

## Binomial attributes and methods

The Binomial class contains the following additional attributes:

  • n: The size of the data set

  • p: The probability

The Binomial class contains the following additional methods:

  • calculate_mean

  • calculate_stdev

  • replace_stats_with_data

  • plot_bar

  • pdf

  • plot_bar_pdf

The magic methods __add__ and __repr__ have also been implemented.

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

typekev_mlnd_probability-1.1.tar.gz (3.9 kB view hashes)

Uploaded Source

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