mspath-class {mspath} | R Documentation |
These classes hold the results of likelihood estimation
from a call to mspath
, either with (mspathFull
) or
without (mspath
) modeling observational measurement error.
Result of calls to mspath
.
transCoef
:"mspathCoefficients"
.errCoef
:mspathFull
has this slot, which
gives the estimated observation error coefficients. Slot class
mspathCoefficients
.calc
:"mspathCalculator"
used to produce
this object. overlap
:"numeric"
.call
:mspath
that created
this object. Slot has class "call"
. callArgs
:"list"
with the resolved
values specified by the user in the call. Each argument captured
by ... will be present, but omitted arguments will be absent,
even if they have defaults.
To understand the difference between this slot and the previous
one, suppose one invokes mspath(qmatrix=b4, ...)
, and
then later redefines b4
. Then call
will have
qmatrix=b4
but callArgs$qmatrix
will have the value
of b4
at the time of the call.
opt
:optim
that is used for the likelihood maximization.
Slot class "list"
.mspathCoefficients
object.coeff
argument is a vector of strings, each
being the name of a coefficient of interest; otherwise all are
reported.signature(x="mspath", na.rm="ANY")
: Estimated
standard deviation of coefficients, or 0 if they are fixed.
na.rm
is required for compatibility with the general
interface for this function, but probably won't work properly.signature(x = "mspath")
: -2 time the
estimated log-likelihood. signature(x = "mspath")
: Number of invalid nodes generated. signature(x = "mspath")
: Number of cases, i.e.,
unique id's, in the input data. The number of individual
observations will generally be greater than this.signature(x = "mspath")
: Number of unique
good nodes on these paths. Note that nodes may be shared between
paths, and some "good" nodes turn out not to be on any good paths.
Expected likelihood computation time is roughly proportional to this number. signature(x = "mspath")
: Total number
of nodes in all the good paths. goodPathNodes/goodPaths is the
average path length. goodNodes/goodPathNodes estimates the
speedup from sharing nodes between paths vs a naive implementation
that treats each path independently. signature(x = "mspath")
: Number of complete
good paths on which to compute a likelihood. signature(x = "mspath")
: The results of the
inner call to optim
. signature(x = "mspath")
: For internal use
only. signature(x="mspath")
: print results. If there
is an error model, the default behavior is only to show the
transition or error coefficients if they were not completely fixed
in advance; use the optional showAll=TRUE
argument to show
the fixed coefficients as well. Other arguments, including
general printing parameters and coeff
are passed to the
coefficient printing routines.signature(x = "mspath")
: For internal use only. The counts are counts over all cases, so the number good paths, for example, is the sum of all the good paths for each case. Currently the counts are not reliable for distributed calculations.
This class currently exists mostly to print out the estimated coefficients. It records other information to preserve the context of the computation, but doesn't currently do much with it. As need arises, the class will be enhanced.
In particular, the class only provides the raw coefficients and their mapping to cells in the matrices. It does not multiply by covariates, calculate implied transition or error probabilities, or otherwise work out the implications of the model.
The related msm package does work out many of the implications of the estimated coefficients (in fact, it does not present the raw coefficients at all in its standard print method). Almost none of the operations there (markov, continuous time models) translate directly into the context of this model (non-markov, discrete time). Also, msm uses S3 classes, while this package uses S4. The only user implication is that the S4 help system is available.
In principle this class could hold sets of coefficients that did not come from maximization; in particular, the coefficients do not have to be estimated ones. Neither the class nor its methods are designed for that use, however.
Ross Boylan ross@biostat.ucsf.edu
mspath
creates these objects. The key values are
in mspathCoefficients
, which will usually be the
mspathEstimatedCoefficients
subclass. See
optim
for details of its results object, which is
preserved here. mspathCalculator
describes the
calculator.