fitted.heckmanGE {heckmanGE}R Documentation

fitted.heckmanGE Extract Fitted Values of the Generalized Heckman Model

Description

This function extracts the fitted values from a heckmanGE object. You can specify which part of the model you want to retrieve the fitted values for: selection, outcome, dispersion, or correlation. By default, it returns the fitted values for the outcome part of the model.

Usage

## S3 method for class 'heckmanGE'
fitted(
  object,
  part = c("selection", "outcome", "dispersion", "correlation"),
  ...
)

Arguments

object

An object of class heckmanGE. This object should contain the fitted values for different parts of the model.

part

A character vector specifying which part of the model to return the fitted values for. Options are "selection", "outcome" (default), "dispersion", or "correlation". If multiple parts are provided, only the "outcome" part will be returned.

...

Additional arguments passed to or from other methods. These are not used in this method but must be included to match the generic method signature.

Details

If part is not one of the specified options, an error will be raised. If multiple parts are provided, the function defaults to returning the fitted values for the outcome part of the model.

Value

A vector of fitted values corresponding to the specified part of the heckmanGE model. The type of the returned values depends on the part specified.


[Package heckmanGE version 1.0.0 Index]