[scilab-Users] Re: reducing timeseries dataset for later on linear interpolation
GOBILLOT Gilles 116128
gilles.gobillot at cea.fr
Fri Jun 1 13:28:02 CEST 2012
Hi David,
A simple way to under-sampling datas is :
Undersamplingfactor=4;
Dat_undersamp=dat(1: Undersamplingfactor:$);
But if datas are physical signals you will have an aliasing problem
(http://en.wikipedia.org/wiki/Nyquist%E2%80%93Shannon_sampling_theorem#Aliasing in English,
http://www-prima.imag.fr/Prima/jlc/Courses/2000/ENSI2.TS/ENSI2.TS.S5.pdf = in French)
So, in this case, you've to apply an anti-alisasing filter BEFORE the under-sampling.
Hope it will help you
Gilles
-----Message d'origine-----
De : CHEZE David 227480
Envoyé : jeudi 31 mai 2012 09:25
À : users at lists.scilab.org
Objet : [scilab-Users] Re: reducing timeseries dataset for later on linear interpolation
Hi,
I've done it that way:
dat=[0 0 1 3 2 2 0 0 0 0 2 4 2 4 4 2 0 0 0 0];
plot2d(dat)
datp=diff(dat);
datp_1=[datp(1) datp(1:$-1)];
k=find(datp<>datp_1)
datr=dat(k);
plot2d(k,datr)
i should have add the first point of dat in datr to have exactly the same curve but it works.
Is there a more direct and efficient way to do that in Scilab?
Thanks for your comment,
David
--
View this message in context: http://mailinglists.scilab.org/reducing-timeseries-dataset-for-later-on-linear-interpolation-tp4022470p4024263.html
Sent from the Scilab users - Mailing Lists Archives mailing list archive at Nabble.com.
--
To unsubscribe from this mailing-list, please send an empty mail to users-unsubscribe at lists.scilab.org
To check the archives of this mailing list, see http://mailinglists.scilab.org/
More information about the users
mailing list