Math Operations Guide: All 12 Numeric Transformations
A complete guide to arithmetic, binning, log transform, power, round/ceil/floor, standardize, normalize, sign, Box-Cox/Yeo-Johnson, and cumulative operations.
Math Operations Guide: All 12 Numeric Transformations
This guide explains every math operation: what it does, when to use it, and how to run it step by step.
---
1. Arithmetic
Plain English: Performs basic math: add, subtract, multiply, or divide. Can combine two columns or use a column and a fixed number.
When to use: Calculate profit (Revenue − Cost), percentage (Part ÷ Total × 100), or adjust values (Price × 1.1 for 10% markup).
Step-by-step:
- Choose Arithmetic.
- Select the first column (or enter a constant).
- Choose operator (+, −, ×, ÷).
- Select the second column (or enter a constant).
- Name the new column and click Apply.
| Revenue | Cost | Profit (Revenue − Cost) |
|---|---|---|
| 100 | 60 | 40 |
| 200 | 120 | 80 |
| 150 | 90 | 60 |
2. Binning
Plain English: Groups numbers into ranges (bins). Each value is replaced by a bin label or midpoint (e.g., 0–10 → "Low", 11–50 → "Medium", 51–100 → "High").
When to use: Converting continuous values into categories for charts, reports, or modeling.
Step-by-step:
- Select the numeric column.
- Choose Binning.
- Choose method: equal width (each bin same size) or equal frequency (each bin same count).
- Enter number of bins or define custom breakpoints.
- Optionally name the bins.
- Click Apply.
| Age | AgeBin |
|---|---|
| 22 | 20-30 |
| 35 | 30-40 |
| 48 | 40-50 |
| 55 | 50-60 |
3. Log Transform
Plain English: Applies the logarithm (log10 or natural log) to each value. Shrinks large numbers and expands small ones.
When to use: Data is highly skewed (e.g., income, population). Log helps make the distribution more normal and stabilizes variance.
Step-by-step:
- Select the numeric column.
- Choose Log Transform.
- Select log base (10 or natural).
- Handle zeros: add 1 before log, or replace with missing.
- Click Apply.
| Original | Log10 |
|---|---|
| 1 | 0 |
| 10 | 1 |
| 100 | 2 |
| 1000 | 3 |
4. Square Root
Plain English: Takes the square root of each value. A milder way to reduce skew than log.
When to use: Data is positive and right-skewed; you want a gentler transformation than log.
Step-by-step:
- Select the column.
- Choose Square Root.
- Handle negative values if any (replace with missing or 0).
- Click Apply.
| Value | Sqrt |
|---|---|
| 4 | 2 |
| 9 | 3 |
| 16 | 4 |
| 25 | 5 |
5. Power
Plain English: Raises each value to a power (e.g., squared, cubed, or any exponent).
When to use: Creating squared terms for regression, or inverse transforms (e.g., power of 0.5 = square root).
Step-by-step:
- Select the column.
- Choose Power.
- Enter the exponent (2 for square, 3 for cube, 0.5 for square root).
- Click Apply.
| Value | Squared |
|---|---|
| 3 | 9 |
| 4 | 16 |
| 5 | 25 |
6. Absolute Value
Plain English: Converts negative numbers to positive. Leaves positive numbers unchanged.
When to use: You care about magnitude, not sign (e.g., error, distance from target).
Step-by-step:
- Select the column.
- Choose Absolute Value.
- Click Apply.
| Original | Absolute |
|---|---|
| −5 | 5 |
| 3 | 3 |
| −10 | 10 |
7. Round / Ceil / Floor
Plain English:
- Round: Rounds to nearest integer (or specified decimals).
- Ceil: Rounds up to next integer.
- Floor: Rounds down to previous integer.
Step-by-step:
- Select the column.
- Choose Round, Ceil, or Floor.
- For Round, enter number of decimal places (0 = integer).
- Click Apply.
| Value | Round | Ceil | Floor |
|---|---|---|---|
| 3.2 | 3 | 4 | 3 |
| 3.7 | 4 | 4 | 3 |
| −1.3 | −1 | −1 | −2 |
8. Standardize (Z-Score)
Plain English: Transforms values so the mean is 0 and standard deviation is 1. Formula: (value − mean) / std.
When to use: Comparing variables on different scales, or preparing data for many ML algorithms.
Step-by-step:
- Select the column(s).
- Choose Standardize or Z-Score.
- Click Apply.
- Mean = 50, Std = 10
- 30 → −2 (2 std below mean)
- 50 → 0 (at mean)
- 70 → 2 (2 std above mean)
9. Normalize (0–1)
Plain English: Scales values to a 0–1 range. Formula: (value − min) / (max − min).
When to use: When you need values between 0 and 1 for neural networks, similarity scores, or percentages.
Step-by-step:
- Select the column(s).
- Choose Normalize or Min-Max Scale.
- Optionally set custom min and max.
- Click Apply.
- Min = 0, Max = 100
- 25 → 0.25
- 50 → 0.5
- 100 → 1.0
10. Sign
Plain English: Returns +1 for positive numbers, −1 for negative, and 0 for zero.
When to use: Creating a direction indicator (up/down) or simplifying change analysis.
Step-by-step:
- Select the column.
- Choose Sign.
- Click Apply.
| Value | Sign |
|---|---|
| 5 | 1 |
| −3 | −1 |
| 0 | 0 |
11. Data Transform (Box-Cox / Yeo-Johnson)
Plain English: Advanced transforms that can make skewed data more normally distributed. Box-Cox for positive values; Yeo-Johnson for any values including zero and negatives.
When to use: Strong skew that log or square root does not fix; preparing for methods that assume normality.
Step-by-step:
- Select the column.
- Choose Box-Cox or Yeo-Johnson.
- Let the tool auto-select lambda, or specify it.
- Click Apply.
---
12. Cumulative Operations
Plain English: Computes running totals or running statistics (cumulative sum, cumulative product, cumulative max, cumulative min).
When to use: Running totals (sales YTD), cumulative growth, or tracking max/min over time.
Step-by-step:
- Select the column.
- Choose Cumulative Sum, Cumulative Product, Cumulative Max, or Cumulative Min.
- Optionally sort by another column first (e.g., date).
- Click Apply.
| Month | Sales | CumulativeSum |
|---|---|---|
| Jan | 100 | 100 |
| Feb | 150 | 250 |
| Mar | 120 | 370 |
| Apr | 180 | 550 |
Quick Reference
| Operation | Purpose |
|---|---|
| Arithmetic | +, −, ×, ÷ |
| Binning | Group into ranges |
| Log Transform | Reduce skew |
| Square Root | Mild reduce skew |
| Power | Square, cube, etc. |
| Absolute Value | Remove sign |
| Round/Ceil/Floor | Round numbers |
| Standardize | Mean 0, std 1 |
| Normalize | Scale to 0–1 |
| Sign | +1, 0, −1 |
| Box-Cox/Yeo-Johnson | Advanced normalization |
| Cumulative | Running sum, max, min |
What's Next?
- [Data Operations Guide](data-operations-guide) – Filter, encode, group
- [String Operations Guide](string-operations-guide) – Text transforms
- [Formula Builder Guide](formula-builder-guide) – Custom calculations
Related Articles
Data Operations Guide: All 15 Transformations Explained
A complete guide to all 15 data operations: label encode, one-hot encode, filter, transpose, rename, date conversion, concatenate, cross tab, rename factor, impute, grouping, drop duplicates, ignore column, delete missing, and data table view.
String Operations Guide: All 20 Text Transformations
A complete guide to substring, replace, trim, pad, case changes, split, concatenate, length, contains, extract pattern, and 10 more string operations.
Formula Builder: Calculated Columns and Expressions
Build powerful calculated columns using column references, pipe chaining, and 70+ functions across String, Math, Date, Aggregation, Finance, and Geo categories.
Was this helpful?