guido-s / meta

Official Git repository of R package meta
http://cran.r-project.org/web/packages/meta/index.html
GNU General Public License v2.0
82 stars 32 forks source link

Fixed and random effect models for specified subgroups #43

Closed DaveCurta closed 2 years ago

DaveCurta commented 2 years ago

I'm working on a forest plot with subgroups, but in some cases my subgroups consist of a single study. In this case I don't want to display the FE/RE models for this subgroup as it doesn't add anything of interest to the plot.

Is it possible to functionality to print FE/RE models for only specified subgroups? I'm imagining passing a vector of TRUE/FALSE to the subgroup parameter rather than a single logical value.

Thanks for maintaining the package!

guido-s commented 2 years ago

Thank you for this suggestion. It is now possible to provide a logical vector for arguments 'subgroup', 'subgroup.hetstat' (new argument), 'prediction.subgroup' (new argument), 'test.effect.subgroup', 'test.effect.subgroup.fixed' and 'test.effect.subgroup.random'.

Furthermore, I changed the default, i.e., subgroup results are not shown for subgroups consisting of a single study. Argument subgroup = k.w >= 1 can be used to print results for all subgroups.

For more information, see help page of forest.meta, subsection "Flexible printing of subgroup results".

DaveCurta commented 2 years ago

Thank you!