[R-meta] stepadj argument ignored in an rma.mv model

Danka Puric dj@gu@rd @end|ng |rom gm@||@com
Tue May 7 20:59:22 CEST 2019


Dear Wolfgang,

yes, you are correct, I was using Rstudio. Profiling in basic R resulted in
this message:
Profiling sigma2 = 1
...
|=========================================================================================================================|
100%
Error in plot.window(...) : need finite 'ylim' values
In addition: Warning messages:
1: In min(x) : no non-missing arguments to min; returning Inf
2: In max(x) : no non-missing arguments to max; returning -Inf

Again, this is similar to what I get when plotting over single variance
components.

I have installed the developer version of metafor, fitted the model again
and plotted the variance components, but unfortunately I haven't noticed
anything different (the model vaues are the same as well as the profile()
warning messages).

Finally, here is the model I'm fitting as well as the full output:

> es.re.mv <- rma.mv(ES_corrected, SV, random = list(~ 1 | MA_data$IDeffect,
+                                                      ~ MA_data$DV |
MA_data$IDsubsample,
+                                                      ~
MA_data$IDsubsample | MA_data$IDstudy),
+                      struct="CS", data=MA_data,
control=list(optimizer="optim", optmethod="Nelder-Mead"))
> es.re.mv

Multivariate Meta-Analysis Model (k = 70; method: REML)

Variance Components:

            estim    sqrt  nlvls  fixed            factor
sigma^2    0.0000  0.0000     70     no  MA_data$IDeffect

outer factor: MA_data$IDsubsample (nlvls = 55)
inner factor: MA_data$DV          (nlvls = 5)

            estim    sqrt  fixed
tau^2      0.0843  0.2903     no
rho        1.0000             no

outer factor: MA_data$IDstudy     (nlvls = 16)
inner factor: MA_data$IDsubsample (nlvls = 55)

            estim    sqrt  fixed
gamma^2    0.0000  0.0002     no
phi        1.0000             no

Test for Heterogeneity:
Q(df = 69) = 312.8672, p-val < .0001


Another huge thank you!
Danka

On Tue, May 7, 2019 at 8:14 PM Viechtbauer, Wolfgang (SP) <
wolfgang.viechtbauer using maastrichtuniversity.nl> wrote:

