Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Statistical risk factors beta exposure zero strategy

Attempt:
1. Identify statistical factors explaining risk.
2. Optimize portfolio such that exposure to all factors is zero and alpha positive.
3. Re-balance frequently.

4 responses

Hi Pravin,

Thanks for the share! I'm trying to study your implementation. Would you mind explain some details on how beta and weight based on beta calculated?

Thanks
Meng

  1. Run ICA to identify risk factors.
  2. Regress risk factors against returns to get coefficients of regression (beta)
  3. Optimize to get weights of portfolio with an equality to zero constraint on beta times weights.

Hi Pravin,

Here's my understanding for getweights():

  1. C*x: If my understanding is correct, you're trying to minimum -sum(alpha_i * 0 * x_i). Why multiplying zero here? isn't minimum -sum(alpha_i * x_i) a more straightforward?
  2. Ax = b : here b is vector of zero thus minium beta value.
  3. Gx <= h: here you restrict x_i <= 1 and sum(-alpha_i * x_i) <= -1e-5

Would you please give some details on how you modeling the optimization goal and convert to LP form?

Thanks
Meng

Hi Meng,

The algorithm is very fragile at the moment. More needs to be done to see the stability and relevance of each risk factor.

Your understanding of the optimization goal is correct. I had to multiply the objective function by zero because otherwise the optimizer fails sometimes. Don't know why.

Best regards,
Pravin