\hypertarget{classegiw}{
\section{egiw Class Reference}
\label{classegiw}\index{egiw@{egiw}}
}
Gauss-inverse-Wishart density stored in LD form.  


{\tt \#include $<$libEF.h$>$}

Inheritance diagram for egiw:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=40pt]{classegiw__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for egiw:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=72pt]{classegiw__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
\hypertarget{classegiw_c52a2173c6eb1490edce9c6c7c05d60b}{
\hyperlink{classegiw_c52a2173c6eb1490edce9c6c7c05d60b}{egiw} (\hyperlink{classRV}{RV} \hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv}, mat V0, double nu0)}
\label{classegiw_c52a2173c6eb1490edce9c6c7c05d60b}

\begin{CompactList}\small\item\em Default constructor, assuming. \item\end{CompactList}\item 
\hypertarget{classegiw_1a17fdbac6c72b9c3abb97623db466c8}{
\hyperlink{classegiw_1a17fdbac6c72b9c3abb97623db466c8}{egiw} (\hyperlink{classRV}{RV} \hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv}, \hyperlink{classldmat}{ldmat} V0, double nu0)}
\label{classegiw_1a17fdbac6c72b9c3abb97623db466c8}

\begin{CompactList}\small\item\em Full constructor for V in \hyperlink{classldmat}{ldmat} form. \item\end{CompactList}\item 
\hypertarget{classegiw_3d2c1f2ba0f9966781f1e0ae695e8a6f}{
vec \hyperlink{classegiw_3d2c1f2ba0f9966781f1e0ae695e8a6f}{sample} () const }
\label{classegiw_3d2c1f2ba0f9966781f1e0ae695e8a6f}

\begin{CompactList}\small\item\em Returns a sample, $x$ from density $epdf(rv)$. \item\end{CompactList}\item 
\hypertarget{classegiw_6deb0ff2859f41ef7cbdf6a842cabb29}{
vec \hyperlink{classegiw_6deb0ff2859f41ef7cbdf6a842cabb29}{mean} () const }
\label{classegiw_6deb0ff2859f41ef7cbdf6a842cabb29}

\begin{CompactList}\small\item\em return expected value \item\end{CompactList}\item 
\hypertarget{classegiw_9594f396acc5ad186d1c5b03b0745502}{
void \textbf{mean\_\-mat} (mat \&M, mat \&R) const }
\label{classegiw_9594f396acc5ad186d1c5b03b0745502}

\item 
\hypertarget{classegiw_2ab1e525d692be8272a6f383d60b94cd}{
double \hyperlink{classegiw_2ab1e525d692be8272a6f383d60b94cd}{evalpdflog\_\-nn} (const vec \&val) const }
\label{classegiw_2ab1e525d692be8272a6f383d60b94cd}

\begin{CompactList}\small\item\em In this instance, val= \mbox{[}theta, r\mbox{]}. For multivariate instances, it is stored columnwise val = \mbox{[}theta\_\-1 theta\_\-2 ... r\_\-1 r\_\-2 \mbox{]}. \item\end{CompactList}\item 
\hypertarget{classegiw_70eb1a0b88459b227f919b425b0d3359}{
double \hyperlink{classegiw_70eb1a0b88459b227f919b425b0d3359}{lognc} () const }
\label{classegiw_70eb1a0b88459b227f919b425b0d3359}

\begin{CompactList}\small\item\em logarithm of the normalizing constant, $\mathcal{I}$ \item\end{CompactList}\item 
\hypertarget{classegiw_533e792e1175bfa06d5d595dc5d080d5}{
\hyperlink{classldmat}{ldmat} \& \hyperlink{classegiw_533e792e1175bfa06d5d595dc5d080d5}{\_\-V} ()}
\label{classegiw_533e792e1175bfa06d5d595dc5d080d5}

