calculate autocorrelation for u,y

This commit is contained in:
leo 2023-02-25 13:23:47 +01:00
parent cc8ede3772
commit 4bf633dc5b
Signed by: wanderer
SSH Key Fingerprint: SHA256:Dp8+iwKHSlrMEHzE3bJnPng70I7LEsa3IJXRH/U+idQ

@ -34,11 +34,19 @@ func run() error {
varianceU := stats.Variance(data[u])
varianceY := stats.Variance(data[y])
log.Printf("len(data): %d\n", len(data[u]))
maxShift := 0.1
autocorrelationU := stats.AutocorrelateMP(data[u], maxShift)
autocorrelationY := stats.AutocorrelateMP(data[y], maxShift)
log.Printf("len(data): %d", len(data[u]))
log.Printf("means - u: %v, y: %v", meanU, meanY)
log.Printf("variance - u: %v, y: %v", varianceU, varianceY)
log.Printf("len(autocorrelationU): %d", len(autocorrelationU))
log.Printf("autocorrelationU: %v", autocorrelationU)
log.Printf("autocorrelationY: %v", autocorrelationY)
}
return nil