Basically you can't with an Arduino. An FFT takes time to gather samples, process them, like windowing, and then display the results. While this is happening the continuous signal goes on happening. So basically this is a stop / start process.

To do this you would have to have something like a continuous FFT going and you sample phase involves just adding one sample to the FFT buffer and processing that. This in done by using a hardware, or rather a FPGA FFT implementation.

**However**, you can do other sorts of filtering on a continuous signal by using DSP (Digital Signal Processing) algorithms.

The whole subject is a bit maths heavy, But here are some links to get you started:-

Basic forms of filters

Basic Digital filters

Introduction to DSP

Basically what you do is to take the last n samples and apply a coefficient to each one. Sample n is the latest sample you take, sample n-1 is the sample before that and so on.

The filter's output is the sum of all the samples multiplied by the samples' coefficient Cn.

So you might have

output = Sn * Cn + Sn-1 * Cn-1 + S-2 * Cn-2

For a recursive filter some of these values in the polynomial can also include previous output values, like Out n-2 * CnOut n-2. If the output coefficients are not chosen correctly the filter can become unstable and the output will oscillate instead of passing the signal through the filter. But a recursive filter often gives better results with fewer calculations.

As you can see there are a lot of floating point multiplications and additions, so you need a powerful Arduino to to this. However, on a Uno you can implement simple filters with a few coefficients, and still use a reasonable sample speed.

This is a tool that takes in what sort of filter you would like to implement and gives you the signal weighting for each successive sample.

Filter Design tool

This is a plot from my book Arduino Music Where Chapter 16 is all about simple signal processing. It shows a signal in the plotter window. The first half of the plot shows the input signal which is a simple square wave. The last half of the plot shows the output of the filter which is a simple notch filter taking out the fundamental frequency of the input square wave and leaving all the other harmonics in the square wave.

Notice that the filter, like all digital filters, needs a little time to settle down before producing a continuous output, because at the start the older samples have not been gathered yet. Or are full of old values.