Overall Statistics
Total Trades
2
Average Win
0%
Average Loss
-41.56%
Compounding Annual Return
-12.370%
Drawdown
71.700%
Expectancy
-1
Net Profit
-69.264%
Sharpe Ratio
-0.844
Loss Rate
100%
Win Rate
0%
Profit-Loss Ratio
0
Alpha
-0.082
Beta
-0.285
Annual Standard Deviation
0.119
Annual Variance
0.014
Information Ratio
-0.638
Tracking Error
0.263
Treynor Ratio
0.353
Total Fees
$2.00
namespace QuantConnect 
{   
    public class BasicTemplateAlgorithm : QCAlgorithm
    {
        string[] symbols = new string[]{"VXX"};

        public override void Initialize()
        {
            SetStartDate(2008,6,1);
            foreach(var symbol in symbols)
            {
                AddEquity(symbol, Resolution.Daily);
            }
        }

        public void OnData(TradeBars data) 
        {   
            if(!Portfolio.Invested) SetHoldings(symbols.First(), 1);
        }

        public override void OnEndOfDay()
        {
            foreach(var symbol in symbols)
            {
                Plot(symbol, "EOD Close", Securities[symbol].Price);
            }
        }
    }
}