# Confidence Interval For Frequency of Peak in Averaged Periodogram?

I am averaging periodograms from sets of ~15-25 experimentally measured timeseries all of the same length. To do this I am just summing the power in each frequency bin over all periodograms and then dividing by the total power over all the periodograms (I believe this is similar to Welch's Method but here I have many timeseries instead of a single long timeseries).

In many of these averaged periodograms I see a distinct peak that is called as statistically significant by Fisher's G-test. What is a good way to get a confidence interval or other interval estimate (e.g. standard-error of the mean) for the frequency of this peak? Is there some method that takes into account both sample size and width of the peak (maybe width at half-max)?

Add note below to provide more detail:

These are real timeseries data from measurements of gene expression in cells (each timeseries is the gene expression in an individual cell sampled every 6 minutes for ~10 hrs). I have been averaging the individual periodograms to create an averaged periodogram (like Bartlett's method) and want to be able to determine two things:

i.) Is a power at a frequency in the averaged periodogram statistically significant (i.e. unlikely to be due to chance)? This is what I am currently using Fisher's G-Test for but if there are better methods I am open to trying those (provided I can understand them and they are relatively easy to use).

ii.) What is an interval estimate for the frequency of a statistically significant power in the averaged periodogram? The bin with the greatest power in these averaged periodograms is typically a "peak" (when a line is plotted connecting the power values across bins) with neighboring bins also showing some increased power relative to other parts of the periodogram.

• Can I please ask you to clarify the question a little bit? Specifically, the G-Test doesn't make much sense in this case. I started writing a response but it ended up being a justification of why not to use the G-Test and I am not sure how much this is correct in this case without knowing more about your application and specific data processing you have opted for (is there a paper for example)? If one assumes real time series, the G-Test doesn't make sense. There has to be quantisation in there somewhere.
– A_A
Mar 4, 2017 at 14:27
• @A_A I have added detail in the post about the data I am working with and what I am trying to get out of the averaged periodogram (statistically significant frequencies and an interval estimate for these frequencies since their neighboring frequency bins also show some increased power in them too). Mar 4, 2017 at 15:48
• Thank you very much. Last question: Have you generated your expected values for the G test or is there a model?
– A_A
Mar 4, 2017 at 16:18
• @A_A From the biology there is a frequency range that is of interest but so far I was just using G-test to say whether any bin shows power that is significant relative to white noise (analogous to lag thresholds in ACF and PACF above white noise). From data it is clear that my control condition shows significant peak at bins in expected frequency range but my experimental condition cells generally seem not to. If there's a good way to also test control condition averaged periodogram directly against experimental condition averaged periodogram that would be of interest too. Mar 4, 2017 at 16:45

I am averaging periodograms from sets of ~15-25 experimentally measured timeseries all of the same length. To do this I am just summing the power in each frequency bin over all periodograms and then dividing by the total power over all the periodograms...

So, for a given waveform, your time series dataset is $x_i$, where $i$ denotes the $i^{th}$ acquisition, let's call it $i \in [1 \ldots N_{acq}]$. You then derive the periodogram as $X_i = |\mathscr{F(x_i \otimes x_i)}|$. Now, for a given harmonic $k$, each of the $X_i[k], i \in [1 \ldots N_{acq}]$ gives you some point estimate for that $k^{th}$ harmonic.

Following this, what you do is to generate some $\bar{X} = \frac{1}{N_{acq}} \cdot \sum_{i=1}^{N_{acq}}X_i$. So, now, your $\bar{X}$ is the averaged periodogram.

As it seems, the next thing that you want to do is to answer the question "Is this periodogram obtained by chance or is there something in there?"

In many of these averaged periodograms I see a distinct peak that is called as statistically significant by Fisher's G-test.

OK, so, for this one, you need a test. You are going for the G-Test. The G-Test works over "counts". The value of the frequency bin would be represented as a random variable and we would be asking the question, does this look totally like noise OR is there a significant difference between the values of a frequency bin between experimental conditions (?).

So, the question here is, are your variables so much quantised as to be considered "categorical" and justify the use of the G-Test? (Probably not (?)).

The other point which is not entirely clear is "what" do you want to work on?

At the moment, given a $k^{th}$ harmonic, you work on a dataset of $N_{acq}$ values, which are indexed by $i$. But, what you seem to be wanting to do is work across the $k$s by locating "peaks".

So, the question here is, do you want to be able to say "Over so many experiments, the power of this particular harmonic is some $\bar{X}[k] \pm \sigma$" or do you want to say "Over so many experiments, the frequency is some $f_{critical} \pm \sigma$"?

If you want to work over the $i$s (given some $k$) and therefore make a statement on the validity of the harmonic itself: Assume that frequency bins are independent with each other and go for a "straightforward" t-test. This can either be 1-sample to work out significance or 2-sample to work out significance across two conditions. In using the t-test, you would also be assuming that the distribution of the $k^{th}$ harmonic is distributed normally, in which case you can also apply confidence intervals in the typical way.

If you want to work over the $k$'s, (having averaged in the "$i$ direction") and therefore make a statement on the frequency itself: Then, you cannot assume that the bins are independent with each other (which, they are not) and you would be seeking a model that describes $\bar{X}$ as a whole. One option could be kernel density estimation. Because it would explain $\bar{X}$ like $\hat{X} = \sum_{k=1}^{N_{kernels}} \mathcal{N(\mu_m,\sigma_m^2)}$, it would give you an estimate for the "bump" that is created by the frequency "lobe" at frequency $\mu_m$ with a spread of $\sigma_m^2$. In this case, again, because you have those $\mu_m,\sigma_m^2$ pairs, you could use them to apply confidence intervals.

As a last note, have you tried plotting boxplots of the spectra over the two conditions? Is there overlap in the frequency range you are interested in?

Hope this helps