nCovars | R Documentation |
Return number of covariates in a distance model
nCovars(X)
X |
The X matrix of covariates, or a vector. |
The reason this routine is needed is that sometimes we pass one row of covariates to a likelihood function. If so, it may come in as a normal vector, not a matrix. If a normal vector, ncol(X) does not work.
An integer scalar
# do not export
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.