1.2 Current version and changes
There is a list of the changes that have been made since the first version of H2M (Mar. 18,
1997) in the file h2m/doc/CHANGES. The current version number which should be found in
all the m-files is 2.0. Since version 1.3, the code for the multivariate Gaussian case has
been pretty stable and changes have m ostly concerned the documentation and examples.
The H2M/cnt extension appears only in version 2.0.
1.3 License and warranty
You should read the h2m/LICENSE file (especially if you plan se lling this code to the
MathWorks - or to someone else - or suing me because it doesn’t work).
1.4 MATLAB/OCTAVE compatibility
H2M functions where originally developed using MAT LAB V4 and then MATLAB V5,
they will thus run on any currently available version of MATLAB. The only exception is
the mex-file c_dgaus.c which uses the mex-specific V5 syntax (the obsolete V4 lines are
commented out) - if you are using the MATLAB compiler mcc however you shouldn’t need
that anyway (see section 2.5.3).
The H2M functions have also been tested using OCTAVE (the GNU alternative to
MATLAB), version 2.0.13. It basically works as long as you are using the --traditional
switch. The sub-directory octave contains a minimal set of MATLAB compatibility rou-
tines needed to run the three examples ex_basic, ex_bic and ex_sprec (remember to
append this sub-directory to your loadpath using the path command if you are using
OCTAVE). The only significant difference is that OCTAVE does not allow for sparse
matrices.
The H2M/cnt functions have been tested under version 2.0.16 of OCTAVE (always
using the --traditional switch). Note that the simulation routines (pm_gen, ph_gen
and nbh_gen) do require some functions that have been introduced in version 2.0.14 of
OCTAVE (poisson_rnd and gamma_rnd for simulating random deviates). The H2M/cnt
functions naturally run without problem using MATLAB V5 but you will need the Statis-
tics toolbox which contains the poissrnd and gammrnd functions in order for the simulation
routines to work (see section 4.2.2 for other possible solutions).
1.5 FAQ
Here are the answers to some questions I have been asked several times (hope this helps):
Why does the log-likelihood takes positive values? For Gaussian state conditional
densities, the likelihood is a value from a probability density function (pdf) and
should thus not be interpreted as a probability (it can take any positive values, not
only those smaller than 1). For such models, obtaining log-likelihood values greater
than 0 is certainly not a bug. It is easy to see that if you scale your observations
by, say, 10, and modify the parameters of the model accordingly (divide the means
by 10 and the variances by 10 to the square), then the likelihood is multiplied by
10^(T*p) (the log-likelihood is increased by T*p*log(10)) where T is the number
of observations and p their dimension.
Does H2M has some limits on the dimension or on the scaling of the data? The
dynamics of the Gaussian pdf increases steadily with the dimension, so that if you
are in large dimension and try to compute the value of the Gaussian pdf far from
3