# Fitting nonlinear meta regression models to data

I have a collection of data, obtained from different studies. To plot the ratio of means against different CO2 concentrations, I used a random effects model with a continues predictor (the CO2 concentrations given in ppm).

I also did a meta-regression, by assigning co2 values in to three groups (High co2, medium co2 and low co2). The ratio of means was the highest for the "low co2" group and the lowest for the "medium co2" group. The response is clearly not linear.

How could one fit various non linear models do the date, and test how well they fit the data? A very nice tutorial on fitting a quadratic polynomial model to the data exits. Is the best way to just try different polynoms and see which model result gets the highest p value?

dat<- read.csv(file="C:/data.csv",head=TRUE,sep=",")
library(metafor)

dat<- escalc(measure="ROM", m1i = mean_t, m2i = mean_c, sd1i = sd_t, sd2i = sd_c, n1i = n, n2i = n, data = dat)
metaa<- rma(yi, vi, method="DL", data=dat, mods=cbind(ppm))

wi <- 1/sqrt(dat$vi) size <- 0.5 + 3.0 * (wi - min(wi))/(max(wi) - min(wi)) plot(dat$ppm, exp(dat$yi), pch=19, cex=size, xlab="PPM", ylab="Reaction rate",las=1, bty="l", log="y") preds <- predict(metaa, newmods=c(540:740), transf=exp) lines(540:740, preds$pred)
lines(540:740, preds$ci.lb, lty="dashed") lines(540:740, preds$ci.ub, lty="dashed")


The data:

   number mean_c mean_t   sd_c   sd_t  n ppm
1       1  36.85  48.61  28.40  24.54 20 700
2       2  31.36  29.01  16.83  21.04 20 700
3       8  29.00  35.00   3.03   3.03  4 700
4       9  26.12  41.05   7.50   4.14 12 700
5      13  38.20  34.90   9.68  11.23 15 550
6      14  38.20  36.30   9.68  12.01 15 550
7      15  21.00  55.20  12.07   8.05 20 550
8      16  62.00  62.00   9.80   9.80  6 700
9      17  53.00  53.00   7.35   9.80  6 700
10     18  76.00  63.00   7.35  17.15  6 700
11     23 258.00 249.00 101.19 199.22 10 700
12     24  12.00  23.75   6.48   6.48  8 560
13     25  11.25  20.63   6.48   6.48  8 560
14     26  17.63  25.75   6.48   6.48  8 560
15     27  16.38  19.00   6.48   6.48  8 560
16     46 360.00 360.00 200.92 259.81 12 600
17     47 170.00 234.00  90.07  62.35 12 600
18     48 228.00 284.00  38.11 131.64 12 600
19     49 260.00 340.00 263.27 443.41 12 600
20     50  75.00 147.00  65.82 110.85 12 600
21     51 138.00 240.00 110.85 242.49 12 600
22     52  94.00 157.00 110.85 138.56 12 600
23     82 154.00 154.00  90.07  31.18 12 540
24     83 156.00 329.00 110.85  76.21 12 540
25     84 163.00 293.00 100.46  45.03 12 540
26     94 376.00 418.00 148.63 132.82 10 740
27     95  29.00  36.00  41.11  82.22 10 740
28     96 188.00 403.00 117.00  94.87 10 740
29     97 121.30 207.80  34.47  43.64 10 700
30     98 278.30 146.20  82.54  25.93 10 700
31    120 212.00 226.00 153.36 169.79 30 700
32    121 568.00 663.00  83.14 121.24 12 550
33    122 677.00 648.00 131.64 173.21 12 550
34    123 279.00 449.00 117.00 154.95 10 730
35    124 266.00 352.00 139.14 211.87 10 730
36    125  51.66  53.94  52.81  40.49  8 700
37    126  44.81  44.19  66.90  61.03  8 700
38    127  14.56  21.10  26.76  17.60  8 700


• I would do exactly what has been explained in the link you gave. But don't make decision based on the highest p-value. Everything that is significant should be add to the polynom. Does this make sense to you ? Jul 2, 2015 at 13:00