Q1. create a table showing the average salary of males and females, who were placed. Review whether there is a gender gap in the data. In other words, observe whether the average salaries of males is higher than the average salaries of females in this dataset.

mba <- read.csv(paste("Deans Dilemma.csv", sep=""))
aggregate(Salary~Gender, data = mba, FUN=mean)
##   Gender   Salary
## 1      F 193288.2
## 2      M 231484.8

yes, average salary of Males is higher than females in this dataset

Q2.R to run a t-test to test the following hypothesis:

H1: The average salary of the male MBAs is higher than the average salary of ##female MBAs.

boxplot(mba$Salary~mba$Gender, main = "Average salary of Males and Females in MBA", xlab = "Females/Males", ylab = "Average salary")

t.test(mba$Salary~mba$Gender, var.equal = TRUE)
## 
##  Two Sample t-test
## 
## data:  mba$Salary by mba$Gender
## t = -2.5757, df = 389, p-value = 0.01037
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
##  -67352.803  -9040.516
## sample estimates:
## mean in group F mean in group M 
##        193288.2        231484.8

What is the p-value based on the t-test?

P Vales = 0.01037 ## interpret the results 1. Males has high average salary of 231484.8 compared to the females average salary of 193288.2 2. T test results showed there significant difference between males an females salary. Submit your R code that creates a table showing the mean salary of males and females, who were placed.

Including Plots