> Dear Danka,
>
> The "Error in plot.new() : figure margins too large" message has nothing
> to do with metafor. I would guess you are using Rstudio and the plotting
> pane is too small.
>
> As for the rest, it's difficult to say what is going on. To start, make
> sure you first install the 'devel' version of metafor:
>
> https://wviechtb.github.io/metafor/#installation
>
> Maybe that already takes care of some of these issues. Could you also post
> the command you used to fit model 'es.re.mv' and the output from that
> model?
>
> Best,
> Wolfgang
>
> -----Original Message-----
> From: Danka Puric [mailto:djaguard using gmail.com]
> Sent: Tuesday, 07 May, 2019 19:38
> To: Viechtbauer, Wolfgang (SP)
> Cc: r-sig-meta-analysis using r-project.org
> Subject: Re: [R-meta] stepadj argument ignored in an rma.mv model
>
> Dear Wolfgang,
>
> Thank you so much for this quick reply! I needed to do some reading before
> I could respond. I'm quite new to nested models, so I'm still trying to
> wrap my head around them.
>
> I tried changing the optimizer to BFGS and Nelder-Mead and the latter
> resulted in model convergence (the former didn't). Problem solved! Well,
> partly - some of the variance component estimates in the model, namely
> sigma2 and gamma2, are zero.
>
> Moreover, when I run profile() on this model I'm getting the following
> message:
> Profiling sigma2 = 1
>  |==========================================================================================|
> 100%
> Error in plot.new() : figure margins too large
> In addition: Warning messages:
> 1: In min(x) : no non-missing arguments to min; returning Inf
> 2: In max(x) : no non-missing arguments to max; returning -Inf
>
> When I tried plotting just over tau2 and rho (like in the example on the
> profile.rma.mv help page), I got similar messages:
> > profile(es.re.mv, tau2=1)
> |==========================================================================================|
> 100%
> Error in plot.window(...) : need finite 'ylim' values
> In addition: Warning messages:
> 1: In min(x) : no non-missing arguments to min; returning Inf
> 2: In max(x) : no non-missing arguments to max; returning -Inf
> > profile(es.re.mv, tau2=2)
> Error in profile.rma.mv(es.re.mv, tau2 = 2) :
>   No such 'tau2' component in the model.
> > profile(es.re.mv, rho=1, xlim=c(.90, .98))
>  |==========================================================================================|
> 100%
> Error in plot.window(...) : need finite 'ylim' values
> In addition: Warning messages:
> 1: In min(x) : no non-missing arguments to min; returning Inf
> 2: In max(x) : no non-missing arguments to max; returning -Inf
>
> I would assume that this means (at least some of) the variance components
> are actually not identified. Is that the case? And does that mean that I
> should probably try fitting a different model?
>
> Thanks a lot for your help!
> Best,
> Danka
>
> On Tue, May 7, 2019 at 8:08 AM Viechtbauer, Wolfgang (SP) <
> wolfgang.viechtbauer using maastrichtuniversity.nl> wrote:
> Dear Danka,
>
> rma.uni() and rma.mv() use different optimization routines. The link you
> sent mostly pertains to rma.uni(). For one thing, the optimizers used in
> rma.mv() do not have a 'stepadj' control argument (which is also what the
> warning message is telling you).
>
> If you run into convergence problems with rma.mv(), first take a look at
> help(rma.mv) and the "Note" section towards the end. One of the first
> things you can try is to switch to 'optim' for the optimizer and then use
> either the 'BFGS' or 'Nelder-Mead' methods. So:
>
> control=list(optimizer="optim", optmethod="BFGS")
>
> or
>
> control=list(optimizer="optim", optmethod="Nelder-Mead")
>
> Maybe that already fixes things. If so, please also run profile() on the
> fitted model to make sure that all variance components are clearly
> identiable. See help(profile.rma.mv).
>
> Best,
> Wolfgang
>
> -----Original Message-----
> From: R-sig-meta-analysis [mailto:
> r-sig-meta-analysis-bounces using r-project.org] On Behalf Of Danka Puric
> Sent: Monday, 06 May, 2019 12:28
> To: r-sig-meta-analysis using r-project.org
> Subject: [R-meta] stepadj argument ignored in an rma.mv model
>
> Hi everyone!
>
> I'm running a meta-analysis using the rma.mv function and have run into
> some issues with the stepadj argument.
>
> One of the models I'm testing won't converge, with the following message:
> Error in rma.mv(ES_corrected, SV, random = list(~1 | MA_data$IDeffect,  :
>   Optimizer (nlminb) did not achieve convergence (convergence = 1).
>
> Following the advice on this page:
>
> http://www.metafor-project.org/doku.php/tips:convergence_problems_rma?s[]=convergence
> I tried increasing the number of iterations (up to maxiter = 10000), but
> the model wouldn't converge. I then tried shortening the step length to
> stepadj = 0.5. The model still failed to converge, but I also got the
> following message:
> Warning message:
> In nlminb(start = c(con$sigma2.init, con$tau2.init, con$rho.init,  :
>   unrecognized control elements named ‘stepadj’ ignored
>
> I get the same message when I try to adjust step length for models that do
> converge, so I'm hopeful that this model would also converge if only I
> could get the stepadj to work.
>
> Has anyone else had this issue when using stepadj with the rma.mv
> function?
> Any input would be greatly appreciated. Thank you in advance!
>
> Best,
> Danka
>

	[[alternative HTML version deleted]]



More information about the R-sig-meta-analysis mailing list