[Deoptim-commits] r110 - pkg/DEoptim/src
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Sep 28 01:41:46 CEST 2012
Author: kmm
Date: 2012-09-28 01:41:45 +0200 (Fri, 28 Sep 2012)
New Revision: 110
Modified:
pkg/DEoptim/src/evaluate.c
Log:
feval
Modified: pkg/DEoptim/src/evaluate.c
===================================================================
--- pkg/DEoptim/src/evaluate.c 2012-09-01 19:38:30 UTC (rev 109)
+++ pkg/DEoptim/src/evaluate.c 2012-09-27 23:41:45 UTC (rev 110)
@@ -9,7 +9,7 @@
double f_result;
PROTECT(fn = lang3(fcall, par, R_DotsSymbol));
- (*l_nfeval)++; /* increment function evaluation count */
+ (*l_nfeval)++; /* increment function evaluation count */
PROTECT(sexp_fvec = eval(fn, env));
f_result = NUMERIC_POINTER(sexp_fvec)[0];
@@ -28,10 +28,10 @@
int P = 0;
PROTECT(fn = lang3(fcall, parMat, R_DotsSymbol)); P++;
- (*l_nfeval)++; /* increment function evaluation count */
-
+
PROTECT(sexp_fvec = eval(fn, env)); P++;
int nr = nrows(sexp_fvec);
+ (*l_nfeval) += nr;
if(nr != nrows(parMat))
error("objective function result has different length than parameter matrix");
switch(TYPEOF(sexp_fvec)) {
More information about the Deoptim-commits
mailing list