Removing certain frequencies from data

Hello everyone,

I am collecting data from a load cell, but it is being corrupted due to an unfixable hardware issue.

The corruption comes in the form of turning the data into a baseline sine wave, but it still increases/decreases with force applied to the cell.

Is there a node I can use to detect the frequency of the sine wave and flatten the data to just the useful stuff?

Thanks in advance for your help,

You could try importing pitchfinder in a function node and use it to detect the frequency. Never tried!

Do you mean you want to smooth the data so that it shows the average of the sine wave? If so then possibly node-red-node-smooth will help.

Hi Colin,

I want to smooth out the general noise so i will, but there is an around 10second sine wave along all of the data. When there are spikes of force this just gets added to the sine wave, as if it is a baseline. therefore i would just like to remove the sine wave and bring it back to the data it should be .

That is incredibly difficult to do, it is just down to the maths, not a node-red problem. If you know exactly the frequency of the signal you might be able to us some sort of notch filter, but I don't hold out much hope of success.
Is the frequency of the sine wave known exactly, and constant? Is it of constant amplitude? If so then you might be able to use a generated compensation signal to subtract from the data. Alternatively you could record significant periods and then analyse the data retrospectively to determine the sine wave parameters and then subtract it. It is a pretty complex data analyses problem, that is above my maths knowledge. I think you might have to consult an expert in such things if this is critical to you. As I said, the problem isn't how to do it in node-red, but how to do it at all.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.