How to trade with cTrader indicators¶
Traders who use indicators can quickly react to market changes, adapt their strategies in real time and make immediate risk adjustments. In this article and its corresponding video, we will show you how to trade using indicators.
Create an indicator with a trading panel¶
To create a simple trading panel using an indicator, go to the Algo app, navigate to the Indicators tab and then click the New button. Tick the Blank option, enter a name for your indicator such as "Trading Panel" and then click the Create button.
We can start modifying the indicator code in the code editor. To prevent the indicator from creating a separate chart, we set isOverlay
to true
.
1 |
|
Then, we initialise two buttons that open buy and sell positions when clicked.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
|
Add the new buttons to a new grid.
1 2 3 |
|
Add the grid to our chart.
1 |
|
You can copy the full code below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
|
Click the Build button or use the Ctrl+B shortcut to build the indicator.
Use the trading panel¶
Go to the Trade app to use the indicator. You can add the Trading panel indicator to a chart. Click the Indicator icon, search for Trading panel and click the result.
Here, the indicator was added to a EURUSD chart.
Click the Buy and Sell buttons to open positions. When the Permission request window appears, click the Allow button. You can manage the panel visibility through its Hide/Show icon.
cTrader now allows you to change the chart period without removing indicators on that chart. Simply select a new period and watch how the panel behaves.
This article taught you the basics of trading with indicators in cTrader.