[Distr-commits] r1312 - branches/distr-2.8/pkg/distrMod/tests/Examples

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sun Mar 10 18:24:30 CET 2019


Author: stamats
Date: 2019-03-10 18:24:30 +0100 (Sun, 10 Mar 2019)
New Revision: 1312

Modified:
   branches/distr-2.8/pkg/distrMod/tests/Examples/distrMod-Ex.Rout.save
Log:
Update of Rout.save - but still strange

Modified: branches/distr-2.8/pkg/distrMod/tests/Examples/distrMod-Ex.Rout.save
===================================================================
--- branches/distr-2.8/pkg/distrMod/tests/Examples/distrMod-Ex.Rout.save	2019-03-10 17:07:57 UTC (rev 1311)
+++ branches/distr-2.8/pkg/distrMod/tests/Examples/distrMod-Ex.Rout.save	2019-03-10 17:24:30 UTC (rev 1312)
@@ -458,7 +458,7 @@
         dimnames = list(nms, nms0))
     list(fval = fval0, mat = mat0)
 }
-<bytecode: 0xf1b7758>
+<bytecode: 0xd5b8870>
 Trafo / derivative matrix at which estimate was produced:
        scale shape
 shape  0.000     1
@@ -674,7 +674,7 @@
         1)/c(scale = 1)
     return(y)
 }
-<environment: 0xfedf758>
+<environment: 0xe2e04d0>
 
 > checkL2deriv(E1)
 precision of centering:	 -2.042661e-06 
@@ -862,8 +862,8 @@
 Slot "fct":
 function (x) 
 QuadFormNorm(x, A = A)
-<bytecode: 0xef44690>
-<environment: 0xef44380>
+<bytecode: 0xd346ac0>
+<environment: 0xd3467b0>
 
 > 
 > ## The function is currently defined as
@@ -1181,7 +1181,7 @@
         1)/c(meanlog = 1)
     return(y)
 }
-<environment: 0x12e4fac8>
+<environment: 0xf4d9b28>
 
 > checkL2deriv(L1)
 precision of centering:	 -0.003003394 
@@ -1546,9 +1546,231 @@
 CvM distance 
   0.03266119 
 > 
+> ## No test: 
+> ## von Mises minimum distance estimator with default mu = Mod
+> MDEstimator(x = x, ParamFamily = G, distance = CvMDist,
++             asvar.fct = .CvMMDCovarianceWithMux)
+Evaluations of Minimum CvM distance estimate ( mu = emp. cdf )  :
+-----------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  MDEstimator(x = x, ParamFamily = G, distance = CvMDist, asvar.fct = .CvMMDCovarianceWithMux)
+samplesize:   50
+estimate:
+     scale       shape  
+  0.4683173   2.6527970 
+ (0.1205419) (0.7876606)
+asymptotic (co)variance (multiplied with samplesize):
+           scale     shape
+scale  0.7265171 -4.161896
+shape -4.1618956 31.020460
+Criterion:
+CvM distance 
+  0.03266119 
+> ## or
+> CvMMDEstimator(x = x, ParamFamily = G)
+Evaluations of Minimum CvM distance estimate ( mu = model distr. ) :
+--------------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  CvMMDEstimator(x = x, ParamFamily = G)
+samplesize:   50
+estimate:
+     scale       shape  
+  0.4664460   2.7095119 
+ (0.1203869) (0.6398993)
+asymptotic (co)variance (multiplied with samplesize):
+           scale     shape
+scale  0.7246503 -3.424459
+shape -3.4244594 20.473558
+Criterion:
+CvM distance 
+  0.03185405 
+> ## or
+> CvMMDEstimator(x = x, ParamFamily = G, muDatOrMod="Mod")
+Evaluations of Minimum CvM distance estimate ( mu = model distr. ) :
+--------------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  CvMMDEstimator(x = x, ParamFamily = G, muDatOrMod = "Mod")
+samplesize:   50
+estimate:
+     scale       shape  
+  0.4664460   2.7095119 
+ (0.1203869) (0.6398993)
+asymptotic (co)variance (multiplied with samplesize):
+           scale     shape
+scale  0.7246503 -3.424459
+shape -3.4244594 20.473558
+Criterion:
+CvM distance 
+  0.03185405 
 > 