\begin{CompactList}\small\item\em returns a pointer to the internal statistics. Use with Care! \item\end{CompactList}\item 
\hypertarget{classegiw_08029c481ff95d24f093df0573879afe}{
double \& \hyperlink{classegiw_08029c481ff95d24f093df0573879afe}{\_\-nu} ()}
\label{classegiw_08029c481ff95d24f093df0573879afe}

\begin{CompactList}\small\item\em returns a pointer to the internal statistics. Use with Care! \item\end{CompactList}\item 
\hypertarget{classegiw_036306322a90a9977834baac07460816}{
void \hyperlink{classegiw_036306322a90a9977834baac07460816}{pow} (double p)}
\label{classegiw_036306322a90a9977834baac07460816}

\begin{CompactList}\small\item\em Power of the density, used e.g. to flatten the density. \item\end{CompactList}\item 
\hypertarget{classeEF_a89bef8996410609004fa019b5b48964}{
virtual void \hyperlink{classeEF_a89bef8996410609004fa019b5b48964}{dupdate} (mat \&v)}
\label{classeEF_a89bef8996410609004fa019b5b48964}

\begin{CompactList}\small\item\em TODO decide if it is really needed. \item\end{CompactList}\item 
\hypertarget{classeEF_6466e8d4aa9dd64698ed288cbb1afc03}{
virtual double \hyperlink{classeEF_6466e8d4aa9dd64698ed288cbb1afc03}{evalpdflog} (const vec \&val) const }
\label{classeEF_6466e8d4aa9dd64698ed288cbb1afc03}

\begin{CompactList}\small\item\em Evaluate normalized log-probability. \item\end{CompactList}\item 
\hypertarget{classeEF_c71faf4b2d153efda14bf1f87dca1507}{
virtual vec \hyperlink{classeEF_c71faf4b2d153efda14bf1f87dca1507}{evalpdflog} (const mat \&Val) const }
\label{classeEF_c71faf4b2d153efda14bf1f87dca1507}

\begin{CompactList}\small\item\em Evaluate normalized log-probability for many samples. \item\end{CompactList}\item 
\hypertarget{classepdf_54d7dd53a641b618771cd9bee135181f}{
virtual mat \hyperlink{classepdf_54d7dd53a641b618771cd9bee135181f}{sampleN} (int N) const }
\label{classepdf_54d7dd53a641b618771cd9bee135181f}

\begin{CompactList}\small\item\em Returns N samples from density $epdf(rv)$. \item\end{CompactList}\item 
\hypertarget{classepdf_3ea597362e11a0040fe7c990269d072c}{
virtual double \hyperlink{classepdf_3ea597362e11a0040fe7c990269d072c}{eval} (const vec \&val) const }
\label{classepdf_3ea597362e11a0040fe7c990269d072c}

\begin{CompactList}\small\item\em Compute probability of argument {\tt val}. \item\end{CompactList}\item 
\hypertarget{classepdf_cebbdd7a85e6328f7358fc0ba8eee06c}{
virtual vec \hyperlink{classepdf_cebbdd7a85e6328f7358fc0ba8eee06c}{evalpdflog\_\-m} (const mat \&Val) const }
\label{classepdf_cebbdd7a85e6328f7358fc0ba8eee06c}

\begin{CompactList}\small\item\em Compute log-probability of multiple values argument {\tt val}. \item\end{CompactList}\item 
\hypertarget{classepdf_3ba08c0e788deff22134c049b9269666}{
\hyperlink{classmpdf}{mpdf} $\ast$ \hyperlink{classepdf_3ba08c0e788deff22134c049b9269666}{condition} (const \hyperlink{classRV}{RV} \&\hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv})}
\label{classepdf_3ba08c0e788deff22134c049b9269666}

