Learn R Programming

ashr (version 0.9.2)

pcdf_post: pcdf_post

Description

``parallel" vector version of cdf_post where c is a vector, of same length as betahat and sebetahat

Usage

pcdf_post(m, c, betahat, sebetahat, v)

Arguments

m
mixture distribution with k components
c
a numeric vector with n elements
betahat
an n vector of observations
sebetahat
an n vector of standard errors
v
degree of freedom of error distribution (scalar)

Value

an n vector, whose ith element is the cdf for beta_i at c_i

Examples

Run this code
beta = rnorm(100,0,1)
betahat= beta+rnorm(100,0,1)
sebetahat=rep(1,100)
ash.beta = ash(betahat,1,mixcompdist="normal")
c = pcdf_post(ash.beta$fitted.g,beta,betahat,sebetahat,NULL)

Run the code above in your browser using DataLab