From f6dc35acc8f2642d50dd83113c2b1e0616d2fa42 Mon Sep 17 00:00:00 2001 From: Ashim Kapoor Date: Fri, 24 Oct 2025 11:56:07 +0530 Subject: [PATCH 1/2] Correction to the documentation. --- R/multitaperHelper.R | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/R/multitaperHelper.R b/R/multitaperHelper.R index c2b7b93..59ff6fb 100644 --- a/R/multitaperHelper.R +++ b/R/multitaperHelper.R @@ -68,11 +68,11 @@ var, dt_, ev, evp=(1-ev), tol=.03, maxadaptiveiteration=100) { - ## this is equation (5.3) and (5.4) form + ## this is equation (5.2) and (5.3) from ## Thomson, D.J. Spectrum Estimation and Harmonic Analysis, ## Proceedings of the IEEE, 1982. - ## note that the weights are squared, they are |d_k(f)^2 from equation - ## (5.4) + ## note that the weights are squared, they are |d_k(f)|^2 from equation + ## (5.2) out <- .Fortran("mw2wta", as.double(sa), wt=matrix(as.double(0), nfreq, nord), From 492b83d38f1b676ec3bf6b84cc8748764fef234b Mon Sep 17 00:00:00 2001 From: Ashim Kapoor Date: Fri, 24 Oct 2025 15:27:35 +0530 Subject: [PATCH 2/2] Improved upon the correction. Equation 5.2 is where d_k(f) is defined, however |d_k(f)|^2 is the weight used in equation 5.3. Hence the change. --- R/multitaperHelper.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/multitaperHelper.R b/R/multitaperHelper.R index 59ff6fb..bb3ad83 100644 --- a/R/multitaperHelper.R +++ b/R/multitaperHelper.R @@ -72,7 +72,7 @@ ## Thomson, D.J. Spectrum Estimation and Harmonic Analysis, ## Proceedings of the IEEE, 1982. ## note that the weights are squared, they are |d_k(f)|^2 from equation - ## (5.2) + ## (5.3) out <- .Fortran("mw2wta", as.double(sa), wt=matrix(as.double(0), nfreq, nord),