R/powerfun_function.R

#' Generate Normal Power Function
#'
#' This function creates a power function under a normal distribution
#' @param n sample size
#' @param a alpha value
#' @keywords powerfun
#' @export
#' @examples
#' powerfun_function()

powerfun <- function(n,a){
  function(x) {
    pnorm(sqrt(n)*x- qnorm(1-a))}
}
tydarnell/linmod documentation built on May 7, 2019, 6:10 a.m.