Overall Statistics
Total Trades
1
Average Win
0%
Average Loss
0%
Compounding Annual Return
0.093%
Drawdown
0.100%
Expectancy
0
Net Profit
0.093%
Sharpe Ratio
0.51
Probabilistic Sharpe Ratio
29.720%
Loss Rate
0%
Win Rate
0%
Profit-Loss Ratio
0
Alpha
0.001
Beta
-0.001
Annual Standard Deviation
0.001
Annual Variance
0
Information Ratio
-2.265
Tracking Error
0.113
Treynor Ratio
-0.837
Total Fees
$0.00
namespace QuantConnect 
{   
    public class QCUQuandlImporter : QCAlgorithm
    {
        string _quandlCode = "CBOE/VIX";
        
        public override void Initialize()
        {
            //Start and End Date range for the backtest:
            SetStartDate(2019, 1, 1);         
            SetEndDate(2020, 1, 1); 
            
            //Cash allocation
            SetCash(25000);
           
            AddData<QuandlVix>(_quandlCode, Resolution.Daily);
        }

        public void OnData(Quandl data) 
        {
            if (!Portfolio.Invested) 
            {
                var orders = -1.5;
                
                Order(_quandlCode, Math.Floor(orders) );
            }
        }
    }
    
    public class QuandlVix : Quandl 
    {
    	public QuandlVix() : base("VIX Close")
    	{
    		
    	}
    }
}