Created framework for self.by_market