Programming the statistical procedures from SAS

using proc mixed for meta-analysis

Reply
Occasional Contributor
Posts: 5

using proc mixed for meta-analysis

Dear all,

I am a beginner on SAS. Was asked to write a SAS program for meta-analysis. Learnt it can be done using Proc mixed. Currently stucked on how to get my forest plot and the tactics to arrive at the final analysis.

please correct me if I'm wrong;

proc mixed data= blood_pressure order=data method=reml;

class trial;

model theta= / cl solution outp=predicted;

random trial / solution gdata=blood_pressure;

repeated diag;

run;

many thanks;

ib.

Respected Advisor
Posts: 2,655

using proc mixed for meta-analysis

What is the variable "diag" in the repeated statement?  Since it is not included in the class statement, I must assume that it is a continuous variable that is unique for each record in the data set blood_pressure.  In order for this to be valid, the dataset must be sorted on "diag."

I also wonder that your input dataset and your G matrix dataset are identically named.  I suspect that this will lead to problems, as the gdata= option requires somewhat different formatting.

For further assistance, it would help if you posted any error or warning messages from the log.

Steve Denham

Occasional Contributor
Posts: 5

using proc mixed for meta-analysis

Hi steve, thanks for the reply. The sas code you saw there was gotten from the internet. I not really sure of it's correctness. I have been instructed to carry out a full  meta-analysis of a normally distributed data on sas, as well as to produce the forest plot(95% CI). Ordinarily, the CMA package is what I'm used to but the instruction was that i should use sas for the analysis. The data is of the form;

trial     mean_of_new_treat     stand_dev_of_new_treat     numb_on_new_treat     mean_of_placebo stand_dev_of_placebo     numb_on_placebo

1          5.7                                6.2                                     12                                    5.2                          6.3                       10

2          6.3                                5.6                                     120                                  7.5                          6.2                       122

3          6.9                                4.5                                      63                                   7.1                          4.3                       64

4          7.3                                5.4                                      58                                   7.5                          3.4                       56

Thanks

ib

Valued Guide
Valued Guide
Posts: 684

using proc mixed for meta-analysis

I see you are trying the approach originally proposed by Normand (1999), and repeated several places, including in the book Meta-Analysis of Controlled Clinical Trials. However, there is an easier way to do this, and this has been shown by several authors. Presumably, your GDATA file contains a variance term, known as the sampling variance, with a separate value for each study. These are held fixed in meta-analysis. (It is not clear that you defined the sampling variance properly). Only the among-study variance is estimated. But the Normand approach treats the among-study variance as the residual, where usually the residual should be the within-study variance (with a separate value for each study, held fixed). This all still works out correctly if all you want is the estimated expected effect size and its estimated standard error. But if you want BLUPs for each study, then you need additional post-model-fitting steps.

Here is a way to fit the same model that does not require a separate GDATA file. Assume that the variable wgt in the blood_pressure data file is the inverse of the sampling variance for each study. You can create it with wgt = 1/samplvar; statement in a data step. You must have this value from each trial in order to do this meta-analysis. Then use:

proc mixed data= blood_pressure order=data method=reml;

class trial;

weight wgt;

model theta= / cl solution outp=predicted;

random trial ;

parms (1) (1) / hold=2;

estimate 'exp.effect size' int 1 / cl;

run;

The combination of the weight and the parms statements gives the required model. The parms statement gives initial guesses for the among-study and residual variance. The second variance parameter (residual) is held fixed at 1 (hold=2 means hold the second term at the value of 1). This, in combination with the weight statement, gives a separate sampling variance for each trial that is held fixed. (The output lists 1 for residual variance, but with the weight statement, one is really getting a separate residual for each trial. This will give the correct EBLUPs on the outp file.

There are several other, but more tedious, ways of getting idential results, using pdata= options on a repeated statement.

If you want to learn more, send me your email and I will send you an instruction file.

SAS Super FREQ
Posts: 3,547

using proc mixed for meta-analysis

Wow. Answers like this give me a warm feeling inside. On behalf of all of us who don't have as much experience, thanks to LVM and Steve and ALL of the SAS experts who spend considerable time to answer these technical forum questions!

Occasional Contributor
Posts: 5

using proc mixed for meta-analysis

Many thanks Ivm, will work on this sas code now. My email addy is - yemiabdulwasiu@ymail.com.

Thanks

ib

Occasional Contributor
Posts: 8

Re: using proc mixed for meta-analysis

Hi,

I've found your code very usefull for a meta analysis I'm doing. It gives great results, but I have to add references to complete may work.

You mentionned  in your post that there are several authors descibing the analysis that is in your code. Could you give me some references, so i will try to read and understand these papers.

Thanks a lot

Friedrich

PS : here is my mail  friedrich.rouffineau@adisseo.com

Ask a Question
Discussion stats
  • 6 replies
  • 3200 views
  • 2 likes
  • 5 in conversation