Skip to content
Prev 51535 / 63421 Next

Apparent bug in summary.data.frame() with columns of Date class and NA's present

Thanks Marc,

It used to be the case that the NA count was stored as a 7th element of the Fivenum+mean summary. This had the side effect that the NAs were displayed using the same format as the other numbers, which was sort of OK for numerics (3.00) but not for class Date (1970-01-04 for three missings???), so Date objects didn't display the NA count at all. This got straightened out at some point, but apparently there's a residual. It could well be that the reason is that we still have
[1] 6
[1] 6

whereas other numerics get one element longer in case of NAs
[1] 6
[1] 7

but probably the person who fixed it the last time (can't figure out who that was at the moment) need to have a look.
  
-pd