[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
locating signal jumps
From: |
Pascal Dupuis |
Subject: |
locating signal jumps |
Date: |
Wed, 27 Jun 2007 16:09:25 +0200 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
Hello,
I have a signal wich is piecewise constant with a very small number of
random jumps. But the constant parts are themselve noised. I detect
the "true" jumps as follows:
1) compute a three points variance as
A=[1/3 -1/6 -1/6; -1/6 1/3 -1/6; -1/6 -1/6 1/3];
for indi = 2:length(u)-1,
var(indi, 1) = u(indi-1:indi+1).'*A*u(indi-1:indi+1);
end
2) define thresholding points:
th = round(length(var)*[.1 .25 .50 .75 .9]);
3) sort the variance vector
vars = sort(var);
4) compute sigma2 estimate:
sigma2 = [.211 .575 1.39 2.77 4.61]' \ (2*vars(th));
5) find the real jumps:
indtv= find(var > 10.6*sigma2);
The explanation is that 2*var is the sum of squared random variables
whose expectation is 1/sigma2: it is chisquare, 2 degrees of
freedom. The pairs (.1, .211) come from the Schaum tables. The
probability of having this estimator > 10.6 sigma2 is < .005.
So far so good but ...
1) A is not positive definite. Indeed, the variance of [1 1 1] is 0.
No factoring possible using chol().
2) It is very heavy from a computationnal point of view.
Do people know lighter algorithms ? Have Octave implementation of such
functions ?
TIA
Pascal Dupuis
--
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- locating signal jumps,
Pascal Dupuis <=