Re: meanclip [message #82316] |
Thu, 06 December 2012 08:15  |
wlandsman
Messages: 743 Registered: June 2000
|
Senior Member |
|
|
meanclip.pro, is not a standard IDL procedure but in the IDL Astronomy library ( http://idlastro.gsfc.nasa.gov/ftp/pro/math/meanclip.pro ).
As David said, you don't give enough information, but I am going to guess that
the first column in your array contains your X values, and the second column contains the Y values you want to plot. If true, then I would copy these into X and Y vectors to make it easier to keep track of things.
IDL> x = arr[*,0]
IDL> y = arr[*,1]
IDL> help,arr,x,y
ARR DOUBLE = Array[1439, 2]
X DOUBLE = Array[1439]
Y DOUBLE = Array[1439]
MEANCLIP is meant to take the mean of an array after iteratively removing outliers, but it also has a keyword to find "good" subscripts -- by default those values within 3 sigma of the mean.
IDL> meanclip,y,arrmean,subs=subs
IDL> help,subs
SUBS LONG = Array[1435]
So meanclip has thrown out 4 outliers. Now one can plot only the good data
IDL> cgplot, x[subs], y[subs]
--Wayne
On Thursday, December 6, 2012 6:13:48 AM UTC-5, Charlie Paul D'auria wrote:
> Hi everyone.
>
>
>
> I was just wondering if anyone can guide me in using meanclip.pro? I'm am an IDL beginner and the online documentation is sparse.. (I don't get it)
>
>
>
> I have a double array of 2 columns and 1439 rows.
>
>
>
> I'd like to use this program to clip data that is a certain amount of sigma away from the last value and then plot it. I am also using the Poly fit routine if this is relevant.
>
>
>
> Any help would be great appreciated!
>
>
>
> Charlie
|
|
|