[Gmm-commits] r205 - in pkg/gmm: . R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sat Dec 3 21:55:33 CET 2022


Author: chaussep
Date: 2022-12-03 21:55:33 +0100 (Sat, 03 Dec 2022)
New Revision: 205

Modified:
   pkg/gmm/DESCRIPTION
   pkg/gmm/R/getModel.R
Log:
fixed a big with sample size

Modified: pkg/gmm/DESCRIPTION
===================================================================
--- pkg/gmm/DESCRIPTION	2022-10-19 21:09:41 UTC (rev 204)
+++ pkg/gmm/DESCRIPTION	2022-12-03 20:55:33 UTC (rev 205)
@@ -1,5 +1,5 @@
 Package: gmm
-Version: 1.7
+Version: 1.8
 Date: 2022-07-30
 Title: Generalized Method of Moments and Generalized Empirical
         Likelihood

Modified: pkg/gmm/R/getModel.R
===================================================================
--- pkg/gmm/R/getModel.R	2022-10-19 21:09:41 UTC (rev 204)
+++ pkg/gmm/R/getModel.R	2022-12-03 20:55:33 UTC (rev 205)
@@ -225,8 +225,8 @@
                     attr(object$x, "k") <- 1
                 else
                     attr(object$x, "k") <- length(object$t0)
-                attr(object$x, "q") <- NCOL(object$g(object$t0, object$x))
-                attr(object$x, "n") <- NROW(object$x)
+                attr(object$x, "q") <- NCOL(gt <- object$g(object$t0, object$x))
+                attr(object$x, "n") <- NROW(gt)
                 if (object$optfct == "optimize")
                     {
                         object$namesCoef <- "Theta1"
@@ -373,8 +373,8 @@
                 attr(object$x,"ModelType") <- "nonlinear"
                 attr(object$x, "momentfct") <- object$g
                 attr(object$x, "k") <- k
-                attr(object$x, "q") <- NCOL(object$g(object$tet0, object$x))
-                attr(object$x, "n") <- NROW(object$x)
+                attr(object$x, "q") <- NCOL(gt <- object$g(object$tet0, object$x))
+                attr(object$x, "n") <- NROW(gt)
                 if(is.null(names(object$tet0)))
                     object$namesCoef <- paste("Theta[" ,1:attr(object$x, "k"), "]", sep = "")
                 else



More information about the Gmm-commits mailing list