R/Prob.R

Prob <-
function (t1, t2, pi, S1, S2, C1, C2) 
{
    p = pi * S1^(t1) * (1 - S1)^(1 - t1) * S2^(t2) * (1 - S2)^(1 - 
        t2)/(pi * S1^(t1) * (1 - S1)^(1 - t1) * S2^(t2) * (1 - 
        S2)^(1 - t2) + (1 - pi) * C1^(1 - t1) * (1 - C1)^(t1) * 
        C2^(1 - t2) * (1 - C2)^t2)
    return(p)
}

Try the HSROC package in your browser

Any scripts or data that you put into this service are public.

HSROC documentation built on Sept. 19, 2019, 9:05 a.m.