sfabz.Rd
Compute Bayes optimal spending function
sfabz(theta, psi, alpha = 0.05)
theta | value of theta being tested |
---|---|
psi | a list of parameters for the spending function, including
|
alpha | level of test |
a scalar value giving the optimal tail-area probability
This function computes the value of s that minimizes the acceptance probability of a biased level-alpha test for a normal population with known variance, under a specified prior predictive distribution.
Peter Hoff
thetas<-seq(-1,1,length=100) s<-NULL for(theta in thetas){ s<-c(s,sfabz(theta,list(mu=0,tau2=1,sigma2=1)) ) } plot(thetas,s,type="l")