When simulating many times a PDS with a given rms and measuring it with our rms_calculation in fourier.py, the error bars are underestimated (red lines indicate the calculated error, the blue ones the actual standard deviation of the measurements in the thousands of realization)
I re-implemented the method from scratch, using clearer passages to normalize the spectrum correctly, and I obtain something like this:
So, there must be an error somewhere. Since the current code is rather clunky, I'm inclined to deprecate the old function and create a new one with clearer parameters (e.g. making it clear whether a parameter refers to the full observation or each segment of the averaged spectrum, like nphots_per_segment)
When simulating many times a PDS with a given rms and measuring it with our
rms_calculation
infourier.py
, the error bars are underestimated (red lines indicate the calculated error, the blue ones the actual standard deviation of the measurements in the thousands of realization)I re-implemented the method from scratch, using clearer passages to normalize the spectrum correctly, and I obtain something like this:
So, there must be an error somewhere. Since the current code is rather clunky, I'm inclined to deprecate the old function and create a new one with clearer parameters (e.g. making it clear whether a parameter refers to the full observation or each segment of the averaged spectrum, like
nphots_per_segment
)