<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Monaco;
panose-1:0 0 0 0 0 0 0 0 0 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle17
{mso-style-type:personal-compose;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:12.0pt;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style>
</head>
<body lang="EN-AU" link="#0563C1" vlink="#954F72" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">Hi there,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I am working on a meta-analyses looking at the effect of ocean warming on various traits of marine animals. My model is as follows:<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Traitcat_model <- rma.mv(yi = Ln_response_corrected, V = Variance, mods = ~LnSR:Trait_cat - 1, test="t", random = list(~1|Study_number/Response_id/Effect_size_id), method = "REML", data = Traitcatdata)<o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Ln_response_corrected is the lnRR, i.e. the natural logarithm of the difference between the experimental (high temperature) and control mean.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">Trait_cat is the measure e.g. survival, metabolic rate, growth. I have added in the an interaction with LnSR (the natural logarithm of the difference between the control and experimental temperature). I included
this to account for the fact that some studies might test say a control and +10C, while others may only test at +2C. The effect size id is the number of the observation, which is nested within response_id. All observations of one measure e.g. metabolic rate
at the different experimental temperatures tested in a study will have the same response Id. This is nested within the study number, which is the number assigned to each paper included.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Firstly, when I test the normality and heteroskedasticity of the model as a whole as well as the response variable, there is a high level on non-normality and heteroskedasticity (see attached screenshots for the
diagnostic plots of the model). I am not sure if this means that the model output cannot be trusted? Or if this level of non-normality and heteroskedasticity is ok?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">If not, I was thinking about bootstrapping the confidence intervals to account for the non-normality. However, I cannot seem to figure out the code to do this. This is the code that I tried, at the moment I am
getting the error: </span><span style="font-size:9.0pt;font-family:Monaco;color:#C800A4;background:#E5E5E5"><text>:1:6: unexpected symbol 1: .arg show_col_types ^</span><o:p></o:p></p>
<p class="MsoNormal"><span style="color:black">But I was getting a different error when I tried to run the code yesterday, I can’t remember what this one was.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">library(boot)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">boot.func <- function(dat, indices) {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> Traitcat_model2 <- try(suppressWarnings(rma.mv(yi=Ln_response_corrected,V=Variance, data=Traitcatdata, mods=~LnSR:Trait_cat - 1, test="t", random = list(~1|Study_number/Response_id/Effect_size_id), method =
"REML", subset=indices)))<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> if (inherits(Traitcat_model2, "try-error")) {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> NA<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> } else {<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> c(coef(Traitcat_model2), vcov(Traitcat_model2), Traitcat_model2$sigma2)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"> }<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">}<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">res.boot2 <- boot(Traitcatdata, boot.func, R=5000)<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black">res.boot2<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Please let me know how I need to adjust this code to get the bootstrapped CI’s for each Trait_cat group.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Also, would it be ok to use bootstrapped CI’s along with the estimates from the original model, or should I use bootstrapped estimates too?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Secondly, I am trying to figure out how to do an Orchard plot, which I know you cannot create from a model with two multiple moderators. I was wondering whether there is any way to back calculate from the model
to get data points that have been adjusted for LnSR, and then use them for the Orchard plots?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Please let me know if you need any further details in order to help me with these queries.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Best wishes,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:black"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:black">Bethan<o:p></o:p></span></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<div>
<div>
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:14.0pt;color:#A5A5A5">________________________________________<o:p></o:p></span></b></p>
<p class="MsoNormal"><b><span lang="EN-US" style="color:#ED7D31">Bethan Lang<o:p></o:p></span></b></p>
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt">PhD Candidate<o:p></o:p></span></b></p>
<p class="MsoNormal"><span style="font-size:10.0pt">ARC Centre of Excellence for Coral Reef Studies<br>
James Cook University<br>
Townsville, QLD, Australia <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt">4811<o:p></o:p></span></p>
<p class="MsoNormal"><img width="242" height="96" style="width:2.5208in;height:1.0in" id="Picture_x0020_1" src="cid:image001.jpg@01D7A88E.7ACAEA60" alt="signature_1249144060"><o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>