From Martin Maechler <maechler@stat.math.ethz.ch>  Sat Apr 11 09:56:16 1998
From: Martin Maechler <maechler@stat.math.ethz.ch> (Martin Maechler)
Date: Sat, 11 Apr 1998 10:56:16 +0200
Subject: 0-extent matrices?
In-Reply-To: <Pine.SUN.3.95.980409091945.15125A-100000@chekov> (message from
 Thomas Lumley on Thu, 9 Apr 1998 09:27:47 -0700 (PDT))
Message-ID: <199804110856.KAA00986@sophie.ethz.ch>

>>>>> "TL" == Thomas Lumley <thomas@biostat.washington.edu> writes:

    TL> Is there a good reason not to allow matrix extents to be zero? 

No, I don't think so.

And I agree that it would be really useful to have them in circumstances
like yours.

    TL> I have been writing a function which fits glms under certain linear
    TL> constraints.  I fit the model with a reduced set of variables and
    TL> then transform back to the original set.  This involves operating
    TL> on submatrices of the covariance matrix and subsets of the
    TL> coefficients. Sometimes these subsets are empty.  A zero-length
    TL> subset of the coefficient vector causes no problems, but a 0x6
    TL> submatrix of the covariance matrix won't work with rbind and cbind.
    TL> There appears to be no difficulty in deciding how standard matrix
    TL> and array operations should work with a 0x6 matrix and in fact you
    TL> might expect that the same C code would usually work.

Could you look into implementing them? 

Martin
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


0-extent matrices?
Martin Maechler