R/pvalue_control.R

#Function for controlling if the p-value is < alpha.
#If p<alpha, null hyp is rejected and is returned TRUE.
pvalue_control <- function(x, alpha){
  ogg<-summary(x)
  coeff<-coef(ogg)
  if(coeff[2,4]>=alpha) pbool <- FALSE
  else pbool <- TRUE
  return(pbool)
}
theugen/moving_window documentation built on May 31, 2019, 9:51 a.m.