From 3223b527890e3090184384374f45a964cffa254a Mon Sep 17 00:00:00 2001 From: Jaron Kent-Dobias Date: Thu, 26 Jul 2018 19:32:34 -0400 Subject: fixed several bugs --- src/analyze_correlations.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/analyze_correlations.cpp b/src/analyze_correlations.cpp index 5f3dda0..91c2e7f 100644 --- a/src/analyze_correlations.cpp +++ b/src/analyze_correlations.cpp @@ -20,7 +20,7 @@ double mean(int N, T *data) { double squared_mean(int N, double *data) { double total = 0; for (int i = 0; i < N; i++) { - total += data[i]; + total += pow(data[i], 2); } return total / N; -- cgit v1.2.3-70-g09d2