R Under development (unstable) (2024-10-16 r87241 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > if(!require("GNE"))stop("this test requires package GNE.") Loading required package: GNE Loading required package: alabama Loading required package: numDeriv Loading required package: nleqslv Loading required package: BB Loading required package: SQUAREM > > > try(funSSR("x")) Error in funSSR("x") : argument "dimx" is missing, with no default > > try(funSSR(rep(1, 2) , 1, grobj=function(x) x)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : SSR: incompatible dimension for dimlam, dimx, dimmu. > > try(funSSR(rep(1, 2), rep(1, 2), grobj=function(x) x)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : missing compl argument. > > try(funSSR(rep(1, 2), rep(1, 2), grobj=function(x) x, compl=phiFB)) Error in grobj(z, i, j) : unused arguments (i, j) Error when calling function, below the try output. [1] "Error in grobj(z, i, j) : unused arguments (i, j)\n" attr(,"class") [1] "try-error" attr(,"condition") Arguments are: [[1]] [1] 1 1 [[2]] [1] 1 [[3]] [1] 1 [[4]] list() Error in testfunc(grobjfinal, z, arg = arggrobj, echo = echo, errmess = str) : the call to grobj(z, 1, 1, arggrobj) does not work. arguments are x . > > funSSR(rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB) [1] 1 1 > > try(funSSR(rep(1, 2), rep(1, 2), grobj=function(x, i, j, arg) arg$x, compl=phiFB)) Error in grobj(z, i, j) : argument "arg" is missing, with no default Error when calling function, below the try output. [1] "Error in grobj(z, i, j) : argument \"arg\" is missing, with no default\n" attr(,"class") [1] "try-error" attr(,"condition") Arguments are: [[1]] [1] 1 1 [[2]] [1] 1 [[3]] [1] 1 [[4]] list() Error in testfunc(grobjfinal, z, arg = arggrobj, echo = echo, errmess = str) : the call to grobj(z, 1, 1, arggrobj) does not work. arguments are x, i, j, arg . > > funSSR(rep(1, 2), rep(1, 2), grobj=function(x, i, j, arg) arg$x, arggrobj=list(x=1), compl=phiFB) [1] 1 1 > > try(funSSR(rep(1, 2), rep(1, 2), rep(1, 3), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x) x)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : argument grconstr incompatible with constr. > > try(funSSR(rep(1, 2), rep(1, 2), rep(1, 3), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x) x, grconstr=function(x) 1)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : argument dimlam must be a vector of length 2 . > > try(funSSR(rep(1, 2), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x) x, grconstr=function(x) 1)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : SSR: incompatible dimension for dimlam, dimx, dimmu. > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x) x, grconstr=function(x) 1)) Error in constr(z, i) : unused argument (i) Error when calling function, below the try output. [1] "Error in constr(z, i) : unused argument (i)\n" attr(,"class") [1] "try-error" attr(,"condition") Arguments are: [[1]] [1] 1 1 1 1 [[2]] [1] 1 [[3]] list() Error in testfunc(constrfinal, z, arg = argconstr, echo = echo, errmess = str) : the call to constr(z, 1, argconstr) does not work. arguments are x . > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x) 1)) Error in grconstr(z, i, j) : unused arguments (i, j) Error when calling function, below the try output. [1] "Error in grconstr(z, i, j) : unused arguments (i, j)\n" attr(,"class") [1] "try-error" attr(,"condition") Arguments are: [[1]] [1] 1 1 1 1 [[2]] [1] 1 [[3]] [1] 1 [[4]] list() Error in testfunc(grconstrfinal, z, arg = arggrconstr, echo = echo, errmess = str) : the call to grconstr(z, 1, 1, arggrconstr) does not work. arguments are x . > > funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x, i, j) 1) [1] 2.000000 2.000000 1.414214 1.414214 > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i, arg) arg$x, grconstr=function(x, i, j) 1)) Error in constr(z, i) : argument "arg" is missing, with no default Error when calling function, below the try output. [1] "Error in constr(z, i) : argument \"arg\" is missing, with no default\n" attr(,"class") [1] "try-error" attr(,"condition") Arguments are: [[1]] [1] 1 1 1 1 [[2]] [1] 1 [[3]] list() Error in testfunc(constrfinal, z, arg = argconstr, echo = echo, errmess = str) : the call to constr(z, 1, argconstr) does not work. arguments are x, i, arg . > > funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i, arg) arg$x, argconstr=list(x=1), grconstr=function(x, i, j) 1) [1] 2.000000 2.000000 1.414214 1.414214 > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x, i, j, arg) arg$x, + arggrconstr=list(x=1))) [1] 2.000000 2.000000 1.414214 1.414214 > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x, i, j) 1, + joint=function(x) x)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : argument grjoint incompatible with joint. > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x, i, j) 1, + joint=function(x) x, grjoint=function(x) 1, dimmu=1:2)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : argument dimmu must be a vector of length 1. > > try(funSSR(rep(1, 4), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x, i, j) 1, + joint=function(x) x, grjoint=function(x) 1, dimmu=1)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : SSR: incompatible dimension for dimlam, dimx, dimmu. > > funSSR(rep(1, 5), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + constr=function(x, i) x, grconstr=function(x, i, j) 1, + joint=function(x) x, grjoint=function(x, j) 1, dimmu=1) [1] 3.000000 3.000000 1.414214 1.414214 1.414214 > > try(funSSR(rep(1, 5), rep(1, 2), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + joint=function(x) x, grjoint=function(x, j) 1, dimmu=1)) Error in testargfunSSR(z, dimx, dimlam, grobj, arggrobj, constr, argconstr, : SSR: incompatible dimension for dimlam, dimx, dimmu. > > funSSR(rep(1, 3), rep(1, 2), grobj=function(x, i, j) x, compl=phiFB, + joint=function(x) x, grjoint=function(x, j) 1, dimmu=1) [1] 2.000000 2.000000 1.414214 > > > > proc.time() user system elapsed 0.28 0.14 0.40