 Usage:  {xr,yr,wxr,offr,ctrl} = glminit(code,x,y{,opt})  
 
 Input:

  code                   text string, the short code for the model (e.g. 
                         "bilo" for logit or "noid" for ordinary PLM). 
                         
  x                      n x p matrix, the predictor variables. 
                         
  y                      n x 1 vector, the response variables. Binomial 
                         y[i] may have (integer) values between 0 
                         and opt.wx[i] or opt.wx (if opt.wx is scalar). 
                         
  opt                    optional, a list with optional input. The macro 
                         "glmopt" can be used to set up this parameter. 
                         The order of the list elements is not important. 
                         Parameters which are not given are replaced by 
                         defaults (see below). 
                         
  opt.weights            string, type of weights. Can be "frequency" 
                         for replication counts, or "prior" (default) 
                         for prior weights in weighted regression. 
                         
  opt.wx                 scalar or n x 1 vector, frequency or prior 
                         weights. If not given, set to 1. 
                         
  opt.off                scalar or n x 1 vector, offset. Can be used for 
                         constrained estimation. If not given, set to 0. 
                         
  opt.shf                integer, if exists and =1, some output is produced 
                         which indicates how the iteration is going on. 
                         
  opt.miter              integer, maximal number of iterations. The default 
                         is 10. 
                         
  opt.cnv                integer, convergence criterion. The default is 0.0001. 
                         
  opt.fscor              integer, if exists and =1, a Fisher scoring is 
                         performed (instead of the default Newton-Raphson 
                         procedure). This parameter is ignored for 
                         canonical links. 
                         
  opt.pow                optional, power for power link. 
                         
  opt.nbk                scalar, extra parameter k for negative binomial 
                         distribution. If not given, set to 1 (geometric 
                         distribution). 
                         
 Output:

  xr                     nr x p matrix, the predictor variables, 
                         eventually reduced up to replications. 
                         
  yr                     nr x 1 or nr x 2 or nr x 3 matrix, 
                         either the response values, or sums of response 
                         values in 1st column and sums of a function 
                         of response values in the 2nd and 3rd column (e.g. 
                         sums of y^2 or log(y), see glmll). 
                         (In the case of replicated data, the number of 
                         replications should be given in wx, yr[,1] contains 
                         the sums of all responses for a replication, 
                         yr[,2:3] contains sums of e.g. y^2 or log(y) for a 
                         replication.) 
                         
  wxr                    nr x 1 vector or scalar, weights. 
                         
  offr                   nr x 1 vector or scalar, offset. 
                         
  ctrl                   6 x 1 integer vector or scalar, contains control 
                         parameters shf, miter, cnv, fscor, pow, nbk 
                         or shf alone. 
                         Defaults for miter, cnv, fscor, pow, nbk are 
                         10, 0.0001, 0, 0 (logarithm link) and 1. 
                         
--------------------------------------------------------------
(C) MD*TECH Method and Data Technologies, 17.8.2000
