\HeaderA{eapply}{Apply a Function over values in an environment}{eapply}
\keyword{iteration}{eapply}
\keyword{environment}{eapply}
\keyword{list}{eapply}
\begin{Description}\relax
\code{eapply} applies \code{FUN} to the named values from an
environment and returns the results as a list.  The user can request
that all named objects are used (normally names that begin with a
dot are not). The output is not sorted and no parent environments are
searched.
\end{Description}
\begin{Usage}
\begin{verbatim}
eapply(env, FUN, ..., all.names = FALSE)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{env}] environment to be used.
\item[\code{FUN}] the function to be applied, found \emph{via}
\code{\LinkA{match.fun}{match.fun}}.
In the case of functions like \code{+},
\code{\%*\%}, etc., the function name must be backquoted or quoted.
\item[\code{...}] optional arguments to \code{FUN}.
\item[\code{all.names}] a logical indicating whether to apply the function to
all values
\end{ldescription}
\end{Arguments}
\begin{SeeAlso}\relax
\code{\LinkA{lapply}{lapply}}.
\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
require(utils); require(stats)

env <- new.env()
env$a <- 1:10
env$beta <- exp(-3:3)
env$logic <- c(TRUE,FALSE,FALSE,TRUE)
# what have we there?
eapply(env, str)

# compute the mean for each list element
eapply(env, mean)
# median and quartiles for each list element
eapply(env, quantile, probs = 1:3/4)
eapply(env, quantile)
\end{ExampleCode}
\end{Examples}

