@ccsv It's unclear to me what you're doing here. Do you have an exact reference for this, or can you explain in words?

It looks like you normalize the data in one period by the mean of each period. E.g., for monthly data year one is normalized by the mean for that whole year (axis 1 mean). Then you take the period averages (axis 0) mean. I'm curious about this. Division vs. subtraction corrections for the assumed type of cycle.