Notebook
In [25]:
import matplotlib.pyplot as plt
import pyfolio as pf
#====================================================================================================================

bt2 = get_backtest('596d370a3078324e270d47e3')
plotGit, = plt.plot(pf.timeseries.cum_returns(bt2.daily_performance.returns), label = 'Get In And Get Out');

bt3 = get_backtest('5973f288383bb84e19734569')
plotGitStop5, = plt.plot(pf.timeseries.cum_returns(bt3.daily_performance.returns), label = 'Get In And Get Out STOP 5');

bt5 = get_backtest('5973ff77ebb7ec4de92832f0')
plotGitTrail3, = plt.plot(pf.timeseries.cum_returns(bt5.daily_performance.returns), label = 'Get In And Get Out 2.5% Trail 3');

btspy = get_backtest('5970660138279f521a8fbeb7')
plotSPY, = plt.plot(pf.timeseries.cum_returns(btspy.daily_performance.returns), label = 'SPY');
#====================================================================================================================
plt.legend(bbox_to_anchor=(1.025, 1),handles=[plotSPY, plotGit, plotGitStop5,plotGitTrail3], loc = 2, borderaxespad= 0. )
100% Time: 0:00:01|###########################################################|
  7% ETA:  0:00:02|####                                                       |
/usr/local/lib/python2.7/dist-packages/ipykernel_launcher.py:6: DeprecationWarning: Risk functions in pyfolio.timeseries are deprecated and will be removed in a future release. Please install the empyrical package instead.
  
100% Time: 0:00:00|###########################################################|
 13% ETA:  0:00:01|#######                                                    |
/usr/local/lib/python2.7/dist-packages/ipykernel_launcher.py:9: DeprecationWarning: Risk functions in pyfolio.timeseries are deprecated and will be removed in a future release. Please install the empyrical package instead.
  if __name__ == '__main__':
100% Time: 0:00:00|###########################################################|
  0% ETA:  --:--:--|                                                          |
/usr/local/lib/python2.7/dist-packages/ipykernel_launcher.py:12: DeprecationWarning: Risk functions in pyfolio.timeseries are deprecated and will be removed in a future release. Please install the empyrical package instead.
  if sys.path[0] == '':
100% Time: 0:00:00|###########################################################|
/usr/local/lib/python2.7/dist-packages/ipykernel_launcher.py:15: DeprecationWarning: Risk functions in pyfolio.timeseries are deprecated and will be removed in a future release. Please install the empyrical package instead.
  from ipykernel import kernelapp as app
Out[25]:
<matplotlib.legend.Legend at 0x7fbefde05fd0>
In [ ]: