Solved! Go to Solution.
This quick patch is far from perfect, but it gives you a place to start.
If I understand, you want to execute this sheet for 400 different files. You can do this in Mathcad, but it would be far easier in MatLab.
You can write a program in Mathcad to combine your operations, this would take the raw file and return the array S:
You would need to write a second function to finish the task (or add to this one.)
Then an array of 400 file names, and a program that executes a loop that reads each file, calls the function above, and writes out a file with your results.
Not simple.
This quick patch is far from perfect, but it gives you a place to start.