[Genabel-commits] r895 - pkg/ProbABEL/src
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Wed Apr 25 11:44:15 CEST 2012
Author: lckarssen
Date: 2012-04-25 11:44:15 +0200 (Wed, 25 Apr 2012)
New Revision: 895
Modified:
pkg/ProbABEL/src/reg1.h
Log:
Small code layout changes to ProbABEL's reg1.h. No functional changes.
Modified: pkg/ProbABEL/src/reg1.h
===================================================================
--- pkg/ProbABEL/src/reg1.h 2012-04-17 00:35:49 UTC (rev 894)
+++ pkg/ProbABEL/src/reg1.h 2012-04-25 09:44:15 UTC (rev 895)
@@ -934,20 +934,23 @@
for (int i=0;i<X.nrow;i++) beta[i]=0.;
mematrix<double> u(X.nrow,1);
mematrix<double> imat(X.nrow,X.nrow);
- double work[X.ncol*2+2*(X.nrow)*(X.nrow)+3*(X.nrow)];
+ double work[X.ncol*2 + 2*(X.nrow)*(X.nrow) + 3*(X.nrow)];
double loglik_int[2];
int flag;
double sctest=1.0;
- coxfit2(&maxiter,&cdata.nids,&X.nrow,
- cdata.stime.data,cdata.sstat.data,X.data,
- newoffset.data,cdata.weights.data,cdata.strata.data,
- means.data,beta.data,u.data,
- imat.data,loglik_int,&flag,
- work,&eps,&tol_chol,
+ coxfit2(&maxiter, &cdata.nids, &X.nrow,
+ cdata.stime.data, cdata.sstat.data, X.data,
+ newoffset.data, cdata.weights.data, cdata.strata.data,
+ means.data, beta.data, u.data,
+ imat.data, loglik_int, &flag,
+ work, &eps, &tol_chol,
&sctest);
- for (int i=0;i<X.nrow;i++) sebeta[i]=sqrt(imat.get(i,i));
+ for (int i=0; i<X.nrow; i++)
+ {
+ sebeta[i] = sqrt(imat.get(i,i));
+ }
loglik = loglik_int[1];
- niter = maxiter;
+ niter = maxiter;
}
};
More information about the Genabel-commits
mailing list