Originally posted by dloomis
The code at the link you posted was supposed (imho) to be actual efs code. If so, it has syntax errors and will not run.
Perhaps the author make a mistake and posted the wrong code, I don't know why code would be posted that has errors.
Anyway, Jason posted some code that was identified as Mel's method and I commented that code. They appear to be quite similar.
Here are my comments, hope they help.
The code at the link you posted was supposed (imho) to be actual efs code. If so, it has syntax errors and will not run.
Perhaps the author make a mistake and posted the wrong code, I don't know why code would be posted that has errors.
Anyway, Jason posted some code that was identified as Mel's method and I commented that code. They appear to be quite similar.
Here are my comments, hope they help.
Thanks for the comments. What I am asking in this thread is for someone to disect the actual coding from e-signal.txt /original mel's EFS that JasonK produced, and spit out the formula's that were used. Similar to the "documentary" type coding that I posted before. I AM NOT making an EFS, or editing this EFS to fit my needs. I just want to extract the formula's and what/how needs to be plotted. (again, like I posted below with this example:
***********************
Single Regression Line algorithm:
1. Going through the last N periods calculate:
SumX - sum of all X values
SumY - sum of all Y values
SumXY - sum of all XY
SumX2 - sum of all XX
2. B = (N*SumXY-SumX*SumY)/(N*SumX2+SumX*SumX)
A = (SumY-B*SumX)/N
3. Calculate standard deviation
Go through all N periods and for each calculate
F = Y-(X*B+A)
4. SumF = sum of all F*F from step 3
5. StD = SQRT(SumF/N)
Plot the lines:
Y=B*X+A for the central line
Y=B*X+A+W*StD for upper channel line (where W is the width of the
channel)
Y=B*X+A-W*StD for lower channel line (where W is the width of the
channel)
***********************
Comment