This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see http://rmarkdown.rstudio.com.
Note: this analysis was performed using the open source software R and Rstudio.
The objective of this tutorial is to explain how bivariate analysis works.This analysis can be used by marketers to make decisions about their pricing strategies, advertising strategies, and promotion stratgies among others.
Bivariate analysis is one of the simplest forms of statistical analysis. It is generally used to find out if there is a relationship between two sets of values (or two variables). That said, it usually involves the variables X and Y (statisticshowto.com).
segmentation <- read.csv('Game_Survey_Clean.csv')
plot(Purchase_freq ~ Age_group, data = segmentation, pch = 16)
abline(lm(Purchase_freq ~ Age_group, segmentation), col = "grey20")
# Simple linear regression (one predictor)
simple_model <- lm(Purchase_freq ~ Age_group, data = segmentation)
simple_model
##
## Call:
## lm(formula = Purchase_freq ~ Age_group, data = segmentation)
##
## Coefficients:
## (Intercept) Age_group
## 1.8889 -0.4444
summary(simple_model)
##
## Call:
## lm(formula = Purchase_freq ~ Age_group, data = segmentation)
##
## Residuals:
## Min 1Q Median 3Q Max
## -0.4444 -0.4444 -0.4444 0.2778 1.5556
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 1.8889 0.6656 2.838 0.0195 *
## Age_group -0.4444 0.5354 -0.830 0.4280
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 0.6849 on 9 degrees of freedom
## Multiple R-squared: 0.07111, Adjusted R-squared: -0.0321
## F-statistic: 0.689 on 1 and 9 DF, p-value: 0.428
# multivarite linear regression (three predictor)
multivarite_model <- lm(Purchase_freq ~ Age_group + Worth_price + Platform, data = segmentation)
multivarite_model
##
## Call:
## lm(formula = Purchase_freq ~ Age_group + Worth_price + Platform,
## data = segmentation)
##
## Coefficients:
## (Intercept) Age_group Worth_price Platform
## 2.800e+00 -6.000e-01 6.911e-16 -6.000e-01
summary(multivarite_model)
##
## Call:
## lm(formula = Purchase_freq ~ Age_group + Worth_price + Platform,
## data = segmentation)
##
## Residuals:
## 1 2 4 6 7 9 11
## 4.000e-01 1.400e+00 -6.000e-01 -6.000e-01 -6.000e-01 1.527e-16 -3.747e-16
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 2.800e+00 2.487e+00 1.126 0.342
## Age_group -6.000e-01 1.347e+00 -0.446 0.686
## Worth_price 6.911e-16 3.651e-01 0.000 1.000
## Platform -6.000e-01 1.189e+00 -0.505 0.649
##
## Residual standard error: 1.033 on 3 degrees of freedom
## (4 observations deleted due to missingness)
## Multiple R-squared: 0.1385, Adjusted R-squared: -0.7231
## F-statistic: 0.1607 on 3 and 3 DF, p-value: 0.9163
Bivariate Analysis Definition & Example https://www.statisticshowto.com/bivariate-analysis/#:~:text=Bivariate%20analysis%20means%20the%20analysis,the%20variables%20X%20and%20Y.
https://www.sciencedirect.com/topics/mathematics/bivariate-data