교수가 가르쳐준 식쓰는데 시바 내컴에선 안돼...왜그럴까... 첫번째가 교수가한거 두번쨰가 내가한거야...뭘까.. 살려줘






t_test_rt <- function(alpha, mu0, xbar, s, n){

  se <- s/sqrt(n)

  t <-(xbar-mu0)/se

  cr <- qt(alpha, df=n-1)

  p_value <- pt(t, df=n-1, lower,tail=T)

  if(p_value < alpha) result<-"Reject H0"

  else result<-"Accept H0"

  print(paste("Hypothesis testing for H0: mu=", mu0, "or H1: mu < ", mu0))

  print(c(paste("t Statistics is ", round(t, 4), "and Critical Region is" $

  print(paste(result, "at significance level", alpha))

}


이거임 ㅠㅠ