# Please make strategy for the expression on MACD and RSI

**URL:** https://tradingqna.com/t/please-make-strategy-for-the-expression-on-macd-and-rsi/2787
**Category:** Algos, strategies, code
**Created:** [March 27, 2015, 12:57pm UTC](https://tradingqna.com/t/please-make-strategy-for-the-expression-on-macd-and-rsi/2787 "2015-03-27T12:57:37Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Anita](https://tradingqna.com/letter_avatar_proxy/v4/letter/a/49beb7/32.png) [@Anita](https://tradingqna.com/u/Anita)
#### Post date: [March 27, 2015, 12:57pm UTC](https://tradingqna.com/t/please-make-strategy-for-the-expression-on-macd-and-rsi/2787/1 "2015-03-27T12:57:37Z")

</div>

Generally I use MACD of Short Period 12 and Long Period 26 with RSI Period 10.  
I buy @ cross over + RSI~30 (Increase the value of RSI from a lower range)  
I sell@ cross over + RSI~70 (Decrease the value of RSI from a higher range)  
Please make strategy for the expression.

---

<div class="post-metadata">

### Author: ![AlgoGeek](https://tradingqna.com/user_avatar/tradingqna.com/algogeek/32/6398_2.png) [@AlgoGeek](https://tradingqna.com/u/AlgoGeek)
#### Post date: [March 27, 2015, 1:21pm UTC](https://tradingqna.com/t/please-make-strategy-for-the-expression-on-macd-and-rsi/2787/2 "2015-03-27T13:21:33Z")

</div>

Buy:

```
SET A = MACDSignal(12, 26, 10, SIMPLE)
SET B = MACD(13, 26, 9, SIMPLE)
CROSSOVER(A, B) = TRUE AND RSI(CLOSE, 14) > 30
```

Sell:

```
SET A = MACDSignal(13, 26, 9, SIMPLE)
SET B = MACD(12, 26, 10, SIMPLE)
CROSSOVER(A, B) = TRUE AND RSI(CLOSE, 14) < 70
```
