Skip to content

Subset of a 'table' divided by a 'table' is a 'table', but printed by 'print.default'

2 messages · Barry Rowlingson, Duncan Murdoch

#
On Tue, Apr 30, 2013 at 10:49 AM, Duncan Murdoch
<murdoch.duncan at gmail.com> wrote:

            
Also happens with *, if LHS is not a scalar:

 > c(1,1)*table(x)
x
A B
2 2
attr(,"class")
[1] "table"

 > 1*table(x)
x
A B
2 2

 - similar with + and -, but not unary + and -.

 Nice to see a bug in arithmetic operators that isn't covered by
everyone screaming "FAQ 7.31!!!"

Barry
#
On 13-04-30 6:51 AM, Barry Rowlingson wrote:
Yes :-).

I will fix it.

Duncan Murdoch