Generalized harmonic least-squares amplitude and phase estimation method
An optimisation approach which aims at minimizing the sum of the squared residuals when fitting sinusoids of known frequencies to a time series of discrete measurements. Also included is a windowed linear detrend function with optional window overlap for pre-processing of non-uniformly sampled data.
[1] Stoica Petre, Moses R. L. (2005). Spectral Analysis of Signals. Upper Saddle River, New Jersey 07458. Pearson Prentice Hall, ISBN 0-13-113956.
[2] Stoica, Petre, Jian Li, & Hao He. (2009). Spectral Analysis of Nonuniformly Sampled Data: A New Approach Versus the Periodogram. IEEE Transactions on Signal Processing, 57(3), 843–858. https://doi.org/10.1109/TSP.2008.2008973