Select CSV, XLS, XLSX, or XLAM data. DataForge inspects the columns and makes them available to later controls.
DataForge Documentation
DataForge is a personal project created to practice and demonstrate a complete data-analysis workflow in one interface: preparing messy datasets, exploring them, producing visual evidence, applying statistical tests, and experimenting with machine-learning models. This page documents what each control means, what happens mathematically, and what kind of values a user should select in the application.
How the application is intended to be used
Browse every row page-by-page and use Quick Summary to understand types, missing values, duplicates, spread, and central tendency.
Handle missing values, remove duplicates, control outliers, or normalize numeric features. Each transformation becomes the current working dataset.
Select a chart. Only parameters required by that chart appear, which reduces invalid combinations and visual clutter.
Use statistical tests when the question is about evidence, differences, association, or group means.
Use supervised models for prediction or unsupervised models for grouping. Choose model-specific parameters only when they are relevant.
Viewing the complete dataset without freezing the browser
The dataset table is a paged browser rather than one giant HTML table. A user can move from the first row to the final row, while the browser renders only a controlled number of records at once. This keeps memory usage and DOM work bounded even when the dataset is large. The Rows per page selector supports 50, 100, 250, or 500 records.
The Export CSV and Export XLSX actions export the current working version of the dataset, including transformations already applied.
Dataset profiling metrics
Mean
x̄ = Σxᵢ / nThe arithmetic average of a numeric column. Useful for typical values when extreme values are not dominating the data.
App example: salary → Mean.Median
middle value after sortingThe 50th percentile. More robust than the mean when the distribution contains large outliers.
Example: house_price with a few luxury properties.Mode
most frequent valueThe most common value. Works naturally for categories and can also be used with numeric values.
Example: district → most common district.Variance
s² = Σ(xᵢ − x̄)² / (n − 1)Measures squared spread around the sample mean. Large values mean observations are more dispersed.
Example: compare variability of monthly_sales.Standard Deviation
s = √s²Square root of variance, expressed in the original unit of the variable.
Example: age SD = 8.2 years.Missing Values
count(is null)Counts empty/NaN values per column so the user can decide whether to fill or remove them.
Example: income has 143 missing rows.Duplicates
repeated row countCounts repeated records. Duplicates can bias totals, frequencies, model training, and reports.
Example: repeated transaction records.Data Types
numeric • text • date-likeShows how Pandas interpreted each column. Type matters because many statistical and ML techniques require numeric values.
Example: age should normally be numeric.Cleaning and transformation controls
Handle Missing Values
Select one column, then choose a strategy. DataForge shows strategies that make sense for that column type.
Example: column = latitude, strategy = Remove Null ValuesExample: age → 31.7Example: income → median incomeExample: gender → most frequent categoryExample: priority score where boundary values are intentionalRemove Duplicates
With no column selected, entire rows must match to be considered duplicates. If a column is selected, only that column is used as the duplicate key.
Ref number when it is supposed to uniquely identify one record. Duplicate Ref numbers will be reduced to the first occurrence.Handle Outliers — IQR Clipping
Q1 = 25th percentile • Q3 = 75th percentile • IQR = Q3 − Q1
Lower = Q1 − 1.5×IQR • Upper = Q3 + 1.5×IQR
Values outside the lower/upper boundary are clipped to the nearest boundary rather than deleting the complete row. This limits extreme influence while preserving record count.
monthly_income. If Upper = 250,000, a value of 900,000 is replaced with 250,000.Normalization
Min-Max
x′ = (x − min) / (max − min)Maps numeric features approximately to 0–1. Useful for distance-based algorithms such as KNN and K-Means.
Example: age 18–80 becomes a 0–1 scale.Z-Score
z = (x − x̄) / sCenters around 0 and scales by standard deviation. Useful when features have very different units.
Example: salary and age before SVM/KNN.Max Absolute
x′ = x / max(|x|)Scales by maximum absolute value while preserving sign and zero.
Example: features containing both negative and positive values.Charts, parameters, and when to use them
Histogram
Shows the distribution of one variable by dividing its range into bins.
Use: age distribution • X=age • Bins=20 • KDE=OnKDE overlays a smoothed density estimate. Stat controls count/frequency/probability/percent/density. Multiple controls how Hue groups layer, dodge, stack, or fill.
Box Plot
Summarizes median, quartiles, spread, and possible outliers.
Use: salary by department • X=department • Y=salaryShow Outliers toggles individual fliers. Hue adds another categorical grouping.
Scatter Plot
Examines the relationship between two numeric variables.
Use: X=age • Y=income • Hue=gender • Alpha=0.6Hue maps color, Size maps marker size, Style maps marker shape, and Alpha controls transparency.
Heatmap
Displays correlations among numeric columns.
r = cov(X,Y) / (sₓsᵧ)Correlation ranges from −1 to +1. Show Values prints coefficients when the matrix is not excessively large. Color Map changes the visual palette.
Pair Plot
Creates pairwise scatter plots plus univariate distributions for several numeric columns.
Use: age + income + household_size + scoreSelect 2–8 numeric columns. Hue can separate classes. Corner Layout removes mirrored duplicates to reduce visual load.
Bar Chart
Compares the mean of a numeric Y variable across X categories.
Use: X=district • Y=income • Hue=genderDataForge pre-aggregates the mean before plotting for faster rendering.
Count Plot
Counts how many records occur in each category.
Use: X=district • Hue=genderBest for frequency comparisons rather than numeric magnitudes.
Line Chart
Shows progression or trend across an ordered X dimension.
Use: X=month • Y=sales • Hue=region • Marker=CircleDataForge aggregates repeated X/Hue combinations by mean before plotting.
Violin Plot
Combines a distribution-density shape with summary information.
Use: X=department • Y=salary • Hue=genderInner Display can show quartiles, a mini box, points, sticks, or nothing. Split Violins require exactly two Hue groups.
Pie Chart
Shows category shares of a whole.
Use: Category=genderBest with a small number of categories. For high-cardinality columns DataForge groups smaller categories into Other.
Statistical tests
Independent T-Test
t = (x̄₁ − x̄₂) / [sₚ √(1/n₁ + 1/n₂)]
Tests whether the means of two numeric samples differ more than expected from sampling variation. The output includes the t-statistic and p-value.
income_group_A, Sample B = income_group_B. A small p-value (commonly < 0.05) is evidence against equal means, assuming the test assumptions are appropriate.Z-Test
One sample: z = (x̄ − μ₀) / SE
Two sample: z = (x̄₁ − x̄₂) / SE
One-Sample: compare one sample mean with a hypothesized value. Two-Sample: compare two sample means.
delivery_days, Hypothesized Mean = 5.Chi-Square Test of Independence
χ² = Σ (O − E)² / E
Checks whether two categorical variables are associated. O is an observed frequency and E is the frequency expected under independence.
gender, Second Category = product_choice.One-Way ANOVA
F = MSbetween / MSwithin
Compares three numeric samples in DataForge and tests whether at least one group mean differs from the others.
score_group_A, Sample B = score_group_B, Sample C = score_group_C.Models and parameters
Linear Regression
ŷ = β₀ + β₁x₁ + β₂x₂ + … + βₚxₚ
Predicts a continuous numeric target. Coefficients describe the fitted linear contribution of each feature.
MSE: Σ(y−ŷ)²/n — lower is better. R²: 1 − SSres/SStot — closer to 1 indicates more explained variation.
house_price; encode categorical predictors such as district; Test Data = 20%.Logistic Regression
p = 1 / (1 + e^(−z))
Classification model that converts a linear score into a probability-like value and learns class boundaries.
churn containing classes such as Yes/No; encode text predictors; Test Data = 20%.Random Forest
An ensemble of decision trees. Each tree learns from randomized data/features and the forest combines their outputs, reducing dependence on one unstable tree.
Gini = 1 − Σpᵢ²Entropy = −Σpᵢ log₂(pᵢ)Learning Type: Classification or Regression. Number of Trees: more trees usually improve stability but cost more CPU/time. Criterion: controls how splits are evaluated.
approved, Trees = 200, Criterion = Gini. Regression example: Target = sales, Trees = 200, Criterion = Squared Error.K-Nearest Neighbor (KNN)
d(x,y) = √Σ(xᵢ − yᵢ)²
Finds the K closest training samples. Classification uses neighbor voting; regression averages nearby target values.
Neighbors (K): small K reacts strongly to local data; larger K smooths decisions. Feature scaling is highly recommended because distance is scale-sensitive.
risk_class; Learning Type = Classification; K = 7; Test Data = 20%.Support Vector Machine (SVM)
decision boundary: w·x + b = 0
SVM seeks a separating boundary with a large margin. Kernel functions allow nonlinear relationships.
fraud, Learning Type = Classification, Kernel = RBF, C = 1, Gamma = Scale, Test Data = 20%.K-Means Clustering
minimize Σ ||xᵢ − μc(i)||²
Unsupervised algorithm that assigns observations to K clusters around learned centroids. Inertia is the within-cluster squared-distance objective; lower values mean tighter clusters for the same K.
Lloyd: standard general algorithm. Elkan: can be faster on some Euclidean datasets by using triangle-inequality bounds.
Hierarchical Clustering
Agglomerative clustering starts with individual observations and repeatedly merges the closest groups until the requested cluster count remains.
Preparing predictors for machine learning
Label Encoder
Red→0, Blue→1, Green→2Maps categories to integer labels. Compact and useful when an algorithm can tolerate the numeric representation, but the numbers do not automatically mean true ordinal distance.
One-Hot Encoder
color_Red • color_Blue • color_GreenCreates binary indicator columns and avoids artificial category ordering. High-cardinality selections are guarded because thousands of generated columns can exhaust memory.
Test Data (%)
train = 100% − test%Reserves unseen records for evaluation. A common starting point is 20%, although suitable ratios depend on dataset size and task.
What happens when inputs are not valid
DataForge is designed to reject invalid operations with a clear message instead of allowing the user interface to collapse. Important cases include:
- Unsupported or empty uploads are rejected before analysis.
- Oversized uploads are stopped by a safety limit before consuming excessive memory.
- Required parameters remain disabled or are validated before requests are sent.
- Numeric-only techniques reject text columns with an explanation.
- Missing values are detected before machine-learning training.
- One-hot encoding blocks extremely high-cardinality selections that could cause a memory explosion.
- Pair plots cap the number of selected variables and sample very large datasets for responsive rendering.
- Bar/count visualizations reject combinations that would create hundreds of unreadable bars.
- Split violin plots require exactly two Hue groups.
- Ward hierarchical linkage automatically requires Euclidean distance.
- Cluster count cannot exceed the number of available observations.
- Long-running browser requests time out safely and explain what the user can change.
- Unexpected server errors are caught, logged with a reference ID, and returned as a controlled error response.
Example sequences to try in the app
- Upload survey.xlsx.
- Quick Summary → inspect missing values.
- Handle Missing → income → Median.
- Handle Missing → district → Mode.
- Remove Duplicates → Ref number.
- Export XLSX.
- Histogram → age → 20 bins.
- Count Plot → district → Hue gender.
- Bar Chart → district → household_income.
- Heatmap → inspect numeric correlations.
- Handle all missing values.
- Normalize numeric columns if using KNN/SVM.
- Select Logistic Regression or SVM.
- Target = approved.
- Encode text predictors.
- Test Data = 20%.
- Run Analysis and inspect Accuracy.
- Choose useful numeric behavior columns.
- Normalize with Z-Score.
- K-Means → Clusters = 4 → Lloyd.
- Inspect labels, centers, and inertia.
- Try another K and compare domain usefulness.