Hi!

I'm new to quantitative trading and would like some help with placing trades based on RSI. This is what I have so far:

 def GetState(self, rsi, previous):
        if rsi.Current.Value > 70:
            self.Sell(self.pair, 1000)
            self.LimitOrder(self.pair, 1000, price / onePercent)
            self.StopMarketOrder(self.pair, 1000, price * onePercent)
        if rsi.Current.Value < 30:
            self.Buy(self.pair, 1000)
            self.LimitOrder(self.pair, 1000, price / onePercent)
            self.StopMarketOrder(self.pair, 1000, price / onePercent)

        return previous

Some feedback would be appreciated as I take it that the general idea isn't too hard to deter.