+> ## or with data based integration measure:
+> CvMMDEstimator(x = x, ParamFamily = G, muDatOrMod="Dat")
+Evaluations of Minimum CvM distance estimate ( mu = emp. cdf ) :
+----------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  CvMMDEstimator(x = x, ParamFamily = G, muDatOrMod = "Dat")
+samplesize:   50
+estimate:
+     scale       shape  
+  0.4683173   2.6527970 
+ (0.1205419) (0.7876606)
+asymptotic (co)variance (multiplied with samplesize):
+           scale     shape
+scale  0.7265171 -4.161896
+shape -4.1618956 31.020460
+Criterion:
+CvM distance 
+  0.03266119 
 > 
+> ## von Mises minimum distance estimator with mu = N(0,1)
+> MDEstimator(x = x, ParamFamily = G, distance = CvMDist, mu = Norm())
+Evaluations of Minimum CvM distance estimate ( mu =  Norm() )  :
+----------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  MDEstimator(x = x, ParamFamily = G, distance = CvMDist, mu = Norm())
+samplesize:   50
+estimate:
+    scale     shape 
+0.4856402 2.6130460 
+Criterion:
+CvM distance 
+  0.02090872 
+> ## or, with asy Var
+> MDEstimator(x = x, ParamFamily = G, distance = CvMDist, mu = Norm(),
++             asvar.fct = function(L2Fam, param, ...){
++             .CvMMDCovariance(L2Fam=L2Fam, param=param, mu=Norm(), N = 400)
++             } )
+Evaluations of Minimum CvM distance estimate ( mu =  Norm() )  :
+----------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  MDEstimator(x = x, ParamFamily = G, distance = CvMDist, asvar.fct = function(L2Fam, 
+    param, ...) {
+    .CvMMDCovariance(L2Fam = L2Fam, param = param, mu = Norm(), 
+        N = 400)
+}, mu = Norm())
+samplesize:   50
+estimate:
+     scale       shape  
+  0.4856402   2.6130460 
+ (0.1368937) (0.5947257)
+asymptotic (co)variance (multiplied with samplesize):
+           scale     shape
+scale  0.9369944 -3.627024
+shape -3.6270243 17.684935
+Criterion:
+CvM distance 
+  0.02090872 
+> ## synomymous to
+> CvMMDEstimator(x = x, ParamFamily = G, muDatOrMod="Other", mu = Norm())
+Evaluations of Minimum CvM distance estimate ( mu =  Norm() ) :
+---------------------------------------------------------------
+An object of class “CvMMDEstimate” 
+generated by call
+  CvMMDEstimator(x = x, ParamFamily = G, muDatOrMod = "Other", 
+    mu = Norm())
+samplesize:   50
+estimate:
+     scale       shape  
+  0.4856402   2.6130460 
+ (0.1368937) (0.5947257)
+asymptotic (co)variance (multiplied with samplesize):
+           scale     shape
+scale  0.9369944 -3.627024
+shape -3.6270243 17.684935
+Criterion:
+CvM distance 
+  0.02090872 
 > 
+> ## Total variation minimum distance estimator
+> ## gamma distributions are discretized
+> MDEstimator(x = x, ParamFamily = G, distance = TotalVarDist)
+Evaluations of Minimum total variation distance estimate  :
+-----------------------------------------------------------
+An object of class “MDEstimate” 
+generated by call
+  MDEstimator(x = x, ParamFamily = G, distance = TotalVarDist)
+samplesize:   50
+estimate:
+    scale     shape 
+0.4280712 3.0624864 
+Criterion:
+total variation distance 
+               0.5287968 
+> ## or
+> TotalVarMDEstimator(x = x, ParamFamily = G)
+Evaluations of Minimum total variation distance estimate  :
+-----------------------------------------------------------
+An object of class “MDEstimate” 
+generated by call
+  TotalVarMDEstimator(x = x, ParamFamily = G)
+samplesize:   50
+estimate:
+    scale     shape 
+0.4280712 3.0624864 
+Criterion:
+total variation distance 
+               0.5287968 
+> ## or smoothing of emprical distribution (takes some time!)
+> #MDEstimator(x = x, ParamFamily = G, distance = TotalVarDist, asis.smooth.discretize = "smooth")
+> 
+> ## Hellinger minimum distance estimator
+> ## gamma distributions are discretized
+> distroptions(DistrResolution = 1e-10)
+> MDEstimator(x = x, ParamFamily = G, distance = HellingerDist, startPar = c(1,2))
+Evaluations of Minimum Hellinger distance estimate  :
+-----------------------------------------------------
+An object of class “MDEstimate” 
+generated by call
+  MDEstimator(x = x, ParamFamily = G, distance = HellingerDist, 
+    startPar = c(1, 2))
+samplesize:   50
+estimate:
+    scale     shape 
+0.8221157 1.8103284 
+Criterion:
+Hellinger distance 
+         0.3981454 
+> ## or
+> HellingerMDEstimator(x = x, ParamFamily = G, startPar = c(1,2))
+Evaluations of Minimum Hellinger distance estimate  :
+-----------------------------------------------------
+An object of class “MDEstimate” 
+generated by call
+  HellingerMDEstimator(x = x, ParamFamily = G, startPar = c(1, 
+    2))
+samplesize:   50
+estimate:
+    scale     shape 
+0.8221157 1.8103284 
+Criterion:
+Hellinger distance 
+         0.3981454 
+> distroptions(DistrResolution = 1e-6) # default
+> ## or smoothing of emprical distribution (takes some time!)
+> MDEstimator(x = x, ParamFamily = G, distance = HellingerDist, asis.smooth.discretize = "smooth")
+Evaluations of Minimum Hellinger distance estimate  :
+-----------------------------------------------------
+An object of class “MDEstimate” 
+generated by call
+  MDEstimator(x = x, ParamFamily = G, distance = HellingerDist, 
+    asis.smooth.discretize = "smooth")
+samplesize:   50
+estimate:
+    scale     shape 
+0.3605269 3.2062287 
+Criterion:
+Hellinger distance 
+        0.06807464 
+> ## End(No test)
+> 
+> 
+> 
 > base::assign(".dptime", (proc.time() - get(".ptime", pos = "CheckExEnv")), pos = "CheckExEnv")
 > base::cat("MDEstimator", base::get(".format_ptime", pos = 'CheckExEnv')(get(".dptime", pos = "CheckExEnv")), "\n", file=base::get(".ExTimings", pos = 'CheckExEnv'), append=TRUE, sep="\t")
 > cleanEx()
