Writing an R function that outputs maximum likelihood estimates?
<p>How would I write an R function that takes a response vec y and covariate matrix X and outputs a vector of maximum likelihood estimates of coefficients β where μ = Xβ And E[Y] = μ, where Y is an exponentially distributed random vector?</p>

<p>I can use the qr() and related functions, and need to program the iteratively reweighted least-squares algorithm from first principles using the QR decomposition.</p>