LEAN is the open source
algorithmic trading engine powering QuantConnect. Founded in 2013 LEAN has been built by a
global community of 80+ engineers and powers more than a dozen hedge funds today.
Alpha League Competition: $1,000 Weekly Prize Pool
Qualifying Alpha Streams Reentered Weekly Learn
more
I've been trying to filter a universe through a moving average and rsi, however, i havent been getting the expected results.
I started with the MA cross example and added an RSI indicator to debug what going on. I'm getting the following information for each symbol when i debug the symbol, fastMA, slowMA, price and rsi.
Ticker = AADR UOFRJAZTL0TH , Fast MA = 36.64 , Slow = 0.0 , Price = 36.64 , RSI =0.0
I'm sure this is a rookie mistake, but i seem to be getting 0 for both the slow moving average and rsi and then the same value for the price and fast moving average.
I've attached the backtest, Any help would be greatly appreciated
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
That helps to update the slow and rsi, however, it still gives an unexpected result
Ticker = AFSD VAAHQ09OPU1X , Fast MA = 25.0 , Slow = 25.0 , Price = 25 , RSI =100.0
For all the symbols, rsi = 100 and the fast MA, slow MA and Price are always equal.
0
Michael Manus
10.2k
,
I was not very well in math but glenn how did you set the test period?
start and enddate.......i am asking because the resolution is set to daily and you have
ExponentialMovingAverage(300)
.................................................. is that a 300 day ex. moving average? :)
0
Glenn Wilson
183
,
Yes, it was meant to be a 300 day moving average.
I feel very silly, i was testing it on a non-trading day and wondering why i wasnt getting the correct results. I would have still expected the moving averages to have shown correctly though.
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Loading...
To unlock posting to the community forums please complete at least 30% of Boot Camp. You can
continue your Boot Camp training progress from the terminal. We
hope to see you in the community soon!