Fatskills
Practice. Master. Repeat.
Study Guide: Business Analytics 101: Data Management and Preparation Data Transformation Normalization Scaling Discretization Encoding Categorical Variables
Source: https://www.fatskills.com/business-analytics/chapter/business-analytics-busanalytics-data-management-and-preparation-data-transformation-normalization-scaling-discretization-encoding-categorical-variables

Business Analytics 101: Data Management and Preparation Data Transformation Normalization Scaling Discretization Encoding Categorical Variables

By Fatskills Exam Guides Team — the exam nerds behind 28,500+ quizzes and 2.1M practice questions across 500+ global exams.

⏱️ ~3 min read

What This Is

Data transformation is a crucial step in business analytics that involves converting raw data into a suitable format for analysis. This process helps to improve the accuracy and reliability of models by addressing issues such as missing values, outliers, and non-normal distributions. For instance, a retail company might use data transformation to normalize sales data, allowing them to better forecast demand and optimize inventory levels.

Key Formulas & Metrics

  • Mean Absolute Error (MAE) = (1/n) Σ|yᵢ − ŷᵢ|: average absolute forecast error, where yᵢ is the actual value and ŷᵢ is the predicted value.
  • R² = 1 − (SS_res / SS_tot): proportion of variance explained by the regression model, where SS_res is the sum of squared residuals and SS_tot is the total sum of squares.
  • Standard Deviation (σ) = √(Σ(xᵢ − μ)² / (n - 1)): measure of dispersion, where xᵢ is the individual data point, μ is the mean, and n is the sample size.
  • Coefficient of Variation (CV) = σ / μ: relative measure of dispersion, where σ is the standard deviation and μ is the mean.
  • Pearson Correlation Coefficient (ρ) = Σ[(xᵢ - μ_x)(yᵢ - μ_y)] / (√Σ(xᵢ - μ_x)² * √Σ(yᵢ - μ_y)²): measure of linear association between two variables, where xᵢ and yᵢ are individual data points, μ_x and μ_y are the means, and n is the sample size.
  • Information Gain (IG) = H(D) - H(D|A): measure of the reduction in entropy (uncertainty) due to a feature or attribute A, where H(D) is the entropy of the data and H(D|A) is the conditional entropy given A.
  • Entropy (H) = -Σ(pᵢ log₂ pᵢ): measure of uncertainty or randomness in a probability distribution, where pᵢ is the probability of each outcome.

Step-by-Step Procedure

  1. Identify the goal: Determine the purpose of data transformation (e.g., normalization, scaling, discretization, encoding categorical variables).
  2. Choose the method: Select the appropriate data transformation technique based on the goal and the characteristics of the data.
  3. Apply the method: Use software or tools to perform the data transformation (e.g., using pandas/scikit-learn in Python or Excel functions).
  4. Verify the results: Check the transformed data for errors or inconsistencies.
  5. Document the process: Record the steps taken and the results obtained.

Common Mistakes

  • Mistake: Confusing correlation with causation.
  • Correction: Correlation does not imply causation; a third variable may be responsible for the observed relationship.
  • Mistake: Misinterpreting p-values.
  • Correction: A small p-value indicates that the observed effect is statistically significant, but not necessarily practically significant.
  • Mistake: Using the wrong error metric for a business problem.
  • Correction: Choose an error metric that aligns with the business objective (e.g., mean absolute error for forecasting).

Software / Tool Tips

  • Python with pandas/scikit-learn: Use the StandardScaler class to scale data and the LabelEncoder class to encode categorical variables.
  • R: Use the scale() function to scale data and the factor() function to encode categorical variables.
  • Excel: Use the STDEV() function to calculate standard deviation and the IF() function to create a new column based on conditions.

Quick Practice Problem

Problem: Compute the moving average forecast for period 4 given data: 100, 110, 105, 120.

Answer: 110.5 (average of 105 and 120).

Explanation: The moving average forecast is calculated by taking the average of the previous two values.

Last-Minute Cram Sheet

  1. Normalization: scaling data to a common range (e.g., 0 to 1).
  2. Scaling: transforming data to have a specific distribution (e.g., standard normal distribution).
  3. Discretization: converting continuous data into discrete categories.
  4. Encoding categorical variables: converting categorical data into numerical values.
  5. MAE: average absolute forecast error.
  6. : proportion of variance explained by the regression model.
  7. σ: standard deviation.
  8. CV: coefficient of variation.
  9. ρ: Pearson correlation coefficient.
  10. IG: information gain.
  11. H: entropy.
  12. ⚠️ p-value is NOT the probability that H₀ is true – it’s the probability of observing the data (or more extreme) if H₀ is true.
  13. ⚠️ Correlation does not imply causation.
  14. ⚠️ Choose an error metric that aligns with the business objective.


ADVERTISEMENT