Rank: 281360 based on 0 downloads (last 30 days) and 0 file submitted
photo

Martin Wilkes

E-mail
Company/University
University of Worcester

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Comments and Ratings by Martin View all
Updated File Comments Rating
21 Feb 2012 Despiking This function remove spike noise from data. Author: Nobuhito Mori

Ignore previous post. I have now got this to work by installing the statistics toolbox. Results are rather worrying, however, as it is filtering out 100% of my data points even though WinADV rates were only ~5% using the same filter!

21 Feb 2012 Despiking This function remove spike noise from data. Author: Nobuhito Mori

I created my own nanmean function as suggested by Georg Stillfried above. I then tried running func_despike_phasespace3d and found I needed a nanstd function. I tried this:

function m = nanstd (x,dim)
if nargin<2, dim=1; end
nans = isnan(x);
x(nans) = 0;
sumx = sum(x,dim);
m = sqrt((sumx./sum(~nans))/sum(~nans));

...but now getting back:

Error using *
Inner matrix dimensions must agree.

Error in func_excludeoutlier_ellipsoid3d (line 97)
x2 = a*b*c*x1/sqrt((a*c*y1)^2+b^2*(c^2*x1^2+a^2*z1^2));

Error in func_despike_phasespace3d (line 101)
[xp,yp,zp,ip,coef] = func_excludeoutlier_ellipsoid3d(f,f_t,f_tt,theta);

...what have I done wrong?

Contact us