Ok so i have ran a mata analysis odds ratio and created a forest plot,i have what i need on the graph but i just need to change the study names. for example they show up as 1,2,3,4,5 . How can i change the numbers to medical , dental, specialty etc.
i have looked everywhere but the examples i keep seeing are on STATA 16 so its not working for me
Any help would be greatly appreciated
. metan lnor lnlci lnuci, eform effect (OR)type
Study | ES [95% Conf. Interval] % Weight
---------------------+---------------------------------------------------
1 | 0.510 0.440 0.590 30.63
2 | 0.710 0.610 0.810 32.77
3 | 4.020 3.100 5.200 9.85
4 | 1.920 1.560 2.340 16.03
5 | 1.720 1.340 2.200 10.72
---------------------+---------------------------------------------------
I-V pooled ES | 0.981 0.905 1.064 100.00
---------------------+---------------------------------------------------
this is the code i used
ssc install metan
set obs 5
gen or=0
gen lci=0
gen uci=0
edit
replace or=0.51 in 1/1
replace or=0.71 in 2/2
replace or=4.02 in 3/3
replace or=1.92 in 4/4
replace or=1.72 in 5/5
replace lci=0.44 in 1/1
replace lci=0.61 in 2/2
replace lci=3.1 in 3/3
replace lci=1.56 in 4/4
replace lci=1.34 in 5/5
replace uci=0.59 in 1/1
replace uci=0.81 in 2/2
replace uci=5.2 in 3/3
replace uci=2.34 in 4/4
replace uci=2.2 in 5/5
gen lnor= ln(or)
gen lnlci= ln(lci)
gen lnuci= ln(uci)
metan lnor lnlci lnuci, eform effect (OR)
Related Posts with Changing variable names on a forest plot STATA 15.1
How to reduce the size of large data files in Stata?I have a dataset on "effects of marijuana on mental health" and it has 9 lac observations. Now I ass…
command lasso is unrecognizedDear all I am trying to run the following lasso command: lasso linear outcome $controls, rseed(123…
Interaction Effect versus Sub-Group AnalysisHello, I have a basic modelling question related to an analysis I am running using STATA. I do real…
Export results for Markov-switching ARGood afternoon, I'm doing a few Markov-switching AR models and needed to store the results, prefera…
identify data pattern.Dear All, The question is from here (in Chinese). Suppose the data set is Code: * Example generated…
Subscribe to:
Post Comments (Atom)
0 Response to Changing variable names on a forest plot STATA 15.1
Post a Comment