Learn R Programming

Rdistance (version 4.0.5)

model.matrix.dfunc: model.matrix - Rdistance model matrix

Description

Extract the model matrix ("X" matrix) from an Rdistance model object.

Usage

# S3 method for dfunc
model.matrix(object, ...)

Value

A matrix containing covariates for fitting an Rdistance model.

Arguments

object

An Rdistance model frame or fitted distance function, normally produced by a call to dfuncEstim.

...

Ignored

Examples

Run this code

data(sparrowDf)
sparrowModel <- parseModel( sparrowDf, dist ~ observer )
model.matrix(sparrowModel)

Run the code above in your browser using DataLab