Study showed that big change in trading volume often precedes price change, reflecting information leak. One might be able to detect this by find the correlation between price change and volume turnover. Here is my attempt to do that.
There are two issues need to be addressed:
The algo runs slowly because it has to do column-wise subset correlation. Any suggestion to speed it up is welcome
The equity curve is trending down monotonically which looks like the factor has some alpha. Is there any way to transform the factor so that the equity curve is trending up?