Hi,

I am trying to write a strategy that works on multiple securities with the same strategy. Using the MACD-indicator on four different securities and if one of the four fits the condition, I want to buy an option for that security.

But everything one of the securities fits the condition, I buy options for all four securities instead of only one. 

How do I select only the right security that fits the condition the entry a trade?

        for symbol, macd in self.macd.items():
            if macd.Current.Value < 0.5:
                for symbol in self.symbols:
                    for kvp in data.OptionChains:
                            if kvp.Key == symbol:
                                chains = kvp.Value
                                self.BuyCall(chains)