[18997] in s-news-athena

home help back first fref pref prev next nref lref last post

Re: [S] Variance calculation

daemon@ATHENA.MIT.EDU (Jonathan Monteleone)
Sat Aug 21 07:49:30 1999

Message-Id: <199908211138.XAA12647@smtp2.ihug.co.nz>
Date: Sat, 21 Aug 1999 23:40:06 +1200
To: s-news@wubios.wustl.edu
From: Jonathan Monteleone <monte@ihug.co.nz>
In-Reply-To: <6rvhacltsc.fsf@verdi.stat.wisc.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset="us-ascii"


Under S-PLUS 2000
> var(rep(0.182, 2))  
[1] 0
> var(rep(0.182, 3))  
[1] 0
> var(rep(0.182, 4))  
[1] 0

Under S-PLUS 3.3 for Windows
> var(rep(0.182, 2))  
[1] 7.70372e-34
> var(rep(0.182, 3))  
[1] 7.70372e-34
> var(rep(0.182, 4))  
[1] 7.70372e-34

Hope this helps
Cheers -Jon
At 03:26 PM 8/18/99 -0500, you wrote:
>
>Under S-PLUS 3.4 on a SPARC/Solaris system the following occurs
>> var(rep(0.182, 2))  # would expect 0
>[1] 7.70372e-34
>> var(rep(0.182, 3))
>[1] 7.70372e-34
>> var(rep(0.182, 4))
>[1] 7.70372e-34
>
>Under S-PLUS 5.1 on the same computer the answer is 0.
>
>For most calculations that difference would not be important but it
>happens that I am taking the logarithm of the variance and trying to
>screen out the replicated points by trapping on logarithms of -Inf.  I
>guess I will have to work out an alternative method of doing this
>calculation.
>
>If you test that calculation on your system, could you tell me if it
>produces a non-zero result.  I would be particularly interested in the
>results from S-PLUS 4.5 or S-PLUS 2000.
>-----------------------------------------------------------------------
>This message was distributed by s-news@wubios.wustl.edu.  To unsubscribe
>send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
>message:  unsubscribe s-news
> 
=================================================================
Mr Jonathan Monteleone (MS)
Department of Pharmacology & Clinical Pharmacology                  
School of Medicine and Health Sciences
University of Auckland
Auckland, New Zealand
Phone: +64.9.373.7599 ext. 6732  Fax: +64.9.373.7556
Home:  +64.9.529.1477
Email: monte@ihug.co.nz
-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu.  To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message:  unsubscribe s-news

home help back first fref pref prev next nref lref last post