A Python library for data cleaning, statistical analysis, and insights.
Project description
smartanalytics
A Python library for data cleaning, statistical analysis, and data insights.
Installation
pip install smartanalytics
Modules
1. cleaning — Data Cleaning
Clean and preprocess your DataFrames before analysis.
| Function | Description |
|---|---|
remove_nulls(df) |
Remove rows with missing values |
remove_duplicates(df) |
Remove duplicate rows |
fill_missing(df, value) |
Fill NaN values with a given value |
normalize_data(df) |
Min-Max normalize all numeric columns |
2. stats — Statistics
Compute core statistical measures from lists.
| Function | Description |
|---|---|
mean(data) |
Arithmetic mean |
median(data) |
Middle value |
mode(data) |
Most frequent value(s) |
standard_deviation(data) |
Spread of the data |
3. insights — Data Insights
Advanced analysis functions for real-world data understanding.
| Function | Description |
|---|---|
detect_outliers(data) |
IQR-based outlier detection |
correlation_matrix(df) |
Pearson correlation between columns |
dataset_summary(df) |
Shape, dtypes, nulls, and stats overview |
missing_value_report(df) |
Column-wise missing value report |
Quick Example
import pandas as pd
from smartanalytics import cleaning, stats, insights
# Sample dataset
df = pd.DataFrame({
'Age': [25, 30, None, 22, 30],
'Score': [88, 92, 95, 88, 92],
'Salary': [30000, 45000, 50000, 28000, 45000]
})
# Clean the data
df = cleaning.remove_nulls(df)
df = cleaning.remove_duplicates(df)
# Statistical analysis
print(stats.mean(df['Score'].tolist()))
print(stats.standard_deviation(df['Salary'].tolist()))
# Generate insights
print(insights.missing_value_report(df))
print(insights.correlation_matrix(df))
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file smartanalytics-1.0.0.tar.gz.
File metadata
- Download URL: smartanalytics-1.0.0.tar.gz
- Upload date:
- Size: 4.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe8d99587d6b3fe38573acf3405c2779ee61629b179eb174e18540664066769a
|
|
| MD5 |
62bd8723de247b7cec1e478555a2f0f7
|
|
| BLAKE2b-256 |
21a07fcc439bc64f97ae0f7bd9f3e886a7e15a34ea6a4272cb25151049fed179
|
File details
Details for the file smartanalytics-1.0.0-py3-none-any.whl.
File metadata
- Download URL: smartanalytics-1.0.0-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2fb14496914d9e9d2f33d3f031c3c43218045d9dd2a5963bc0e43a0d330b38aa
|
|
| MD5 |
98427c025be5569c6ee531b9acdaf28f
|
|
| BLAKE2b-256 |
9a0fb93e2eb608546285ac6adb4b6bd3be67471f1b787f77fae862dcfa6c46ea
|