Last data update: 2014.03.03

R: Check the compatibility of a design with a given covariance...
checkX-methodsR Documentation

Check the compatibility of a design with a given covariance object

Description

Check the compatibility of a design matrix with a covariance object.

Usage


   ## S4 method for signature 'covAll'
checkX(object, X, strict = FALSE)

Arguments

object

A covariance kernel object.

X

A design matrix.

strict

Logical. If TRUE, the character vectors colnames(X) and inputNames(object) must be the same sets, and hence have the same length. If FALSE the vector inputNames(object) must be a subset of colnames(X) which then can have unused columns.

...

Not used yet.

Details

The matrix X must have the number of columns expected from the covariance kernel object description, and it must have named columns conforming to the kernel inputnames as returned by the inputNames method. If the two sets of names are identical but the names are in a different order, the columns are permuted in order to be in the same order as the inputnames. If the names sets differ, an error occurs.

Value

A matrix with columns names identical to the inputnames attached with the kernel object, i.e. inputNames(object). The columns are copies of those found under the same names in X, but are put in the order of inputNames(object). When an input name does not exist in colnames(X) an error occurs.

See Also

The inputNames method.

Results