power_disc: find power of gof tests for discrete data

View source: R/RcppExports.R

power_discR Documentation

find power of gof tests for discrete data

Description

find power of gof tests for discrete data

Usage

power_disc(
  pnull,
  rnull,
  vals,
  ralt,
  param_alt,
  phat,
  TS,
  typeTS,
  TSextra,
  rate = 0,
  B = as.integer(c(1000, 1000)),
  alpha = 0.05
)

Arguments

pnull

R function (cdf)

rnull

R function (generate data under null hypothesis)

vals

vector of values of discrete random variable

ralt

R function to generate data under alternative

param_alt

parameters of function ralt

phat

function to estimate parameters from the data

TS

function to calculate test statistics

typeTS

type of test statistic

TSextra

list passed to TS, if desired

rate

=0, rate of sample size, if random

B

=c(1000, 1000) Number of simulation runs for power and null distribution

alpha

=0.05, type I error of test

Value

A matrix of powers


Rgof documentation built on Oct. 9, 2024, 1:06 a.m.