| linearities_cl | R Documentation |
This function calculates the linearities in the negative structure vector matrix X* for a cumulative link model, so the row vectors for which there is no separation. If this is an empty set or of length 0, then we have overlap.
linearities_cl(y, X, rational = FALSE)
y |
the outcome variable. Can be factor, ordered, numeric, character or boolean. Works best if it is a factor or ordered factor. If it is not an (ordered) factor, we treat the outcome as nominal. |
X |
a design matrix, e.g. generated via a call to 'model.matrix'. This means we expect that X already contains the desired contrasts for factors (e.g., dummies) and any other expanded columns (e.g., for polynomials). |
rational |
boolean flag whether rational arithmetic should be used. Default is FALSE. |
a list with elements $lins which lists the rows vectors that are linearities for any category and $index which gives the row index of the linearities. If there is complete separation they are both empty set. If their length/row dimension is number of categories*dim(X)[1], there is overlap. Anything in between is quasi-complete separation.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.