I have an experimental time response data of a system; stored in vectors. I need to plot the Frequency response function of the system using this data, so, I am trying to use "tfestimate" function for this purpose, but I am facing issues with the windowing process. Using the FRF the damping ratios of each mode needs to be calculated, so, the amplitude of the FRF is important. But the amplitude of the data is being changed everytime I change the "length of the Window"; I have been using Hanning Window.
In my code:
N = length(in);
n_window = N/20;
Where "in" is the input vector, so, "N" would be equal to the number of samples and "n_window" is the length if window.
[Txy_1,F_1] = tfestimate(in,out_1,hann(n_window),,N,fs);
In the attachments there are images of FRF when "n_window" was equal to "N", "N/20" and "N/40". From these images you could notice the change in the amplitudes with change in the length of the windows. And the image named "input" shows the leakage in the data collection.
So, I would like to know if there is some rule to be followed in choosing the window length or if this method is not a good one for my purpose.