From maechler at stat.math.ethz.ch  Thu Mar 13 18:00:08 2003
From: maechler at stat.math.ethz.ch (maechler@stat.math.ethz.ch)
Date: Thu Mar 13 18:00:24 2003
Subject: [Rd] 'summary' with logicals (PR#2629)
Message-ID: <200303131700.h2DH08n9001838@pubhealth.ku.dk>

>>>>> "GB" == Gran Brostrm <gb@stat.umu.se>
>>>>>     on Wed, 12 Mar 2003 23:32:16 +0100 (MET) writes:

    GB> Consider
    >> oj <- data.frame(x = c(TRUE, FALSE, NA))
    >> oj
    GB> x
    GB> 1  TRUE
    GB> 2 FALSE
    GB> 3    NA
    >> summary(oj)
    GB> x          
    GB> Mode :logical  
    GB> FALSE:1        
    GB> TRUE :1        

    GB> But

    >> oj$x <- factor(oj$x)
    >> summary(oj)
    GB> x    
    GB> FALSE:1  
    GB> TRUE :1  
    GB> NA's :1  

    GB> My point is that NA's should be reported for logicals like they are for 
    GB> other data types.

Agreed.
I'll look into making this happen for 1.7.0
Martin

    GB> Gran
    GB> ---
    GB> Gran Brostrm                    tel: +46 90 786 5223
    GB> Department of Statistics          fax: +46 90 786 6614
    GB> Ume University                   http://www.stat.umu.se/egna/gb/
    GB> SE-90187 Ume, Sweden             e-mail: gb@stat.umu.se

Martin Maechler <maechler@stat.math.ethz.ch>	http://stat.ethz.ch/~maechler/
Seminar fuer Statistik, ETH-Zentrum  LEO C16	Leonhardstr. 27
ETH (Federal Inst. Technology)	8092 Zurich	SWITZERLAND
phone: x-41-1-632-3408		fax: ...-1228			<><


[Rd] 'summary' with logicals (PR#2629)
maechler@stat.math.ethz.ch