Overall Statistics
Total Trades
2
Average Win
0%
Average Loss
0%
Compounding Annual Return
-1.424%
Drawdown
9.800%
Expectancy
0
Net Profit
0%
Sharpe Ratio
-0.175
Loss Rate
0%
Win Rate
0%
Profit-Loss Ratio
0
Alpha
-0.01
Beta
-0.004
Annual Standard Deviation
0.057
Annual Variance
0.003
Information Ratio
-0.37
Tracking Error
0.143
Treynor Ratio
2.843
Total Fees
$9.16
import pandas as pd
import numpy as np



class BasicTemplateAlgorithm(QCAlgorithm):
	def __init__(self):
		self.tickers = ['KO','PG']
		self.spy = 'SPY'
		
	def Initialize(self):
		self.SetCash(100000)
		self.SetStartDate(2015,1,1)
		self.SetEndDate(2017,1,1)
		
		for i in range(len(self.tickers)):
			symbol = self.AddEquity(self.tickers[i], Resolution.Daily)
			self.tickers[i] = symbol.Symbol


	def OnData(self, slice):
		if not self.Portfolio.Invested:
			self.SetHoldings(self.tickers[0], -0.48)
			self.SetHoldings(self.tickers[1], 0.5)