R/T_test_between_groups.R

Defines functions ttest_team

Documented in ttest_team

#' t-test for the salary between two two
#' @param df1 a NBA team
#' @param df2 another NBA team
#' @return T-test between two teams
#' @examples ttest_team(Spurs, Rockets), ttest_team(Rockets, Mavericks),ttest_team(Spurs, Mavericks)
#' @export

ttest_team<- function(df1,df2){
  t.test(df1$Total_Salary,df2$Total_Salary,alternative="two.sided", var.equal=TRUE,paired=T)
}
MingshuangLi/Mingshuang_finalproject_RProgtamming documentation built on May 24, 2019, 4:05 p.m.