rasbt/mlxtend

Public

A library of extension and helper modules for Python's data analysis and machine learning libraries.

  • Stars5.2k+1 tuần này
  • Forks941
  • Watchers113
  • Issues124
  • Ngày tạo14/08/2014
  • Cập nhật gần nhất24/10/2026
  • Ngôn ngữPython
  • Giấy phép—
README.md15.9 KBRaw

DOI PyPI version Build status codecov Python 3 License Discuss

mlxtend logo

Mlxtend (machine learning extensions) is a Python library of useful tools for the day-to-day data science tasks. It is primarily used for:

  • Ensemble methods such as stacking and voting classifiers
  • Feature selection and feature extraction techniques
  • Visualization utilities (e.g., decision regions, confusion matrices)
  • Plotting helpers for model analysis
  • Frequent pattern mining, including the Apriori algorithm for association rule mining

Sebastian Raschka 2014-2026


Links



Installing mlxtend

Using uv

To add mlxtend to a uv-managed project, run

uv add mlxtend

For a one-off command without changing your current project, run

uv run --with mlxtend python -c "import mlxtend; print(mlxtend.__version__)"

Dev Version

The mlxtend version on PyPI may always be one step behind; you can install the latest development version from the GitHub repository by executing

uv add "mlxtend @ git+https://github.com/rasbt/mlxtend.git"

Or, you can fork the GitHub repository from https://github.com/rasbt/mlxtend and run mlxtend from your local checkout via

git clone https://github.com/<your_username>/mlxtend.git
cd mlxtend
uv sync --group dev
uv run python -c "import mlxtend; print(mlxtend.__version__)"


Examples

import numpy as np
import matplotlib.pyplot as plt
import matplotlib.gridspec as gridspec
import itertools
from sklearn.linear_model import LogisticRegression
from sklearn.svm import SVC
from sklearn.ensemble import RandomForestClassifier
from mlxtend.classifier import EnsembleVoteClassifier
from mlxtend.data import iris_data
from mlxtend.plotting import plot_decision_regions

# Initializing Classifiers
clf1 = LogisticRegression(random_state=0)
clf2 = RandomForestClassifier(random_state=0)
clf3 = SVC(random_state=0, probability

Nội dung README thuộc về rasbt và cộng đồng đóng góp, giấy phép Không có giấy phép. Nguồn: github.com/rasbt/mlxtend