Steps for estimating alpha in 1/f^alpha noise using OLS
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I have a signal (the vector "pink"), which I know is pink noise, 1/f^alfa, where alpha = 1. But let's assume alpha is unknown, and I need to estimate alpha. In other words, Let's assume I just have the signal.
I use the following procedure to get into a position to estimate alpha using OLS:
F = abs(fft(pink)); x = log(1:(length(pink)/2)); y = log(F(1:(length(pink)/2)));
Now I run OLS regression:
[r,m,b] = regression(x,y)
where I get
r = -0.5948, m = -0.4915, b = 6.8223.
I would have thought my estimate of alpha was m, but m is not equal to 1. So, what am I doing wrong? Is there an additional step I am forgetting, or is my procedure plain wrong?
Respuestas (1)
Nachiket Katakkar
el 1 de Jun. de 2017
The regression function is part of the Neural Network Toolbox:
The coefficient "m" is the slope of the curve between the inputs "x" and "y". The example on the documentation page shows a value of m equal to 1, however, this would not necessarily be the case for any regression problem.
Consider this example with random data:
>> pink = rand(1,100);
F = abs(fft(pink));
x = log(1:(length(pink)/2));
y = log(F(1:(length(pink)/2)));
[r,m,b] = regression(x,y)
r =
-0.3448
m =
-0.3469
b =
1.7326
You can visualize the relationship between "x" and 'y" using:
>> plotregression(x,y)
Also notice, that in your case the value of "b", the offset of regression is also quite high. The regression function seems to be working as expected, so I would recommend confirming that the algorithm you are using is correct.
0 comentarios
Ver también
Categorías
Más información sobre Linear Regression en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!