This indicator will plot up- and downward-pointing triangles, whenever the buy-/ sell-conditions are met.
In line 5 and 7, data series are created for the indicators you would like to use. For the sake of clarity, the length of the RSI and MA are hardcoded but could also be provided by an input dialog.
The conditions that implement the strategy are implemented in line 11 and 15. The RSI treshold is hardcoded as well.
To have a visual representation of the signals, we will plot triangles, see line 18 and 19.
To not only see the signals on the chart, but to get the opportunity to create alerts, we need to introduce alertconditions in line 22 and 23.
And that's it - click on the "Add to chart" button and see how the triangles are plotted to the chart:
As you can see on this EURUSD 1H chart, there are some promising signals based on this very basic strategy of just combining RSI and MA.
The next step is to setup the alerts, so you get notified while you are on the go.
The next step is to setup the alerts, so you get notified while you are on the go. To do this, open the "Add Alert" dialog.
The default condition for alerts is always based on the price of the current financial instrument, so be sure to select the newly created indicator "RSI+MA" instead of "EURUSD".
The indicator script implemented two alert conditions, one for buy-signals and one for sell-signals. So we need to setup two alerts, if we want signals for both directions.
Finally you just need to configure the frequency and the alert actions and maybe you want to customize the alert message text - everything is quite self-explanatory.
If you want a sophisticated indicator that is highly customizable and does support alerts, please have a look at my UniDivergence Toolkit.