def next(self):
    position = self.getposition()
    if ((not position) and self.crossover[0]):
        self.order_target_percent(target=self.p.ratio)
    if (position and self.crossdown[0]):
        self.close()
def next(self):
    position = self.getposition()
    if ((not position) and self.crossover[0]):
        self.order_target_percent(target=self.p.ratio)
    if (position and self.crossdown[0]):
        self.close()