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

Home » Public Forums » archive » Re: percentile with dimension keyword
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: percentile with dimension keyword [message #76977 is a reply to message #76975] Wed, 20 July 2011 07:03 Go to previous messageGo to previous message
ben.bighair is currently offline  ben.bighair
Messages: 221
Registered: April 2007
Senior Member
On 7/20/11 12:53 AM, JP wrote:
> thanks,
>
> What I am after is a function that could be used in an array with 3 dimensions.
> like:
>
> array = Lindgen(1000,1000,100)
> median_array = MEDIAN(array, dimension=3)
>
> the result will be a 2d array of 1000x1000
>
> something like that but for any percentile (the example abobe would give the 50th percentile)
>
> thanks
>
> JP

Hi again,

I think you could use the PERCENTILE function (provided by Kim) or some
variant of it with Craig Markwardt's CMAPPLY function. CMAPPLY accepts
a user defined function name as the operation and the dimension over
which to apply the operation. You can find it here...

http://www.physics.wisc.edu/~craigm/idl/down/cmapply.pro


Something along the lines of (untested) ...

r = CMAPPLY("USER:PERCENTILE", data, 3, functargs = {PERCENT: 95})


Cheers,
Ben
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: MIP from BMP Images
Next Topic: Re: cgSnaphot doesn't detect currently open windows

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

Current Time: Fri Oct 10 16:29:17 PDT 2025

Total time taken to generate the page: 0.16304 seconds