Catalog PyPI
PACKAGE EXPLORERView in registry

abc-classification

PyPI

A package for ABC classification

Versions collected1
Direct dependencies2From release 0.8
Last observed20 Oct, 17:13 UTC

README

Version 0.8 documentation

ABC classification library

ABC classification is an inventory categorisation technique. A typical example of ABC classification is the segmentation of products (entity) based on sales (value). The best-selling products that contribute to up to 70% of the total sales belong to cluster A. The products making up the next 20% of sales are in cluster B, whereas the products representing the last 10% of sales, belong to class C. Hence, the pattern is named after the three clusters (ABC).

Example

Installation

pip install abc-classification

Import

from abc_classification.abc_classifier import ABCClassifier

Let's say we have dataframe

producttotal sold
fade cream27000
powders24000
shadows18000
mascara16000
lipstick6000
concealer5000
sculptors4000

You can create ABCClasifier object, pass your dataframe to it and call classify method.

abc_clf = ABCClassifier(df)
abc_df = abc_clf.classify('product', 'total sold')

This way you'll get new dataframe with classified products.

producttotal soldclass
fade cream27000A
powders24000A
shadows18000A
mascara16000B
lipstick6000B
concealer5000C
sculptors4000C

You also can use brief_abc method to get aggregated information

abc_clf.brief_abc(abc_df)
classtotal sold
A69000
B16000
C15000

You can plot pareto chart.

from abc_classification.abc_visualiser import pareto_chart


pareto_chart(abc_df, 'total_sold', 'product')

Pareto chart

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Versions 1

Collected releases
VersionPublishedDirect dependenciesOpen version
0.85 Nov 20222

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
melikbekyanashot/abc-classification

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 17:13 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:6593c5a922395b55fb35dc40a6ec5dfaa30300b893cc453202279304de46b987