Am 31.07.2018 um 21:35 schrieb Allin Cottrell:
On Thu, 26 Jul 2018, Sven Schreiber wrote:

Apart from that, what's the status of stuff like table 16.1 in the guide? It mentions "NA" for matrices instead of NaN, has this been wrong all along?

What's shown in Table 16.1 is correct: the NAs therein are the scalar return values from functions that take a matrix as argument (e.g. determinant), in case the matrix is empty.

OK, right, should have noticed that myself.

I'm noting that two paragraphs further down there appears this: " (All other matrix operations gen-
erate an error when an empty matrix is given as an argument.)" which basically contradicts the sentence which follows directly, enumerating more valid functions.
BTW, in this enumeration which is following the 'diagcat' function is missing it seems. I can edit the guide eventually (in a week or so), not right now.

Furthermore I wonder why the following functions couldn't also naturally return empty matrices when given an empty matrix as argument (but this is only for sake of consistency, not for a particular need):
- lower
- upper
- sort
- dsort
- mreverse
...possible also -but more complicated- those:
- mshape
- msortby
- trimr

cheers,
sven