makeUnit | R Documentation |
makeUnit generates a unit matrix but includes the facility to alter the diagonal value away from 1.0 if desired.
makeUnit(N, diagvalue = 1)
N |
the order of the matrix |
diagvalue |
defaults to 1.0, but otherwise can be a different constant or a vector of dimension N |
a square matrix defaulting to a unit matrix
## Not run:
makeUnit(4)
surv <- exp(-0.2)
makeUnit(4,surv)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.