fits.compare: Comparison of fits

View source: R/fits.compare.R

fits.compareR Documentation

Comparison of fits

Description

The fits.compare function accepts a sequence of objects of class "glm", "cubinf", or "aov" (with optional names), and creates a class "fits.compare" object. The print.fits.compare function prints summaries of each of the input objects in a manner suitable for comparing the input models.

Usage

## S3 method for class 'fits.compare'
print(x, digits = max(3, .Options$digits - 3), ...)

fits.compare(...)

Arguments

x

An object inheriting from class "fits.compare", the result of a call to fits.compare.

digits

Minimal number of significant digits.

...

In fits.compare(), ... is a sequence of objects of class "lm", "lm.robust", or "aov". Otherwise ... represents further arguments passed to or from print method.

Details

It is not recommended to compare objects with different structures.

See Also

The model fitting function glm, cubinf

Examples

 library(robcbi)
 data(Finney)
 Vol <- Finney$Vol; Rate <- Finney$Rate; Resp <- Finney$Resp
 lVol <-log(Vol); lRate <- log(Rate)
 z.glm <- glm(Resp~lVol+lRate,family=binomial)
 z.cub <- glm(Resp~lVol+lRate,family=binomial,method="cubinf", ufact=3.2)
 comp <- fits.compare(z.glm,z.cub)
 comp

robcbi documentation built on Aug. 22, 2023, 1:06 a.m.