Product Sales Casual Analysis

Descriptive & Casual Analysis / Leap Model & Mars Model
Project Goal
In the product sales analysis, I conducted to casual analysis to explain sales units. In order to better interpret sales, I build up linear and non-linear models to explain the effect of each variable on sales.
Data
The dataset tracks over 46,000 transactions for seven years, recording week number, store number, product number, units, total revenue, whether the product is featured, and whether the product is displayed.
Step one :
Exploratory Data Analysis
I discovered the data using the summary function and boxplot to have a brief understanding of the variables.
Next, I plot the numeric variables to observe the distribution of the data.
The correlation check is critical for casual relationships., since we need to find the correlation between sales and price.
Model selection : chose the log-level model base on the scatter plot.
Step two :
Linear Regression
I first shape a simple regression and add in categorical variables.
I analyze the interaction effects on the model.
Step three :
Leaps model
The leaps model detects significant variables and avoid omitted variable bias.
Step four :
Mars Model
The mars model suggests intuition on non-linear relationships.