[R-meta] Adjust the scale for x-axis using forest() function in the metafor package

Thao Tran th@obr@wn @end|ng |rom gm@||@com
Wed Jun 17 10:03:51 CEST 2020


Thanks, Wolfgang.

I will play around with it to see if I can come up with things that I want
to do.
A big thank you for your great support.

Thao.

On Tue, Jun 16, 2020 at 11:47 AM Viechtbauer, Wolfgang (SP) <
wolfgang.viechtbauer using maastrichtuniversity.nl> wrote:

> Dear Thao,
>
> To be precise, you transformed the values shown on the x-axis back
> (through exponentiation) via the 'atransf' argument. Since exp() is a
> non-linear transformation, the spacing of the ticks will not be equidistant
> if the spacing on the log scale was equidistant to begin with (and
> vice-versa). Alternatively, you could use the 'transf' argument, which
> actually transforms all values back (not just the x-axis values that are
> shown). Then the spacing of the ticks will be equidistant (assuming that's
> how you specify the position of the ticks), but the CIs will no longer be
> symmetric (and appear to be of unequal widths even if the CIs are actually
> of equal width on the log scale). Compare:
>
> yi <- log(c(.8, 1, 1.2, 1.4))
> vi <- rep(.01, 4)
> forest(yi, vi)
> forest(yi, vi, atransf=exp, at=log(c(.5, 1, 1.5, 2)))
> forest(yi, vi, transf=exp, at=c(.5, 1, 1.5, 2))
>
> Best,
> Wolfgang
>
> >-----Original Message-----
> >From: R-sig-meta-analysis [mailto:
> r-sig-meta-analysis-bounces using r-project.org]
> >On Behalf Of Thao Tran
> >Sent: Tuesday, 16 June, 2020 10:06
> >To: Michael Dewey
> >Cc: r-sig-meta-analysis using r-project.org
> >Subject: Re: [R-meta] Adjust the scale for x-axis using forest() function
> in
> >the metafor package
> >
> >Hey Michael,
> >It is indeed a plot on the log-scale.
> >However, I did transform the values back to the original scale using
> >atransf = exp.
> >It is quite intuitive to see the 95% CI on the linear scale so the
> >variabilities of different studies can be seen clearly.
> >If you take a look at the plot above (in the previous email): the first
> >study had a very wide 95% CI (on the plot) although the values vary only
> >between 10 and 99.
> >The Roghmann study (fifth from the top) had a wide CI (from 400 to 1300)
> >but shows very short CI on the plot.
> >
> >Regards,
> >Thao
> >
> >On Mon, Jun 15, 2020 at 7:15 PM Michael Dewey <lists using dewey.myzen.co.uk>
> >wrote:
> >
> >> Dear Thao
> >>
> >> It is not wuite clear to me why you expect to see a linear scale on a
> >> plot using log values. I would suggest putting the ticks at places more
> >> evenly spaced on the log scale.
> >>
> >> Michael
> >>
> >> On 15/06/2020 16:32, Thao Tran wrote:
> >> > Dear,
> >> > I want to plot an rma object using the forest() function in the
> metafor
> >> > package.
> >> > Here is a reproducible code to run it (please see the attachment).
> >> >
> >> > axis.png
> >> >
> >> > The problem is the x-axis does not scale as I expected even I tried
> >> > using at = ...
> >> > I wanted to have the x-axis scale from 1, to 1000 but with equal
> >> > interval, for example, between (0, 1e2), (1e2, 2e2), (2e2, 3e2)...
> >> >
> >>
> 1-----100-----200-----300-----400-----500-----600-----700-----800-----900-
> >---1000
> >> > (something similar).
> >> >
> >> > Do you have any suggestions?
> >> > Regards
> >> > Thao
> >> > --
> >> > /Trần Mai Phương Thảo/
> >> > Master Student - Master of Statistics
> >> > Hasselt University - Belgium.
> >> > Email: Thaobrawn using gmail.com <mailto:Thaobrawn using gmail.com> /
> >> > maiphuongthao.tran using student.uhasselt.be
> >> > <mailto:maiphuongthao.tran using student.uhasselt.be>
> >> > Phone number: + 84 979 397 410+ 84 979 397 410/ 0032 488 0358430032
> 488
> >> > 035843
>


-- 
*Trần Mai Phương Thảo*
Master Student - Master of Statistics
Hasselt University - Belgium.
Email: Thaobrawn using gmail.com / maiphuongthao.tran using student.uhasselt.be
Phone number: + 84 979 397 410+ 84 979 397 410 / 0032 488 0358430032 488
035843

	[[alternative HTML version deleted]]



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