You are here: Symbol Reference > Regress Namespace > Functions > Regress.LogisticRegress Function
Stats Master VCL
ContentsIndex
Example

The following example calculates coefficients for simple logistic regression. The counts are out of 10 in each case and there is one covariate[1].

Uses MtxExpr, Regress;
procedure Example;
var y,n,B: Vector;
begin
  y.SetIt(false,[2,0,3,1,5,5,6,9,5,9]);
  n.Size(y);
  n.SetVal(10.0);

  LogisticRegress(y,n,B);
end;
#include "MtxExpr.hpp"
#include "Regress.hpp"
#include "Math387.hpp"
void __fastcall Example()
{
  sVector y,n,B,ycalc;
  y.SetIt(false,OPENARRAY(double,(2,0,3,1,5,5,6,9,5,9)));
  n.Size(y);
  n.SetVal(10.0);

  LogisticRegress(y,n,B);
}
Copyright (c) 1999-2025 by Dew Research. All rights reserved.