data(X)
data(beta)
CalculPx(X=X, beta=beta)
##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
## The function is currently defined as
function (X, beta, intercept = 0)
{
prob <- 1/(1 + exp(-(X %*% beta + intercept)))
return(prob)
}
Run the code above in your browser using DataLab