Hi Statalist,
I am wondering if there is a more efficient way to create a subgroup analysis figure that looks like this (Figure 2 from Leon MB et al. N Engl J Med 2010;363:1597-1607.)
My first question is how to generate the "TAVI" and "Srandard therapy" columns in the Figure efficiently. For example, with age as subgrouping variable, "28/96 (29.2)" means there are 28 positive events in the "TAVI==1 & age_85==1" sample and the event rate is 29.2%. Theoretically I could use
to produce the results and copy and paste, but that seemed too laborious, especially when there is a number of subgrouping variables. So is there a more efficient way that I can generate these columns in the same or similar format as the attached Figure?
My second question is what would be the best solution to produce the entire attached figure in Stata? Because with -coefplot- we could generate the forest plot part and with -metan- maybe include more columns of data but both required a lot of work to adjust the plot afterwards. I also tried to use a combination of -twoway rcap- and -twoway scatter- as suggested by https://blog.uvm.edu/tbplante/2018/0...gure-in-stata/ , but it can only provide forest plot part.
I have access to Stata version 15 and 17 so solutions to both Stata versions are welcome. I did try to use the -collect- command in Stata 17 to produce customized table but not successful.

Thanks in advance!
Ginny Han
I am wondering if there is a more efficient way to create a subgroup analysis figure that looks like this (Figure 2 from Leon MB et al. N Engl J Med 2010;363:1597-1607.)
My first question is how to generate the "TAVI" and "Srandard therapy" columns in the Figure efficiently. For example, with age as subgrouping variable, "28/96 (29.2)" means there are 28 positive events in the "TAVI==1 & age_85==1" sample and the event rate is 29.2%. Theoretically I could use
Code:
by TAVI age_85 : tab event
My second question is what would be the best solution to produce the entire attached figure in Stata? Because with -coefplot- we could generate the forest plot part and with -metan- maybe include more columns of data but both required a lot of work to adjust the plot afterwards. I also tried to use a combination of -twoway rcap- and -twoway scatter- as suggested by https://blog.uvm.edu/tbplante/2018/0...gure-in-stata/ , but it can only provide forest plot part.
I have access to Stata version 15 and 17 so solutions to both Stata versions are welcome. I did try to use the -collect- command in Stata 17 to produce customized table but not successful.
Thanks in advance!
Ginny Han