ss="sourceLine" id="cb6-27" data-line-number="27"><span class="co"># betas &lt;- coefficients(fit)</span></a>
<a class="sourceLine" id="cb6-28" data-line-number="28"><span class="co"># exposed &lt;- exp(-predict(fit, expose.cov, type = &quot;link&quot;))</span></a>
<a class="sourceLine" id="cb6-29" data-line-number="29"><span class="co"># unexposed &lt;- exp(-predict(fit, unexpose.cov, type = &quot;link&quot;))</span></a>
<a class="sourceLine" id="cb6-30" data-line-number="30"><span class="co"># RR &lt;- (1