profile.egf {epigrowthfit} | R Documentation |
Univariate Likelihood Profiles
Description
Computes univariate likelihood profiles of fixed effect coefficients, random effect covariance parameters, and linear combinations thereof, including population fitted values.
Usage
## S3 method for class 'egf'
profile(fitted, level = 0.95,
A = seq_along(par), grid = 12L,
parallel = egf_parallel(), trace = FALSE,
top = egf_top(fitted), subset = NULL, select = NULL, ...)
## S3 method for class 'profile.egf'
confint(object, parm = seq_along(object), level = attr(object, "level"),
class = FALSE, ...)
## S3 method for class 'profile.egf'
plot(x, parm = seq_along(x), level = attr(x, "level"),
type = c("z", "abs(z)", "z^2"), ...)
Arguments
fitted |
an |
level |
a number in the interval |
A |
a numeric matrix with |
grid |
a positive integer. Step sizes chosen adaptively by
|
parallel |
an |
trace |
a logical. If |
top |
a subset of |
subset , select |
index vectors for the rows and columns of
|
... |
additional arguments passed from or to other methods. |
object , x |
a |
parm |
a valid index vector for |
class |
a logical. If |
type |
a character string indicating which of |
Details
Computation of likelihood profiles is typically expensive, requiring
estimation of many restricted models.
It is parallelized at the C++ level when there is OpenMP
support and fitted[["control"]][["omp_num_threads"]]
is set
to an integer greater than 1. When there is no OpenMP support, it
can still be parallelized at the R level with appropriate setting
of argument parallel
.
Value
A list of length nrow(A)
inheriting from classes
profile.egf
and profile
. Each element is a data frame
specifying a profile, with two variables:
z |
a numeric vector containing profile |
par.vals |
a numeric matrix with one column containing values of the linear
combination specified by |
The confidence level level
is preserved as an attribute.
See Also
The generic function profile
.
The more basic “next” method for generic function
plot
, namely plot.profile
.
Examples
example("egf", package = "epigrowthfit")
zz <- profile(m1, A = NULL,
top = "log(r)", subset = quote(country == "A" & wave == 1))
str(zz)
confint(zz, class = TRUE)
pty <- c("z", "abs(z)", "z^2")
bty <- c("l", "u", "u")
for (i in 1:3)
plot(zz, type = pty[i], bty = bty[i], las = 1)