Methods for extracting or sorting parameter estimates
# S3 method for estimate
subset(x, keep, ...)# S3 method for estimate
rev(x)
# S3 method for estimate
tail(x, n = 1, ...)
# S3 method for estimate
head(x, n = 1, ...)
# S3 method for estimate
sort(x, decreasing = FALSE, by = c("labels", "values"), ...)
# S3 method for estimate
[(x, i, ...)
# S3 method for estimate
with(data, expr, ...)
estimate object
subset (integer or character vector) of elements to extract
arguments passed to utils::tail, utils::head, base::sort, base::subset
an integer vector of length up to dim(x) (or 1,
for non-dimensioned objects). A logical is silently coerced to
integer. Values specify the indices to be
selected in the corresponding dimension (or along the length) of the
object. A positive value of n[i] includes the first/last
n[i] indices in that dimension, while a negative value
excludes the last/first abs(n[i]), including all remaining
indices. NA or non-specified values (when length(n) <
length(dim(x))) select all indices in that dimension. Must
contain at least one non-missing value.
logical. Should the sort be increasing or decreasing? Not available for partial sorting.
sorted by "values" or "labels" of parameters
data to use for constructing an environment. For the
default with method this may be an environment, a list, a
data frame, or an integer as in sys.call. For within,
it can be a list or a data frame.
expression to evaluate; particularly for within()
often a “compound” expression, i.e., of the form
{
a <- somefun()
b <- otherfun()
.....
rm(unused1, temp)
}
e <- estimate(coef=4:1, IC=matrix(0,nrow=2,ncol=4), labels=letters[1:4])
subset(e, c(1,4))
sort(e, by="values")
head(e, 2)
rev(e)
Run the code above in your browser using DataLab