Skip to content
Prev 32798 / 63421 Next

edge case concerning NA in dim() (PR#13729)

On Fri, 29 May 2009, astokes at esica.com wrote:

            
The calculation was done in C and failed to take NAs (and indeed 
negative values) into account.  So
succeeded.

Thank you for the report, changed in R 2.9.0 patched.  (Since the 
representation of an integer NA is negative, a test for positivity 
would have caught this.)
In fact NA as used here is logical but is coerced to a numeric NA, and 
a 'missing' numeric could take any possible value including Inf, -Inf 
and NaN.