+--------------------------------------------------------------------+
| |
| MIX |
| |
+--------------------------------------------------------------------+
MEANING: MIX subroutine
CONTEXT: User-supplied subroutine; replaces a NONMEM dummy routine
USAGE:
SUBROUTINE MIX (ICALL,NSPOP,P)
USE SIZES, ONLY: ISIZE,DPSIZE,LTH
USE ROCM_REAL, ONLY: THETA=>THETAC
INTEGER(KIND=ISIZE), INTENT(IN) :: ICALL
INTEGER(KIND=ISIZE), INTENT(OUT) :: NSPOP
REAL(KIND=DPSIZE), INTENT(OUT) :: P(*)
GLOBAL DECLARATION:
REAL(KIND=DPSIZE) :: THETAC(LTH)
DISCUSSION:
MIX is a NONMEM routine that is replaced by a user-supplied routine
when a mixture model is used. The MIX subroutine is used to describe
the mixture parameters of a mixture model. It is called by NONMEM
with one individual record after another.
Input argument:
ICALL
Similar to ICALL for PRED subroutine.
Output argument:
NSPOP
An integer variable or integer constant. The maximum number of
sub-populations that are possible. Must be given a value when
ICALL=1.
P An array. For each i (i=1, ... , NSPOP), P(i) gives the modeled
fraction of the population in the ith subpopulation. The sum of
the P(i) should equal 1. In principle, the P(i) can change from
individual to individual. If for a given individual, the second
(for example) subpopulation doesn't apply, then set P(2)=0 for
that individual.
Other inputs are available to MIX in NONMEM read-only global vari-
ables. In particular, data items that are requested using the $CONTR
record, and the current value of THETA, as shown above.
(See MIX:_DATA, MIX CONTR:_THETA).
The TEMPLT data record in a NONMEM read-only global variable also
serves to provide an additional way for individual-specific informa-
tion to be made available
(See MIX_CONTR:_TEMPLT)
With mixture models, MIXNUM, MIXEST and MIXP are variables that may be
used as right-hand quantities (or in logical conditions) in various
other abbreviated codes or user-supplied routines. MIXNUM is the
index of the subpopulation for which variables are to be computed. At
ICALL=3, and at ICALL=2 when COMACT is not 0, MIXEST is the index of
the subpopulation estimated to be that from which the individual's
data most probably arises. MIXP refers to the mixture probabilities P
computed by subroutine MIX.
This is a general description. For details, see mixnum. |
(See MIXNUM_MIXEST_MIXP)
(See mixnum_mixest_for_mixture_model)
(See Mixture_model:_MIXP)
(See mixture_model_example, mixnum_mixest).
REFERENCES: Guide III Section V.5.0
REFERENCES: Guide IV Section III.B.4, III.B.6
REFERENCES: Guide IV Section IV.E.1, 4.E.2
REFERENCES: Guide VI Section III.L.2, Figure 6
Go to main index.
Created by nmhelp2html v. 1.0 written by Niclas Jonsson (Modified by AJB 5/2006,11/2007,10/2012)