Back

Relative Strength

disclosure: noob to coding

Am I in the correct general area for thinking that in order to get a value for relative strength (security/index) I'll need to create a matrix and then divide them ?

Thanks
Update Backtest








Hey @Neil, do you mean the RSI indicator?
0

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.


This was my psuedo code for the Money Flow Index, which I think is similar to RSI (but volume based). I was meant to post all these indicators for free to the platform but haven't had a chance -- and actually haven't coded up RSI before :)


/*
* 1. Typical Price = (High+Low+Close)/3
* 2. Money Flow = Typical Price * Volume
* 3. Money Ratio = Positive/Negative Money Flow
* 4. Money Flow Index = 100 - (100 / (1 + Money Ratio))
* Positive Money Flow is when the typical price is greater than the previous typical price.
*/

0

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.


@Jared, similar but that indicator compares the security against itself. I'm looking for RS vs an index (S&P500) so something such as IBM:DJIA
0

Update Backtest





0

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...

This discussion is closed