我一直在使用 Synth 包(它使用 optimx 进行优化),但我找不到 Synth 在不收敛时是否给出不收敛错误的答案。我可以在 optimx 的帮助文件中看到,默认情况下,它不会保存失败(即那些不收敛的答案),所以我猜测默认情况下它不会将这些失败传递给 Synth;但是,我想确保我得到的答案是一致的。有没有办法通过 convcode() 设置或其他方式来确定这一点?
问问题
356 次
1 回答
2
我看了一下代码,它没有设置控制值,所以它应该使用你已经知道的 whicho is FALSEsave.failures
的默认行为。以下是代码中optimx
的相关调用。optimx
synth()
rgV.optim.1 <- optimx(par = SV1, fn = fn.V, gr = NULL,
hess = NULL, method = optimxmethod, itnmax = NULL,
hessian = FALSE, control = list(kkt = FALSE, starttests = FALSE,
dowarn = FALSE, all.methods = all.methods), X0.scaled = X0.scaled,
X1.scaled = X1.scaled, Z0 = Z0, Z1 = Z1, quadopt = quadopt,
margin.ipop = Margin.ipop, sigf.ipop = Sigf.ipop,
bound.ipop = Bound.ipop)
....
rgV.optim.2 <- optimx(par = SV2, fn = fn.V, gr = NULL,
hess = NULL, method = optimxmethod, itnmax = NULL,
hessian = FALSE, control = list(kkt = FALSE,
starttests = FALSE, dowarn = FALSE, all.methods = all.methods),
X0.scaled = X0.scaled, X1.scaled = X1.scaled,
Z0 = Z0, Z1 = Z1, quadopt = quadopt, margin.ipop = Margin.ipop,
sigf.ipop = Sigf.ipop, bound.ipop = Bound.ipop)
于 2014-05-30T19:20:14.973 回答