Skip to content

Sundar-Tibshirani Gap Statistic Package for an alternate null Hypothesis where the cluster labels are already known. This package implements the Sundar-Tibshirani Gap Statistic for cluster analysis.

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENSE.md
Notifications You must be signed in to change notification settings

pvsundar/sundargap_statistic

Repository files navigation

Sundar-Tibshirani Gap Statistic Package

This package implements the

Sundar-Tibshirani Gap Statistic when the Cluster Labels are specified.

Installation

  1. Clone the repository:
git clone https://github.com/pvsundar/sundar_gap_stat.git
  1. Navigate to the package directory:
cd sundar_gap_stat
  1. Install the package and its dependencies:
pip install .

Alternatively, you can install directly from the GitHub repository:

pip install git+https://github.com/pvsundar/sundar_gap_stat.git

Usage Example

Here’s a basic example of how to use the package with the Iris dataset:

from sklearn.datasets import load_iris
from gap_statistic.utils import sundar_tibshirani_gap_statistic_main
from sklearn.datasets import fetch_openml
import numpy as np
X, y = load_iris(return_X_y=True)
sundar_tibshirani_gap_statistic_main(X, y, k=3)

Contributing

Feel free to open an issue or submit a pull request if you'd like to contribute.

License

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

Acknowledgments

Special thanks to all contributors and the open-source community. in particular to the code by Mavengence who created the package for the Tibshirani Gap Statistic. https://github.com/Mavengence/GapStatistics/blob/main/gapstatistics/gapstatistics.py

About

Sundar-Tibshirani Gap Statistic Package for an alternate null Hypothesis where the cluster labels are already known. This package implements the Sundar-Tibshirani Gap Statistic for cluster analysis.

Resources

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENSE.md

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published