% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/density_wrappers.R
\name{aedl_tau2_density}
\alias{aedl_tau2_density}
\title{Approximate density of the untruncated DL tau-squared estimator}
\usage{
aedl_tau2_density(vi, tau2, nsim_chi = 1e+05, n_tau = 1000)
}
\arguments{
\item{vi}{Numeric vector of known within-study variances.}

\item{tau2}{Non-negative value of the between-study variance.}

\item{nsim_chi}{Number of Monte Carlo samples for the chi-square mixture.}

\item{n_tau}{Number of grid intervals for the untruncated DL estimator.}
}
\value{
A list with grid values \code{x}, density values \code{y}, and auxiliary
quantities used in the approximation.
}
\description{
\code{aedl_tau2_density()} evaluates the chi-square-mixture approximation used
internally for the untruncated DerSimonian-Laird estimator of the
between-study variance.
}
\examples{
vi <- c(0.04, 0.05, 0.03, 0.06)
d_tau <- aedl_tau2_density(
  vi = vi,
  tau2 = 0.01,
  nsim_chi = 500,
  n_tau = 50
)
str(d_tau[c("x", "y")])
}
