pi_compute | R Documentation |
Compute Probability of Each True Outcome, for Every Subject
pi_compute(beta, X, n, n_cat)
beta |
A numeric column matrix of regression parameters for the
|
X |
A numeric design matrix. |
n |
An integer value specifying the number of observations in the sample.
This value should be equal to the number of rows of the design matrix, |
n_cat |
The number of categorical values that the true outcome, |
pi_compute
returns a matrix of probabilities,
P(Y_i = j | X_i) = \frac{\exp(X_i \beta)}{1 + \exp(X_i \beta)}
for each of the i = 1, \dots,
n
subjects. Rows of the matrix
correspond to each subject. Columns of the matrix correspond to the true outcome
categories j = 1, \dots,
n_cat
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.