Given Data

a<-c(65,81,57,66,82,82,67,59,75,70,64,71,83,59,65,56,69,74,82,79)
type<-c("1","1","1","1","1","1","1","1","1","1","2","2","2","2","2","2","2","2","2","2")
q<-as.factor(type)
dat<-data.frame(a,type)

Boxplot to compare variances

from the above boxplot we can see that the variances are equal, Hence we need to run the levene’s test # Running Levene’s Test

library(lawstat)
levene.test(dat$a,dat$type,location=c("mean"))
## 
##  Classical Levene's test based on the absolute deviations from the mean
##  ( none not applied because the location is not set to median )
## 
## data:  dat$a
## Test Statistic = 0.0014598, p-value = 0.9699

The value of P=0.9699 which is greater than 0.05 hence we failed to reject the null hypothesis # Running T.test

type1<-c(65,81,57,66,82,82,67,59,75,70)
type2<-c(64,71,83,59,65,56,69,74,82,79)
t.test(type1,type2,var.equal=TRUE)
## 
##  Two Sample t-test
## 
## data:  type1 and type2
## t = 0.048008, df = 18, p-value = 0.9622
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
##  -8.552441  8.952441
## sample estimates:
## mean of x mean of y 
##      70.4      70.2

The value of P=0.9622 which is greater than 0.05 hence we failed to reject the null hypothesis