Overall Statistics |
Total Trades 1 Average Win 3.33% Average Loss 0% Compounding Annual Return 1546.436% Drawdown 4.400% Expectancy 0 Net Profit 3.332% Sharpe Ratio 4.42 Loss Rate 0% Win Rate 100% Profit-Loss Ratio 0 Alpha -0.026 Beta 2.025 Annual Standard Deviation 0.388 Annual Variance 0.151 Information Ratio 4.353 Tracking Error 0.197 Treynor Ratio 0.848 Total Fees $12.30 |
package QuantConnect; import cli.QuantConnect.Resolution; import cli.QuantConnect.SecurityType; import cli.QuantConnect.Algorithm.QCAlgorithm; import cli.QuantConnect.Data.Market.TradeBars; /* * QuantConnect University: Strategy Example: Basic Template * In this example we import all the basic components required to support the basic template. */ public class BasicTemplateAlgorithm extends QCAlgorithm { public void Initialize() { SetStartDate(2013, 10, 07); //Set Start Date SetEndDate(2013, 10, 11); //Set End Date SetCash(100000); //Set Strategy Cash // Find more symbols here: http://quantconnect.com/data AddSecurity(SecurityType.wrap(SecurityType.Equity), "SPY", Resolution.wrap(Resolution.Second),true,false); } public void OnData(TradeBars data) { if (!get_Portfolio().get_Invested()) { SetHoldings("SPY", 1, false); Debug("Hello From Java"); } } }