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

Home » Public Forums » archive » Re: Time series.
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: Time series. [message #80118 is a reply to message #80115] Tue, 01 May 2012 11:57 Go to previous messageGo to previous message
chris_torrence@NOSPAM is currently offline  chris_torrence@NOSPAM
Messages: 528
Registered: March 2007
Senior Member
On Monday, April 30, 2012 3:26:44 AM UTC-6, dave poreh wrote:
> On Monday, April 30, 2012 9:31:59 AM UTC+2, Mats Löfdahl wrote:
>> Den måndagen den 30:e april 2012 kl. 09:15:45 UTC+2 skrev dave poreh:
>>> Folks
>>> hi,
>>> I am doing some Time series analysis and i wish to plot the mean like ( http://imageshack.us/content_round.php?page=done&l=img20 7/6577/screenshotat20120430091.png). I mean i want to plot the *BLUE* points in this graph. i have tryed to do with:
>>> Smooth(y, 33)
>>>
>>> but the result is not what i want. Is there any help on Time series expert please?
>>> Cheers,
>>> Dave
>>
>> I think you want to bin your data and then plot the mean y value within each bin vs the mid x point.
> Thanks. Now i am thinking about: http://idlastro.gsfc.nasa.gov/idl_html_help/TS_SMOOTH.html
>
> Cheers,
> Dave :-)

Hi Dave,

At the risk of getting flamed, you can use the undocumented "NSUM" keyword to the PLOT function:

r = randomn(s,1000) + findgen(1000)/300
void = LINFIT(findgen(1000),r,YFIT=yfit)
p = plot(r, 'or', /SYM_FILLED, SYM_SIZE=0.5, NAME='Red data')
p1 = plot(r, 'ob', /SYM_FILLED, /OVERPLOT, NAME='Smoothed', nsum=20, /undoc)
p2 = plot(yfit, 'g3', /OVERPLOT, NAME='Linear fit')
l = legend(POSITION=[0.8,0.3])

In this case, setting NSUM=20 just does a simple average of every 20 points and only plots a single point. Here's what it looks like:
http://www.flickr.com/photos/79705059@N06/6986758828/

Cheers,
Chris
ExelisVIS
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Color problem.
Next Topic: strange behaviour of bytscl by large arrays

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

Current Time: Thu Oct 09 22:36:32 PDT 2025

Total time taken to generate the page: 0.87856 seconds