Learn R Programming

DirichletReg (version 0.5-1)

DirichletRegModel: Methods for the class DirichletRegModel

Description

These are available methods for the results of Dirichlet regression models and objects of class DirichletRegModel. These methods contain functions for print and summary of the data, generate fitted values and predicting new values using predict. Various types of residuals are implemented and confint can be used to compute confidence intervals of the parameters. Furthermore logLik extracts the log-likelihood of the model and vcov extracts the covariance matrix of the parameter estimates.

Usage

## S3 method for class 'DirichletRegModel':
print(x, digits = max(3, getOption("digits") - 3), \dots)

## S3 method for class 'DirichletRegModel':
summary(object, \dots)

## S3 method for class 'DirichletRegModel':
fitted(object, mu = TRUE, alpha = FALSE, phi = FALSE, \dots)

## S3 method for class 'DirichletRegModel':
predict(object, newdata, mu = TRUE, alpha = FALSE, phi = FALSE, \dots)

## S3 method for class 'DirichletRegModel':
residuals(object, type = c("standardized", "composite", "raw"), \dots)

## S3 method for class 'DirichletRegModel':
confint(object, parm, level, \dots, type=c("all", "beta", "gamma"), exp = FALSE)

## S3 method for class 'DirichletRegConfint':
print(x, digits = 3, \dots)

## S3 method for class 'DirichletRegModel':
logLik(object, \dots)

## S3 method for class 'DirichletRegModel':
AIC(object, \dots, k = 2)

## S3 method for class 'DirichletRegModel':
BIC(object, \dots)

## S3 method for class 'DirichletRegModel':
nobs(object, \dots)

## S3 method for class 'DirichletRegModel':
vcov(object, \dots)

## S3 method for class 'DirichletRegModel':
update(object, formula., \dots, evaluate = TRUE)

Arguments

x
an object of class DirichletRegModel
object
an object of class DirichletRegModel or DirichletRegConfint for printing an object obtained by confint.DirichletRegModel
alpha
logical; returns alpha values
mu
logical; returns expected values
phi
logical; returns precision values
type
for residuals: defines the type of residuals to be computed "standardized" (i.e., Pearson), "composite", or "raw" for confint: defines the type of parameter ("all"
newdata
a data.frame containing new observations
k
number for the weighting of parameters
parm
a vector containing names of the parameters to print
level
(a vector of) confidence level(s), defaults to .95
exp
logical; returns parameters in exponentiated form
digits
the number of digits in the output
formula.
the new formula to be updated, see update.Formula
evaluate
if FALSE the updated call will be returned, but not evaluated
...
further arguments

encoding

UTF-8

Examples

Run this code
ALake <- ArcticLake
  ALake$AL <- DR_data(ArcticLake[, 1:3])
  mod1 <- DirichReg(AL ~ depth + I(depth^2) | depth, data = ALake, model="alternative")
  update(mod1, . ~ . | . + I(depth^2), evaluate = FALSE)
  mod1
  summary(mod1)
  head(fitted(mod1))
  head(predict(mod1))
  head(residuals(mod1))
  confint(mod1)
  logLik(mod1)
  vcov(mod1)

Run the code above in your browser using DataLab