Problem generating wavelet variance/covarance

How do I solve the error?

Here's my script:

A=x B=y wf <- "la8" J <- 8 N<- length(A) A.modwt <- modwt(A, wf, J) B.modwt <- modwt(B, wf, J) <- brick.wall(A.modwt, wf) <- brick.wall(B.modwt, wf) WCOV = wave.covariance(, Error in x[c((n%/%2):n, 1:(n%/%2 - 1))] : only 0's may be mixed with negative subscripts

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum