ssociation of serum bilirubin may change over
time, we include an interaction of this time-varying covariate with a
natural cubic spline of time using function <code><a href="https://rdrr.io/r/splines/ns.html" class="external-link">ns()</a></code> from the
<strong>splines</strong> package. <strong>Important Note:</strong> For
this to work correctly, we need to explicitly specify the internal and
boundary knots for the B-splines basis, i.e., in the following example,
we set the internal knots at 3, 6, and 9 