|
Re: rebin (corrected): msg#00078python.numeric.general
Russell E Owen wrote: At 10:56 AM -0700 2004-08-30, Tim Hochberg wrote: I think you could probably do considerably better than the boxcar code, but it it looks like it would get fairly messy once you start worrying about odd number of bins. It might end up being simpler to implement it C, so that's probably a better idea in the long run. I personally have no strong opinion on averaging vs summing. Summing retains precision but risks overflow. Averaging potentially has the opposite advantages, though avoiding overflow is tricky. Note that Nadav Horesh's suggested solution (convolution with a mask of 1s instead of boxcar averaging) computed the sum. I really have no strong feelings since I have no use for rebinning at the moment. Back when I did, it would have been for rebinning data from particle detectors. So for instance, you would change the bin size so that you had enough data in each bin that you could attempt to do statistics on it or plot it or whatever. In that domain it would make no sense to average on rebinning. However, I can see how it makes sense for imaging applications. In the absence of any compelling reason to do otherwise, I imagine the thing to do is copy what every one else is doing as long as they're consistent. Do you know what Matlab and friends do? -tim ------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: rebin (corrected): 00078, Russell E Owen |
|---|---|
| Next by Date: | extracting a random subset of a vector: 00078, Curzio Basso |
| Previous by Thread: | Re: rebin (corrected)i: 00078, Russell E Owen |
| Next by Thread: | Re: rebin (corrected): 00078, Stephen Walton |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |