Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Rearranging order of subgroups on forest plot

    Hi all,

    I'm currently finishing up a systematic review, and one of the subgroups I'm interested in is grouping an intervention by cancer stage (early stage vs advanced stage).

    I've contructed a forestplot using the following code:
    Code:
    meta forestplot, subgroup (stage) eform(HR) nooverall
    Right now, I'm assuming STATA is grouping the subgroups in alphabetical order, so 'Advanced stage' appears on the top of the forest plot, with 'Early stage' below it. I would like to change this so the 'Early stage' group appears first in the forest plot. Does anyone have a solution to do this?

    Many thanks, Oliver

  • #2
    There is no data example provided, so my response will be based on what I think. If you want to order the subgraphs, one way could be to create a variable that maps the categorical variable defining the subgraphs to your desired order. Several community-contributed commands, such as myaxis and labmask, can be helpful for this purpose.

    Code:
    search myaxis
    search labmask

    Comment


    • #3
      Thank you Andrew Musau! myaxis fit the bill perfectly, so thanks for the suggestion! Thanks also to Nick Cox for the code/package

      Comment

      Working...
      X