From maechler at stat.math.ethz.ch  Wed Apr 24 09:53:13 2013
From: maechler at stat.math.ethz.ch (Martin Maechler)
Date: Wed, 24 Apr 2013 09:53:13 +0200
Subject: [Rd] about the 'length' arg of vector()
In-Reply-To: <51771720.7020404@fhcrc.org>
References: <51771720.7020404@fhcrc.org>
Message-ID: <20855.36713.442488.260920@stat.math.ethz.ch>

>>>>> Herv? Pag?s <hpages at fhcrc.org>
>>>>>     on Tue, 23 Apr 2013 16:20:00 -0700 writes:

    > Hi, In the man page for vector():

    >    length: A non-negative integer specifying the desired
    > length.  Double values will be coerced to integer:
    > supplying an argument of length other than one is an
    > error.

    > Since long vectors are supported, it doesn't seem to be
    > true anymore that "double values will be coerced to
    > integer":

    >> bigraw <- vector("raw", 3e9) length(bigraw)
    >    [1] 3e+09
    >> storage.mode(length(bigraw))
    >    [1] "double"

    > At least not always...

Indeed.  Thank you, Herve!
Change committed to the documentation.

Martin Maechler,
ETH Zurich


    > Thanks, H.
    > -- 
    > Herv? Pag?s



[Rd] about the 'length' arg of vector()
Martin Maechler