N. Brouard [Mon, 24 May 2004 18:32:25 +0000 (18:32 +0000)]
Agnes added a direct estimation of mortality (without the need of
computing period prevalence and differential mortality). Thus here
is version 0.97a which has been distributed to some people at
REVES 16 in Brugge using an Inno setup.exe for PCs. Estimates of
mortality using covariates is not done today. Estimating direct
mortality is a very different process because it doesn't need
interpolation because it is easy to get the lx from the force of
the mortality mux in the simplest case as for a Gompertz (log mux
= a + b*x . But we have been able to incorporate the new code
within former imach program (0.96d) without deteriorating too much
the understanding of the program.
Gnuplot is now installed in the same directory (on Windows) as imach.
Thus the full path of gnuplot is executed in order to access the
current version.
N. Brouard [Sun, 16 May 2004 15:05:56 +0000 (15:05 +0000)]
New version 0.97 . First attempt to estimate force of mortality
directly from the data i.e. without the need of knowing the health
state at each age, but using a Gompertz model: log u =a + b*age .
This is the basic analysis of mortality and should be done before any
other analysis, in order to test if the mortality estimated from the
cross-longitudinal survey is different from the mortality estimated
from other sources like vital statistic data.
The same imach parameter file can be used but the option for mle should be -3.
Agn�s, who wrote this part of the code, tried to keep most of the
former routines in order to include the new code within the former code.
The output is very simple: only an estimate of the intercept and of
the slope with 95% confident intervals.
Current limitations:
A) Even if you enter covariates, i.e. with the
model= V1+V2 equation for example, the programm does only estimate a unique global model without covariates.
B) There is no computation of Life Expectancy nor Life Table.
N. Brouard [Wed, 25 Jun 2003 15:30:29 +0000 (15:30 +0000)]
* imach.c (Repository): Duplicated warning errors corrected.
(Repository): Elapsed time after each iteration is now output. It
helps to forecast when convergence will be reached. Elapsed time
is stamped in powell. We created a new html file for the graphs
concerning matrix of covariance. It has extension -cov.htm.
N. Brouard [Tue, 24 Jun 2003 12:34:15 +0000 (12:34 +0000)]
(Module): Some bugs corrected for windows. Also, when
mle=-1 a template is output in file "or"mypar.txt with the design
of the covariance matrix to be input.
N. Brouard [Tue, 24 Jun 2003 12:30:52 +0000 (12:30 +0000)]
(Module): Some bugs corrected for windows. Also, when
mle=-1 a template is output in file "or"mypar.txt with the design
of the covariance matrix to be input.
N. Brouard [Mon, 23 Jun 2003 17:54:56 +0000 (17:54 +0000)]
* imach.c (Repository): Create a sub-directory where all the secondary files are. Only imach, htm, gp and r(imach) are on the main directory. Correct time and other things.
N. Brouard [Tue, 17 Jun 2003 13:12:43 +0000 (13:12 +0000)]
* imach.c (Repository): Check when date of death was earlier that
current date of interview. It may happen when the death was just
prior to the death. In this case, dh was negative and likelihood
was wrong (infinity). We still send an "Error" but patch by
assuming that the date of death was just one stepm after the
interview.
(Repository): Because some people have very long ID (first column)
we changed int to long in num[] and we added a new lvector for
memory allocation. But we also truncated to 8 characters (left
truncation)
(Repository): No more line truncation errors.
N. Brouard [Fri, 13 Jun 2003 21:44:43 +0000 (21:44 +0000)]
* imach.c (Repository): Replace "freqsummary" at a correct
place. It differs from routine "prevalence" which may be called
many times. Probs is memory consuming and must be used with
parcimony.
Version 0.95a2 (should output exactly the same maximization than 0.8a2)
In freqsummary, the observed prevalence is now computed from all the
waves and the bug in the forecasting routine is corrected. We can
forecast prevalence if ncov=0.
N. Brouard [Fri, 28 Mar 2003 13:33:56 +0000 (13:33 +0000)]
(Module): In version up to 0.92 likelihood was computed
as if date of death was unknown. Death was treated as any other
health state: the date of the interview describes the actual state
and not the date of a change in health state. The former idea was
to consider that at each interview the state was recorded
(healthy, disable or death) and IMaCh was corrected; but when we
introduced the exact date of death then we should have modified
the contribution of an exact death to the likelihood. This new
contribution is smaller and very dependent of the step unit
stepm. It is no more the probability to die between last interview
and month of death but the probability to survive from last
interview up to one month before death multiplied by the
probability to die within a month. Thanks to Chris
Jackson for correcting this bug. Former versions increased
mortality artificially. The bad side is that we add another loop
which slows down the processing. The difference can be up to 10%
lower mortality. Version 0.93
N. Brouard [Fri, 28 Mar 2003 13:32:54 +0000 (13:32 +0000)]
(Module): In version up to 0.92 likelihood was computed
as if date of death was unknown. Death was treated as any other
health state: the date of the interview describes the actual state
and not the date of a change in health state. The former idea was
to consider that at each interview the state was recorded
(healthy, disable or death) and IMaCh was corrected; but when we
introduced the exact date of death then we should have modified
the contribution of an exact death to the likelihood. This new
contribution is smaller and very dependent of the step unit
stepm. It is no more the probability to die between last interview
and month of death but the probability to survive from last
interview up to one month before death multiplied by the
probability to die within a month. Thanks to Chris
Jackson for correcting this bug. Former versions increased
mortality artificially. The bad side is that we add another loop
which slows down the processing. The difference can be up to 10%
lower mortality.
Agnès Lièvre [Thu, 21 Nov 2002 08:46:21 +0000 (08:46 +0000)]
Extrapolation doesn't seem to work fine, so we decided to use
interpolation only ie at the cost of an additional matrix product if
the bias, bbh, is positive, in order to make it negative
(interpolation).
We keep other methods mle=4 no adjustment for bias, mle=3 inter-extra
exponential, mle=2 inter-extra linear.
N. Brouard [Mon, 18 Nov 2002 23:01:13 +0000 (23:01 +0000)]
Major change: likelihood is modified in order to unbiased the duration
between 2 waves which is rounded (biased) to the nearest multiple of
stepm.
Some cleaning of the code. Many allocations were not freed correctly.
N. Brouard [Mon, 10 Jun 2002 13:12:01 +0000 (13:12 +0000)]
Many changes:
(a) We look at covariance between step probabilities by drawing
confidence interval ellipsoids of two step probabilities pij versus
pkl.
It is done by diagonalizing the inverse of the convariance matrix.
(b) In order to write to the gnuplot file or even to the html file
without using to much memory we are now reopening ficgp and fichtm
with an "append" option each time we need them into the main program.
It is better than keeping matrices in memory until the end.