comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Inconsistent Mean Calculation
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Inconsistent Mean Calculation [message #30837 is a reply to message #30836] Mon, 20 May 2002 18:59 Go to previous message
Kenneth P. Bowman is currently offline  Kenneth P. Bowman
Messages: 585
Registered: May 2000
Senior Member
In article <a3589d11.0205201557.1a92499f@posting.google.com>,
plmcelwee@yahoo.com (Phil) wrote:

> I have 5000 frames of video in a NetCDF file, and I want to calculate
> the average of frame 2557. I have read the video file into both IDL
> v5.1 and
> Matlab v6.1. Additionally I have extracted frame 2557 and copied it
> into Excel. Here are the mean calculations I get for this frame:
>
> Matlab: 4092.6805
> Excel: 4092.6805
> IDL: 4093.6165
>
> Can anyone offer any suggestions as to why the IDL calculation is
> different? Maybe there is a bug in IDL 5.1? Yeah I know it's a
> really old version. :)

Excel is doing the calculation in double precision; Matlab probably
likewise. Try TOTAL(image, /DOUBLE)/n or MOMENTS(image, /DOUBLE) in IDL
and let us know what you get.

5.1 is really old? Oh, maybe it's me that's really old.

Ken
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: Is there no NULL in IDL??
Next Topic: Re: "bootstrap" statistics

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:26:22 PDT 2025

Total time taken to generate the page: 0.00407 seconds