\begin{CompactList}\small\item\em Return conditional density on the given \hyperlink{classRV}{RV}, the remaining rvs will be in conditioning. \item\end{CompactList}\item 
\hypertarget{classepdf_bc0c171b6dafacd78d26263913b1d0c0}{
\hyperlink{classepdf}{epdf} $\ast$ \hyperlink{classepdf_bc0c171b6dafacd78d26263913b1d0c0}{marginal} (const \hyperlink{classRV}{RV} \&\hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv})}
\label{classepdf_bc0c171b6dafacd78d26263913b1d0c0}

\begin{CompactList}\small\item\em Return marginal density on the given \hyperlink{classRV}{RV}, the remainig rvs are intergrated out. \item\end{CompactList}\item 
\hypertarget{classepdf_ca0d32aabb4cbba347e0c37fe8607562}{
const \hyperlink{classRV}{RV} \& \hyperlink{classepdf_ca0d32aabb4cbba347e0c37fe8607562}{\_\-rv} () const }
\label{classepdf_ca0d32aabb4cbba347e0c37fe8607562}

\begin{CompactList}\small\item\em access function, possibly dangerous! \item\end{CompactList}\item 
\hypertarget{classepdf_7fb94ce90d1ac7077d29f7d6a6c3e0a5}{
void \hyperlink{classepdf_7fb94ce90d1ac7077d29f7d6a6c3e0a5}{\_\-renewrv} (const \hyperlink{classRV}{RV} \&in\_\-rv)}
\label{classepdf_7fb94ce90d1ac7077d29f7d6a6c3e0a5}

\begin{CompactList}\small\item\em modifier function - useful when copying epdfs \item\end{CompactList}\end{CompactItemize}
\subsection*{Protected Attributes}
\begin{CompactItemize}
\item 
\hypertarget{classegiw_f343d03ede89db820edf44a6297fa442}{
\hyperlink{classldmat}{ldmat} \hyperlink{classegiw_f343d03ede89db820edf44a6297fa442}{V}}
\label{classegiw_f343d03ede89db820edf44a6297fa442}

\begin{CompactList}\small\item\em Extended information matrix of sufficient statistics. \item\end{CompactList}\item 
\hypertarget{classegiw_4a2f130b91afe84f6d62fed289d5d453}{
double \hyperlink{classegiw_4a2f130b91afe84f6d62fed289d5d453}{nu}}
\label{classegiw_4a2f130b91afe84f6d62fed289d5d453}

\begin{CompactList}\small\item\em Number of data records (degrees of freedom) of sufficient statistics. \item\end{CompactList}\item 
\hypertarget{classegiw_3d5c719f15a5527a6c62c2a53160148e}{
int \hyperlink{classegiw_3d5c719f15a5527a6c62c2a53160148e}{xdim}}
\label{classegiw_3d5c719f15a5527a6c62c2a53160148e}

\begin{CompactList}\small\item\em Dimension of the output. \item\end{CompactList}\item 
\hypertarget{classegiw_c70d13d86e0d9f0acede3e1dc0368812}{
int \hyperlink{classegiw_c70d13d86e0d9f0acede3e1dc0368812}{nPsi}}
\label{classegiw_c70d13d86e0d9f0acede3e1dc0368812}

\begin{CompactList}\small\item\em Dimension of the regressor. \item\end{CompactList}\item 
\hypertarget{classepdf_74da992e3f5d598da8850b646b79b9d9}{
\hyperlink{classRV}{RV} \hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv}}
\label{classepdf_74da992e3f5d598da8850b646b79b9d9}

\begin{CompactList}\small\item\em Identified of the random variable. \item\end{CompactList}\end{CompactItemize}


\subsection{Detailed Description}
Gauss-inverse-Wishart density stored in LD form. 

For $p$-variate densities, given rv.count() should be $p\times$ V.rows(). 

The documentation for this class was generated from the following files:\begin{CompactItemize}
\item 
work/git/mixpp/bdm/stat/\hyperlink{libEF_8h}{libEF.h}\item 
work/git/mixpp/bdm/stat/libEF.cpp\end{CompactItemize}
