I have used Indicators like: RSI and PE ratio in my python code, like below: inside Initialize function.

How do I get access to PE ratio inside OnData function. I want to trade based upon PE as a factor along with a few other factors like: RSI and MACD.

It will be helpful if I get any example code. 

I have looked at Universe coarse and fine filters, but I am not looking for filtering on PE, I have a set of pre-determined stocks, let's say.


thanks in anticipation.


self.rsi = self.RSI(self.my_stock, 10,  MovingAverageType.Simple, Resolution.Daily)

self.macd = self.MACD(self.my_stock, 12, 26, 9, MovingAverageType.Exponential, Resolution.Daily)