@@ -2289,7 +2511,7 @@
         return(abs(x))
     else return(sqrt(colSums(x^2)))
 }
-<bytecode: 0x1497bc60>
+<bytecode: 0x4388cb8>
 <environment: namespace:distrMod>
 > name(EuclNorm)
 [1] "EuclideanNorm"
@@ -2324,7 +2546,7 @@
         return(abs(x))
     else return(sqrt(colSums(x^2)))
 }
-<bytecode: 0x1497bc60>
+<bytecode: 0x4388cb8>
 <environment: namespace:distrMod>
 
 > 
@@ -2807,8 +3029,8 @@
 Slot "fct":
 function (x) 
 QuadFormNorm(x, A = A0)
-<bytecode: 0xc40ca68>
-<environment: 0xc40cf00>
+<bytecode: 0xbf6a8e8>
+<environment: 0xbf6ad48>
 
 > 
 > ## The function is currently defined as
@@ -2849,8 +3071,8 @@
 Slot "fct":
 function (x) 
 QuadFormNorm(x, A = A)
-<bytecode: 0xbf04c20>
-<environment: 0xbf05278>
+<bytecode: 0xcb64460>
+<environment: 0xc92c438>
 
 > 
 > ## The function is currently defined as
@@ -3977,7 +4199,7 @@
     dimnames(mat) <- list(nfval, c("mean", "sd"))
     return(list(fval = fval, mat = mat))
 }
-<bytecode: 0x18f82f50>
+<bytecode: 0x11bf2170>
 > print(param(NS), show.details = "minimal")
 An object of class "ParamWithScaleFamParameter"
 name:	location and scale
@@ -4026,7 +4248,7 @@
     dimnames(mat) <- list(nfval, c("mean", "sd"))
     return(list(fval = fval, mat = mat))
 }
-<bytecode: 0x18f82f50>
+<bytecode: 0x11bf2170>
 Trafo / derivative matrix:
             mean         sd
 mu/sig 0.3668695 -0.3024814
@@ -4069,7 +4291,7 @@
     dimnames(mat) <- list(nfval, c("mean", "sd"))
     return(list(fval = fval, mat = mat))
 }
-<bytecode: 0x18f82f50>
+<bytecode: 0x11bf2170>
 Trafo / derivative matrix:
          mean      sd
 mu/sig 0.3669 -0.3025
@@ -4490,7 +4712,7 @@
 > cleanEx()
 > options(digits = 7L)
 > base::cat("Time elapsed: ", proc.time() - base::get("ptime", pos = 'CheckExEnv'),"\n")
-Time elapsed:  22.038 0.176 22.225 0 0.008 
+Time elapsed:  51.31 0.261 51.589 0 0.007 
 > grDevices::dev.off()
 null device 
           1 



More information about the Distr-commits mailing list