Back to Community
minimum variance portfolio w/ S&P 500 sector ETFs and TLT

Looks sorta interesting. Maybe someone would like to improve it or comment? --Grant

Clone Algorithm
548
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 565b7d8a7f05c01156d99877
We have migrated this algorithm to work with a new version of the Quantopian API. The code is different than the original version, but the investment rationale of the algorithm has not changed. We've put everything you need to know here on one page.
There was a runtime error.
5 responses

Since you're already using a general optimization algorithm, why not add the no-shorts as a constraint also? Also, try out bootstrapping, that has helped a lot to reduce the jumpiness of optimized portfolio holdings over time, for me.

Thanks Simon,

The solution is already bounded by:

bnds = ((0,1),(0,1),(0,1),(0,1),(0,1),(0,1),(0,1),(0,1),(0,1),(0,1))  

Do you think it would help to incorporate a no-shorts constraint, as well (x[i] >= 0)?

Also, what do you mean by bootstrapping?

Grant

I try add XIV to the portfolio, it seems approve the little performance and keep same Volatility and Max Drawdown with original portfolio.

Clone Algorithm
11
Loading...
Backtest from to with initial capital
Total Returns
--
Alpha
--
Beta
--
Sharpe
--
Sortino
--
Max Drawdown
--
Benchmark Returns
--
Volatility
--
Returns 1 Month 3 Month 6 Month 12 Month
Alpha 1 Month 3 Month 6 Month 12 Month
Beta 1 Month 3 Month 6 Month 12 Month
Sharpe 1 Month 3 Month 6 Month 12 Month
Sortino 1 Month 3 Month 6 Month 12 Month
Volatility 1 Month 3 Month 6 Month 12 Month
Max Drawdown 1 Month 3 Month 6 Month 12 Month
# Backtest ID: 565c2ff2b91d11115b98215d
There was a runtime error.

Ah no, you shouldn't. I just noticed you were also doing:

allocation[allocation<0]=0  

which would seem to be unnecessary.

I'll have to check. I recall adding it because the bounds are not strictly obeyed. Sometimes there is a small negative value.