KEMBAR78
Deriv Bot Builder Help Guide | PDF | Moving Average | Boolean Data Type
0% found this document useful (0 votes)
4K views46 pages

Deriv Bot Builder Help Guide

The document provides a comprehensive guide on various trading strategies integrated into Deriv Bot, including Martingale, Reverse Martingale, D'Alembert, Reverse D'Alembert, and Oscar's Grind. Each strategy outlines key parameters such as initial stake, profit/loss thresholds, and how to manage risks effectively. Traders are advised to assess their risk tolerance, practice in demo accounts, and understand each strategy before engaging in real trading.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4K views46 pages

Deriv Bot Builder Help Guide

The document provides a comprehensive guide on various trading strategies integrated into Deriv Bot, including Martingale, Reverse Martingale, D'Alembert, Reverse D'Alembert, and Oscar's Grind. Each strategy outlines key parameters such as initial stake, profit/loss thresholds, and how to manage risks effectively. Traders are advised to assess their risk tolerance, practice in demo accounts, and understand each strategy before engaging in real trading.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 46

 Deriv Bot Builder help guide.

 Quick strategy guides

Quick strategy guides >

About Martingale
Exploring the Martingale strategy in Deriv Bot
The Martingale strategy involves increasing your stake after each loss to recoup prior losses with a single successful trade.
This article explores the Martingale strategy integrated into Deriv Bot, a versatile trading bot designed to trade assets such
as forex, commodities, and derived indices. We will delve into the strategy's core parameters, its application, and provide
essential takeaways for traders looking to use the bot effectively.

Key Parameters:
These are the trade parameters used in Deriv Bot with Martingale strategy.
Initial stake: The amount that you are willing to place as a stake to enter a
trade. This is the starting point for any changes in stake depending on the
dynamic of the strategy being used.
Multiplier: The multiplier used to increase your stake if you're losing a
trade. The value must be greater than 1.
Profit threshold: The bot will stop trading if your total profit exceeds this
amount.
Loss threshold: The bot will stop trading if your total loss exceeds this
amount.
Maximum stake: The maximum amount you are willing to pay to enter a
single trade. The stake for your next trade will reset to the initial stake if it
exceeds this value. This is an optional risk management parameter.

An Example of Martingale Strategy:

1. Start with the initial stake. Let’s say 1 USD.


2. Select your Martingale multiplier. In this example, it is 2.
3. If the first trade ends in a loss, Deriv Bot will automatically double your
stake for the next trade to 2 USD. Deriv Bot will continue to double the stake
after every losing trade.
4. If a trade ends in a profit, the stake for the following trade will be reset to
the initial stake amount of 1 USD.
The idea is that successful trades may recoup previous losses. However, it is
crucial to exercise caution as the risk can quickly increase with this strategy.
With Deriv Bot, you can minimise your risk by setting a maximum stake. This
is an optional risk management feature. Let’s say a maximum stake of 3
USD. If your stake for the next trade is set to exceed 3 USD, your stake will
reset to the initial stake of 1 USD. If you didn't set a maximum stake, it
would have increased beyond 3 USD.

Profits and theshoulds :

With Deriv Bot, traders can set the profit and loss thresholds to secure potential
profits and limit potential losses. This means that the trading bot will automatically
stop when either the profit or loss thresholds are reached. It's a form of risk
management that can potentially enhance returns. For example, if a trader sets the
profit threshold at 100 USD and the strategy exceeds 100 USD of profit from all
trades, then the bot will stop running.

Estimating the life span of your trades:

If you're about to start trading and haven't established a Maximum Stake as


part of your risk management strategy, you can determine how long your
funds will last by employing the Martingale strategy. Simply use this formula.

R = log(B/s) / log(m)

Where:
R is the number of rounds a trader can sustain given a specific loss
threshold.
B is the loss threshold.
s is the initial stake.
m is the Martingale multiplier.
For instance, if a trader has a loss threshold (B) is 1000 USD, with an initial
stake (s) is 1 USD, and the Martingale multiplier (m) is 2, the calculation
would be as follows:

R = log(100/1) / log(2)

Number of rounds, R ≈ 9.965


This means that after 10 rounds of consecutive losses, this trader will lose
1023 USD which exceeds the loss threshold of 1000 USD, stopping the bot.
This formula helps you plan your trades by considering the amount of money
you have and your comfort level with risk. It involves determining your loss
threshold and the initial stake you want to trade with. Then, you use this
formula to calculate the number of rounds you can trade. This process
provides insight into stake sizing and expectations.

Summary :

The Martingale strategy in trading may offer substantial gains but also
comes with significant risks. With your selected strategy, Deriv Bot provides
automated trading with risk management measures like setting initial stake,
stake size, maximum stake, profit threshold and loss threshold. It's crucial for
traders to assess their risk tolerance, practice in a demo account, and
understand the strategy before trading with real money.
Disclaimer:
Please be aware that while we may use rounded figures for illustration, a
stake of a specific amount does not guarantee an exact amount in successful
trades. For example, a 1 USD stake does not necessarily equate to a 1 USD
profit in successful trades.
Trading inherently involves risks, and actual profits can fluctuate due to
various factors, including market volatility and other unforeseen variables.
As such, exercise caution and conduct thorough research before engaging in
any trading activities.

Exploring the Reverse Martingale Strategy in Deriv Bot :

The Reverse Martingale strategy involves increasing your stake after each
successful trade and resets to the initial stake for every losing trade as it
aims to secure potential profits from consecutive wins.
This article explores the Reverse Martingale strategy integrated into Deriv
Bot, a versatile trading bot designed to trade assets such as forex,
commodities, and derived indices. We will delve into the strategy's core
parameters, its application, and provide essential takeaways for traders
looking to use the bot effectively.

Key Parameters :
These are the trade parameters used in Deriv Bot with Reverse Martingale
strategy.
Initial stake: The amount that you are willing to place as a stake to enter a
trade. This is the starting point for any changes in stake depending on the
dynamic of the strategy being used.
Multiplier: The multiplier used to increase your stake if your trade is
successful. The value must be greater than 1.
Profit threshold: The bot will stop trading if your total profit exceeds this
amount.
Loss threshold: The bot will stop trading if your total loss exceeds this
amount.
Maximum stake: The maximum amount you are willing to pay to enter a
single trade. The stake for your next trade will reset to the initial stake if it
exceeds this value. This is an optional risk management parameter.

1. Start with the initial stake. Let’s say 1 USD.


2. Select your Martingale multiplier. In this example, it is 2.
3. If the first trade is a successful trade, Deriv Bot will automatically double
your stake for the next trade to 2 USD. Deriv Bot will continue to double the
stake after every successful trade.
4. If a trade ends in a loss, the stake for the following trade will be reset to
the initial stake amount of 1 USD.
The objective of Martingale strategy is to take advantage of consecutive
successful trades and maximise potential profits from them. This strategy is
beneficial only if there are consecutive successful trades. Therefore, it is
important to set a maximum stake to secure all the potential profits gained
from a number of consecutive successful trades, or you could lose all the
profits you have accumulated, including your initial stake. For example, if
your goal is to maximise profits within 2 consecutive successful trades, you
set a maximum stake of 2 USD, given your initial stake is 1 USD. Similarly, if
your goal is to maximise profits within 3 consecutive successful trades, you
set a maximum stake of 4 USD, given your initial stake is 1 USD.

Profits and Loss thresholds :

With Deriv Bot, traders can set the profit and loss thresholds to secure potential
profits and limit potential losses. This means that the trading bot will automatically
stop when either the profit or loss threshold is reached. This is a form of risk
management that can potentially boost successful trades whilst limiting the impact
of loss. For example, if a trader sets the profit threshold at 100 USD and the
strategy exceeds 100 USD of profit from all trades, then the bot will stop running.

Summary :

The Reverse Martingale strategy in trading may offer substantial gains but
also comes with significant risks. With your selected strategy, Deriv Bot
provides automated trading with risk management measures like setting
initial stake, stake size, maximum stake, profit threshold and loss threshold.
It's crucial for traders to assess their risk tolerance, practice in a demo
account, and understand the strategy before trading with real money.
Disclaimer:
Please be aware that while we may use rounded figures for illustration, a
stake of a specific amount does not guarantee an exact amount in successful
trades. For example, a 1 USD stake does not necessarily equate to a 1 USD
profit in successful trades.

Exploring Reverse D’Alembert Strategy in Deriv Bot :


The D'Alembert strategy involves increasing your stake after a losing trade and
reducing it after a successful trade by a predetermined number of units.

Key Parameters :

These are the trade parameters used for D’Alembert strategy in Deriv Bot.
Initial stake: The amount that you are willing to place as a stake to enter a
trade. This is the starting point for any changes in stake depending on the
dynamic of the strategy being used.
Unit: The number of units that are added in the event of a trade resulting in
loss or the number of units removed in the event of a trade resulting in
profit. For example, if the unit is set at 2, the stake increases or decreases by
two times the initial stake of 1 USD, meaning it changes by 2 USD.
Profit threshold: The bot will stop trading if your total profit exceeds this
amount.
Loss threshold: The bot will stop trading if your total loss exceeds this
amount.
1. Start with the initial stake. In this example, we’ll use 1 USD.
2. Set your preferred unit. In this example, it is 2 units or 2 USD.
3. If the first trade results in profit, the stake for the following trade will not
reduce but remain at the initial stake. The strategy minimally trades at the
initial stake of 1 USD. See A1.
4. If the second trade results in a loss, the Deriv Bot will automatically
increase your stake for the next trade by 2 USD. Deriv Bot will continue to
add 2 USD to the previous round’s stake after every losing trade. See A2.
5. If the next trades are profitable, the stake for the following trade will be
reduced by 2 USD. This can be shown above where the stake of 3 USD is
reduced to 1 USD. See A3.

Profit and Loss thresholds :


With Deriv Bot, traders can set the profit and loss thresholds to secure potential
profits and limit potential losses. This means that the trading bot will automatically
stop when either the profit or loss thresholds are reached. It's a form of risk
management that can potentially enhance returns. For example, if a trader sets the
profit threshold at 100 USD and the strategy exceeds 100 USD of profit from all
trades, then the bot will stop running.

Estimating the Lifespan of the trades:

The D’Alembert strategy is less risky than Martingale, but you can still
determine how long your funds will last with this strategy before trading.
Simply use this formula.

B = s * [ R + ( (R + 1) / 2 ) * (R * f) ]

Where:
R is the number of rounds a trader can sustain given a specific loss
threshold.
B is the loss threshold.
s is the initial stake.
f is the unit increment.
For instance, if a trader has a loss threshold (B) of 100 USD, with an initial
stake (s) of 1 USD and 2 units of increment (f), the calculation would be as
follows:

100 = s * [ R + ( (R + 1) / 2 ) * (R * 2) ]

Number of rounds (R) = 10


This means after 10 rounds of consecutive losses, this trader will lose 100
USD. This reaches the loss threshold of 100 USD, stopping the bot.
This formula helps you plan your trades by considering the amount of money
you have and your comfort level with risk. It involves determining your loss
threshold and the initial stake you want to trade with. Then, you use this
formula to calculate the number of rounds you can trade. This process
provides insight into stake sizing and expectations.

Summary:

The D'Alembert system offers more balanced trading through controlled stake
progression. With prudent risk management like stake limits, it can be effectively
automated in Deriv Bot. However, traders should thoroughly assess their risk
appetite, test strategies on a demo account to align with their trading style before
trading with real money. This allows optimising the approach and striking a balance
between potential gains and losses whilst managing risk.

Exploring the Reverse D’Alembert Strategy in d bot

The Reverse D'Alembert strategy involves increasing your stake after a successful
trade and reducing it after a losing trade by a predetermined number of unit

Key Parameters:

These are the trade parameters used in Deriv Bot with Reverse D’Alembert
strategy.
Initial stake: The amount that you are willing to place as a stake to enter a
trade. This is the starting point for any changes in stake depending on the
dynamic of the strategy being used.
Unit: The number of units that are added in the event of successful trades or
the number of units removed in the event of losing trades. For example, if
the unit is set at 2, the stake increases or decreases by two times the initial
stake of 1 USD, meaning it changes by 2 USD.
Profit threshold: The bot will stop trading if your total profit exceeds this
amount.
Loss threshold: The bot will stop trading if your total loss exceeds this
amount.

Example of Reverse D’Alembert Strategy


1. Start with the initial stake. Let’s say 1 USD.
2. Select your unit. In this example, it is 2 units or 2 USD.
3. For trades that result in a profit, the stake for the next trade will be
increased by 2 USD. Deriv Bot will continue to add 2 USD for every
successful trade. See A1.
4. For trades that result in a loss, there are two outcomes. If it was traded at
the initial stake, the next trade will remain at the same amount as the
strategy trades minimally at the initial stake, see A2. If it was traded with a
higher amount, the stake for the next trade would be reduced by 2 USD, see
A3.

Profits and Loss Thresholds

With Deriv Bot, traders can set the profit and loss thresholds to secure potential
profits and limit potential losses. This means that the trading bot will automatically
stop when either the profit or loss threshold is reached. This is a form of risk
management that can potentially boost successful trades whilst limiting the impact
of loss. For example, if a trader sets the profit threshold at 100 USD and the
strategy exceeds 100 USD of profit from all trades, then the bot will stop running.

Summary : Effective trading with the D'Alembert system requires careful


consideration of its stake progression and risk management. Traders can automate
this approach using Deriv Bot, setting profit and loss thresholds to ensure balanced
and controlled trading. However, it is crucial for traders to assess their risk appetite,
test strategies on a demo account, and align with their own trading style before
transitioning to real money trading. This optimization process helps strike a balance
between potential gains and losses while managing risk prudently.

Exploring the Oscars Grind Strateguy bot:

The Oscar’s Grind strategy is designed to potentially gain a modest yet steady profit
in each trading session. This strategy splits trades into sessions and has three
principles.

Key Parameters :

These are the trade parameters used for Oscar’s Grind strategy in Deriv Bot.
Initial stake: The amount that you are willing to place as a stake to enter a
trade. This is the starting point for any changes in stake depending on the
dynamic of the strategy being used.
Profit threshold: The bot will stop trading if your total profit exceeds this
amount.
Loss threshold: The bot will stop trading if your total loss exceeds this
amount.
Principle 1: Strategy aims to potentially make one unit of profit per
session
The table above demonstrates this principle by showing that when a
successful trade occurs and meets the target of one unit of potential profit
which is 1 USD in this example, the session ends. If trading continues, a new
session will begin.
Principle 2: The stake only increases when a loss trade is followed
by a successful trade
The table illustrates this principle in the second session. After a trade
resulting in loss in round 4 followed by a successful trade in round 5, the
stake will increase to 2 USD for round 6. This is in line with the strategy's rule
of raising the stake only after a loss is followed by a successful trade.
Principle 3: The stake adjusts to the gap size between current loss
and the target profit for the session
In round 7, the stake is adjusted downwards from 2 USD to 1 USD, to meet
the target profit of 1 USD.
The stake adjustment: target session profit (1 USD) - current session profit (0
USD) = 1 USD
The second session concludes upon reaching the aim of one unit of potential
profit per session, equivalent to 1 USD. If trading continues, a new session
will commence again.
Profits and Loss Limits :

With Deriv Bot, traders can set the profit and loss thresholds to secure potential
profits and limit potential losses. This means that the trading bot will automatically
stop when either the profit or loss threshold is reached. This is a form of risk
management that can potentially boost successful trades whilst limiting the impact
of loss. For example, if a trader sets the profit threshold at 100 USD and the
strategy exceeds 100 USD of profit from all trades, then the bot will stop running.

Summary :

The Oscar's Grind strategy provides a disciplined approach for incremental gains
through systematic stake progression. When integrated into Deriv Bot with proper
risk management like profit or loss thresholds, it offers traders a potentially
powerful automated trading tech

Exploring the 1-3-2-6 strategy in Deriv Bot

The 1-3-2-6 strategy aims to maximise potential profits with four consecutive successful trades. One unit
is equal to the amount of the initial stake. The stake will adjust from 1 unit to 3 units after the first
successful trade, then to 2 units after your second successful trade, and to 6 units after the third
successful trade. The stake for the next trade will reset to the initial stake if there is a losing trade or a
completion of the trade cycle.

This article explores the strategy integrated into Deriv Bot, a versatile trading bot designed to trade
assets such as Forex, Commodities, and Derived Indices. We will delve into the strategy's core
parameters, its application, and provide essential takeaways for traders looking to use the bot effectively.

Key Parameters :

These are the trade parameters used in Deriv Bot with 1-3-2-6 strategy.
Initial stake: The amount that you are willing to place as a stake to enter a
trade. This is the starting point for any changes in stake depending on the
dynamic of the strategy being used.
Profit threshold: The bot will stop trading if your total profit exceeds this
amount.
Loss threshold: The bot will stop trading if your total loss exceeds this
amount.
Example :

1. Start with the initial stake. Let’s say 1 USD.

2. If the trade is successful, this strategy will automatically adjust your stake to 3 units of your initial stake
for the next trade. In this case, the stake adjustment is 3 units and the initial stake is 1 USD, hence the
next trade will start at 3 USD.

3. If the second trade is also successful, your stake will adjust to 2 USD or 2 units of the initial stake for
the next trade.

4. However, if any trade results in a loss, your stake will reset back to the initial stake of 1 USD for the
next trade. The third trade results in a loss hence the stake resets to the initial stake of 1 USD for the
next trade.
5. Upon reaching the initial stake, if the next trade still results in a loss, your stake will remain at the
initial stake of 1 USD. This strategy will minimally trade at the initial stake. Refer to the fourth and fifth
trade.

6. If consecutive successful trades were to happen, the stake would follow a sequence of adjustment
from 1 to 3, then 2, and 6 units of initial stake. After 4 consecutive successful trades, it completes one
cycle and then the strategy will repeat itself for another cycle. If any trade results in a loss, your stake will
reset back to the initial stake for the next trade.

The 1-3-2-6 strategy is designed to capitalise on consecutive successful trades while minimising losses
during losing streaks. The rationale behind this strategy lies in statistical probabilities, with adjustments
to stake sizes based on the perceived likelihood of success. There is a higher likelihood of success in the
second trade after one successful trade. Hence the stake adjusts to 3 in the second trade. In the third
trade, the stake adjusts to 2 units due to a lower probability of a successful trade. If the third trade is also
successful, the strategy then allocates all the previous gains (a total of 6 units of initial stake) into the
fourth trade with the aim of doubling the potential profits. If the fourth trade results in a positive
outcome, the strategy helps achieve a total gain of 12 units. However, it is crucial to exercise caution, as
the risk can escalate quickly with this strategy, and any loss in the fourth trade forfeits all previous gains.

Profit and loss thresholds

With Deriv Bot, traders can set the profit and loss thresholds to secure potential
profits and limit potential losses. This means that the trading bot will automatically
stop when either the profit or loss threshold is reached. This is a form of risk
management that can potentially boost successful trades whilst limiting the impact
of loss. For example, if a trader sets the profit threshold at 100 USD and the
strategy exceeds 100 USD of profit from all trades, then the bot will stop running.

The 1-3-2-6 strategy in trading may offer substantial gains but also comes
with significant risks. Each stake is independent, and the strategy does not
increase your chances of successful trades in the long run. If you encounter a
series of losses, the strategy can lead to significant losses. Therefore, it is
crucial for traders to assess their risk tolerance, practice in a demo account,
utilise profit and loss thresholds, and fully comprehend the strategy before
engaging in real-money trading.

ANOTHER IMPORTANT INFORMATION FOR BOT BUILDER, WHERE IT REFLECTS THE MAIN PAGE TO
INTERACT LIKE FRONT END :
Trade Parameters :

This block is mandatory. It's added to your strategy by default when you create new strategy. You can not
add more than one copy of this block to the canvas.

1. Market

Select your desired market and asset type. For example, Forex > Major pairs > AUD/JPY

2. Trade Type

Select your desired trade type. For example, Up/Down > Rise/Fall

3. Contract Type

Choose what type of contract you want to trade. For example, for the Rise/Fall trade type you can
choose one of three options: Rise, Fall, or Both. Selected option will determine available options for the
Purchase block.

4. Default Candle Interval

Sets the default time interval for blocks that read list of candles.

5. Restart buy/sell on error

Restarts the bot when an error is encountered.

6. Restart last trade on error

Repeats the previous trade when an error is encountered.

7. Run Once at Start

Place blocks here to perform tasks once when your bot starts running.

8. Trade Options

The desired duration, stake, prediction, and/or barrier(s) for the contract is defined here.

Restart last trade on error (bot ignores the unsuccessful trade):✓Restart buy/sell on error (disable for be
tter performance):Default Candle Interval:1 minuteContract Type: Trade Type: > Market: > > 1. Trade par
ametersRun once at start:Trade options:

This block is used to define trade options within the Trade parameters root block. Some options are only
applicable for certain trade types. Parameters such as duration and stake are common among most trade
types. Prediction is used for trade types such as Digits, while barrier offsets are for trade types that
involve barriers such as Touch/No Touch, Ends In/Out, etc.

11Duration: Stake:USD

Multiplier Trade Options :


Use this block when you want to use multipliers as your trade type.

Click the multiplier drop-down menu and choose the multiplier value you want to trade with.

Your potential profit will be multiplied by the multiplier value you’ve chosen.

To learn more about multipliers, please go to the Multipliers page.

Take Profit (Multiplier)

Your contract is closed automatically when your profit is more than or equals to this
amount. This block can only be used with the multipliers trade type.

Stop loss (Multiplier)

Your contract is closed automatically when your loss is more than or equals
to this amount. This block can only be used with the multipliers trade type.
0Stop Loss:USD

Accumulator trade options

Define your trade options such as accumulator and stake. This block can only
be used with the accumulator trade type. If you select another trade type,
this block will be replaced with the Trade options block.
1Growth Rate: Stake:USD

Take Profit (Accumulator)

Your contract is closed automatically when your profit is more than or equals to this
amount. This block can only be used with the accumulator trade type.

Purchase Conditions :

This block is mandatory. Only one copy of this block is allowed. It is added to the canvas
by default when you open Deriv Bot.

Purchase
Use this block to purchase the specific contract you want. You may add multiple Purchase blocks
together with conditional blocks to define your purchase conditions. This block can only be used within
the Purchase conditions block.

Purchase

Sell Conditions :

Here is where you can decide to sell your contract before it expires. Only one
copy of this block is allowed.

Use this block to sell your contract at the market price. Selling your contract is optional.
You may choose to sell if the market trend is unfavourable.

Select at Market Price

Use this block to sell your contract at the market price. Selling your contract is optional.
You may choose to sell if the market trend is unfavourable.

Restart Trading Conditions :

This block is mandatory. Here is where you can decide if your bot should continue
trading. Only one copy of this block is allowed.

This block is commonly used to adjust the parameters of your next trade and to
implement stop loss/take profit logic.

Trade Again :

This block will transfer the control back to the Purchase conditions block, enabling you
to purchase another contract without manually stopping and restarting your bot.

ANALYSIS :

INDICATORS :

Simple Moving Average (SMA )

SMA adds the market price in a list of ticks or candles for a number of time
periods, and divides the sum by that number of time periods.
10PeriodInput Listsetsmato Simple Moving Average

he formula for SMA is:

SMA = (p1 + p2 + p3 + ... + p_suffix_n) / n

where n is the number of periods.

What SMA tells you

SMA serves as an indicator of the trend. If the SMA points up then the market
price is increasing and vice versa. The larger the period number, the
smoother SMA line is.

This will display the SMA for the specified period, using a candle list.

SMA places equal weight to the entire distribution of values.

This is the same as the above example, using a tick list.

You may compare SMA values calculated on every bot run to identify the
market trend direction. Alternatively, you may also use a variation of the
SMA block, the Simple Moving Average Array block.

10PeriodInput Listsetsmaato Simple Moving Average Array

This block returns the entire SMA line, containing a list of all values for a
given period.

If a period of 10 is entered, the Simple Moving Average Array block will


return a list of SMA values calculated based on period of 10.

The below image illustrates how Simple Moving Average Array block works:

Last Digit:
This block gives you the last digit of the latest tick value of the selected market. If the
latest tick value is 1410.90, this block will return 0. It’s useful for digit-based contracts
such as Even/Odd, Matches/Differs, or Higher/Lower.

Simple Moving Average Array (SMAA)

Similar to SMA, this block gives you the entire SMA line containing a list of all
values for a given period.
10PeriodInput Listsetsmaato Simple Moving Average Array

Bollinger Bands (BB)

BB is a technical analysis indicator that’s commonly used by traders. The


idea behind BB is that the market price stays within the upper and lower
bands for 95% of the time. The bands are the standard deviations of the
market price, while the line in the middle is a simple moving average line. If
the price reaches either the upper or lower band, there’s a possibility of a
trend reversal.
1055Standard Deviation Down MultiplierStandard Deviation Up MultiplierPeri
odInput Listsetbbto Bollinger Bandsmiddle

Bollinger Bands Array (BBA)

Similar to BB. This block gives you a choice of returning the values of either the lower
band, higher band, or the SMA line in the middle.

Exponential Moving Average (EMA)

EMA is a type of moving average that places more significance on the most recent data
points. It’s also known as the exponentially weighted moving average. EMA is different
from SMA in that it reacts more significantly to recent price changes.

Exponential Moving Average Array (EMAA)


This block is similar to EMA, except that it gives you the entire EMA line
based on the input list and the given period.
10PeriodInput Listsetemaato Exponential Moving Average Array
Relative Strength Index (RSI)

RSI is a technical analysis tool that helps you identify the market trend. It will give you a
value from 0 to 100. An RSI value of 70 and above means that the asset is overbought
and the current trend may reverse, while a value of 30 and below means that the asset
is oversold.

Relative Strength Index Array (RSIA)

Similar to RSI, this block gives you a list of values for each entry in the input
list.
10PeriodInput Listsetrsiato Relative Strength Index Array

Moving Average Convergence Divergence

MACD is calculated by subtracting the long-term EMA (26 periods) from the short-term
EMA (12 periods). If the short-term EMA is greater or lower than the long-term EMA than
there’s a possibility of a trend reversal.

Tick and Candle Analysis :

Any blocks placed within this block will be executed at every tick. If the default candle
interval is set to 1 minute in the Trade Parameters root block, the instructions in this
block will be executed once every minute. Place this block outside of any root block.

Last Trade Result :

You can check the result of the last trade with this block. It can only be placed within the
"Restart trading conditions" root block.

If "Win" is selected, it will return "True" if your last trade was successful.
Otherwise, it will return an empty string.
If "Loss" is selected, it will return "True" if your last trade was unsuccessful.
Otherwise, it will return an empty string.

Last tick

This block gives you the value of the last tick.


Last Tick

Current Stat

This block gives you the Current Stat value.

Current stat list

This block gives you a list of the cuurent stats of the last 1000 tick values.
Current stat list

Tick list

This block gives you a list of the last 1000 tick values.
Ticks list

Last Digits List

This block gives you a list of the last digits of the last 1000 tick values.
Last digits list

Market Direction:

This block is used to determine if the market price moves in the selected
direction or not. It gives you a value of "True" or "False".
Direction isRise

Examples:

1. If the selected direction is "Rise", and the previous tick value is less than
the current tick value, the output will be "True". Otherwise, the output will be
an empty string.

2. If the selected direction is "Fall", and the previous tick value is more than
the current tick value, the output will be "True". Otherwise, the output will be
an empty string.

Is Candle Back?

This block returns "True" if the last candle is black. It can be placed
anywhere on the canvas except within the Trade parameters root block.

Is candleblack?

The term "candle" refers to each bar on the candlestick chart. Each candle
represents four market prices for the selected time interval:

Each candlestick on the chart represents 4 market prices for the selected
time interval:

- Open price: the opening price

- High price: the highest price

- Low price: the lowest price

- Close price: the closing price

A black (or red) candle indicates that the open price is higher than the close
price. This represents a downward movement of the market price.
A white (or green) candle indicates that the open price is lower than the
close price. This represents an upward movement of the market price.

The time interval for each candle can be set from one minute to one day.

Red Candle Value (1)

This block gives you the specified candle value for a selected time interval. You can
choose which value you want:

Open: the opening price

- High: the highest price

- Low: the lowest price

- Close: the closing price

- Open time: the opening time stamp

In the example below, the opening price is selected, which is then assigned
to a variable called "op".

1In candles list readOpen# from endwith interval:Defaultsetopto

Red Candle Value (2)

This block gives you the selected candle value such as open price, close
price, high price, low price, and open time. It requires a candle as an input
parameter

This block requires a list of candles as an input parameter.

In this example, the open prices from a list of candles are assigned to a
variable called "cl".
Create a List of candle Values (1)

This block gives you the selected candle value from a list of candles within the selected
time interval. You can choose from open price, close price, high price, low price, and
open time.

In this example, the open prices from a list of candles are assigned to a variable called
"candle_list".

Create a List of candle Values (2)

This block gives you the selected candle value from a list of candles. You can choose
from open price, close price, high price, low price, and open time.

This block requires a list of candles as an input parameter.

In this example, the open prices from a list of candles are assigned to a
variable called "cl".

Get candle :

This block gives you a specific candle from within the selected time interval.

In this example, the open price of a candle is assigned to the variable


"candle_open_price".

2in candle list get # from endwith interval:DefaultReadOpen Timevalue in ca


ndlesetcandle_open_priceto
In the above example it is assumed that variable candle_open_price is
processed somewhere within other blocks.

PreviousNext

Get candle List :

This block gives you a list of candles within a selected time interval.

In this example, this block is used with another block to get the open prices
from a list of candles. The open prices are then assigned to the variable
called "cl".

Candles List with interval here 2:DefaultMake a list ofOpenvalues from candl
es listsetclto

CONTRACT :

LAST TRADE RESULT:

You can check the result of the last trade with this block. It can only be placed within the
"Restart trading conditions" root block.

If "Win" is selected, it will return "True" if your last trade was successful.
Otherwise, it will return an empty string.

If "Loss" is selected, it will return "True" if your last trade was unsuccessful.
Otherwise, it will return an empty string.

Contract Details:
You can choose to see one of the following:

- Deal reference ID: the reference ID of the contract

- Purchase price: the purchase price (stake) of the contract

- Payout: the payout of the contract

- Profit: the profit you’ve earned

- Contract type: the name of the contract type such as Rise, Fall, Touch, No
Touch, etс.

- Entry time: the starting time of the contract

- Entry value: the value of the first tick of the contract

- Exit time: the contract expiration time

- Exit value: the value of the last tick of the contract

- Barrier: the barrier value of the contract (applicable to barrier-based trade


types such as stays in/out, touch/no touch, etc.)

- Result: the result of the last contract: "win" or "loss"

Profit/Loss From Selling:

This block gives you the potential profit or loss if you decide to sell your contract. It can
only be used within the "Sell conditions" root block.

In the example below, the contract will only be sold if the potential profit or
loss is more than the stake.

ifthenSell is availableifthenSell profit/lossstake=Sell at market price3. Sell co


nditions

Can contract be sold?


This block helps you check if your contract can be sold. If your contract can
be sold, it returns “True”. Otherwise, it returns an empty string.
Sell is available

Potential payout

This block returns the potential payout for the selected trade type. This block
can be used only in the "Purchase conditions" root block.
Payout

Potential payout

This block returns the potential payout for the selected trade type. This block
can be used only in the "Purchase conditions" root block.
Payout

Account Balance:

The only input parameter determines how block output is going to be


formatted. In case if the input parameter is "string" then the account
currency will be added.

Example output of the below example will be:

1. for "string": 1325.68 USD

2. for "number": 1325.68

Total profit/loss
This block gives you the total profit/loss of your trading strategy since your
bot started running. You can reset this by clicking “Clear stats” on the
Transaction Stats window, or by refreshing this page in your browser.
Total profit/loss

Number of runs

This block gives you the total number of times your bot has run. You can
reset this by clicking “Clear stats” on the Transaction Stats window, or by
refreshing this page in your browser.

Number of runs

CUSTOM FUNCTIONS:

Function : do something

This block creates a function, which is a group of instructions that can be executed at
any time. Place other blocks in here to perform any kind of action that you need in your
strategy. When all the instructions in a function have been carried out, your bot will
continue with the remaining blocks in your strategy. Click the “do something” field to
give it a name of your choice. Click the plus icon to send a value (as a named variable)
to your function.
Function that returns a value

This block is similar to the one above, except that this returns a value. The
returned value can be assigned to a variable of your choice.
functiondo something return
Conditional Return: Used within a function block, this block returns a value
when a specific condition is true.
ifreturn
Set Vairable:

This block assigns a given value to a variable, creating the variable if it


doesn't already exist.

setNext%20Trade%20Conditionto

A variable is among the most important and powerful components in


creating a bot. It is a way to store information, either as text or numbers. The
information stored as a variable can be used and changed according to the
given instructions. Variables can be given any name, but usually they are
given useful, symbolic names so that it is easier to call them during the
execution of instructions.

Creating a variable

1. From the block library, enter a name for the new variable and click Create.

2. The new variable will appear as a block under Set variable.

Print:

This block displays a dialog box with a customised message. When the dialog box is
displayed, your strategy is paused and will only resume after you click "OK".

Abcprint

Request an Print:

This block displays a dialog box that uses a


customised message to prompt for an input. The
input can be either a string of text or a number
and can be assigned to a variable. When the
dialog box is displayed, your strategy is paused
and will only resume after you enter a response
and click "OK".
prompt forstringwith messageabc

Notify

This block displays a message. You can specify the color of the message and
choose from 6 different sound options.
abcNotifygreenwith sound:Silent

Notify Telegram:

This block sends a message to a Telegram channel. You will need to create your own
Telegram bot to use this block.

Here’s how:
1. Create a Telegram bot and get your Telegram
API token. Read more on how to create bots in
Telegram here:
https://core.telegram.org/bots#6-botfather
2. Start a chat with your newly created Telegram
bot and make sure to send it some messages
before proceeding to the next step. (e.g. Hello
Bot!)
3. Get the chat ID using the Telegram REST API
(read more:
https://core.telegram.org/bots/api#getupdates)
- Visit the following URL, make sure to replace
<access_token> with the Telegram API token
you created in Step 1:
https://api.telegram.org/bot<access_token>/get
Updates
- Find the chat ID property in the response, and
copy the value of the id property
4. Come back to Deriv Bot and add the Notify
Telegram block to the workspace. Paste the
Telegram API token and chat ID into the block
fields accordingly.
access_tokenchat_idEnjoy!Notify TelegramAcces
s Token:Chat ID:Message:

Time:

Second Since Epoch


This block returns the number of
seconds since January 1st, 1970.Learn
more
Seconds Since Epoch
Delayed run

This block delays execution for a


given number of seconds. You can
place any blocks within this block. The
execution of other blocks in your
strategy will be paused until the
instructions in this block are carried
out.
Run aftersecond(s)
Tick Delayed run
This block delays execution for a
given number of ticks. You can place
any blocks within this block. The
execution of other blocks in your
strategy will be paused until the
instructions in this block are carried
out.
Run aftertick(s)
Convert to timestamp
This block converts a string of text
that represents the date and time into
seconds since the Unix Epoch (1
January 1970). The time and time
zone offset are optional. Example:
2019-01-01 21:03:45 GMT+0800 will
be converted to 1546347825.Learn
more
yyyy-mm-dd hh:mm:ssTo timestamp
Convert to date/time
This block converts the number of
seconds since the Unix Epoch (1
January 1970) into a string of text
representing the date and time.Learn
more
0To date/time

Math:

Number
Enter an integer or fractional number
into this block. Please use `.` as a
decimal separator for fractional
numbers.
0
Arithmetical operations
This block performs arithmetic
operations between two
numbers.Learn more
11+
Operations on a given number
This block performs the selected
operations to a given number.Learn
more
9square root
Trigonometric functions
This block performs trigonometric
functions.
45sin
Mathematical constants
This block gives you the selected
constant values.
π
Test a number
This block tests a given number
according to the selection and it
returns a value of “True” or “False”.
Available options: Even, Odd, Prime,
Whole, Positive, Negative, Divisible
0iseven
Change variable
This block adds the given number to
the selected variable.
1changeitemby
Aggregate operations
This block performs the following
operations on a given list: sum,
minimum, maximum, average,
median, mode, antimode, standard
deviation, random item.
sumof list
Rounding operation
This block rounds a given number
according to the selection: round,
round up, round down.
3.1round
Remainder after division
Returns the remainder after the
division of the given numbers.
6410remainder of÷
Constrain within a range
This block constrains a given number
so that it is within a set range.Learn
more
constrainlowhigh
Random integer

This block gives you a random number


from within a set range.
1100random integer fromto
Random fraction number
This block gives you a random fraction
between 0.0 to 1.0.
random fraction

Text:

Text
A block that can contain text.
abc
Text join
Creates a single text string from
combining the text value of each
attached item, without spaces in
between. The number of items can be
added accordingly.
abcsettextto create text with
Text Append
Appends a given text to a variable.
abctotextappend text
Text String Length
Returns the number of characters of a
given string of text, including
numbers, spaces, punctuation marks,
and symbols.
length of
Text Is empty
Tests whether a string of text is
empty. Returns a boolean value (true
or false).
textis empty
Search for string
Searches through a string of text for a
specific occurrence of a given
character or word, and returns the
position.
in textfindfirstoccurence of text
Get character
Returns the specific character from a
given string of text according to the
selected option.
in textgetletter #
Get substring
Returns a specific portion of a given
string of text.
in textletter #letter #text02
Change text case

Changes the capitalisation of a string


of text to Upper case, Lower case,
Title case.
abcTransformtoUPPER CASE
Trim spaces
Trims the spaces within a given string
or text.
abctrim spaces fromboth sidesof

LOGIC :

Conditional block
This block evaluates a statement and
will perform an action only when the
statement is true.Learn more
ifthen
Compare
This block compares two values and is
used to build a conditional structure.
=
Logic operation
This block performs the "AND" or the
"OR" logic operation.Learn more
and
Logic negation
This block converts the boolean value
(true or false) to its opposite.
not
True-False
This is a single block that returns a
boolean value, either true or false.
true
Null

This block assigns a null value to an


item or statement.
null
Test value
This block tests if a given value is true
or false and returns “True” or “False”
accordingly.
testif trueif false

LIST :

Create list
This block creates a list with strings
and numbers.
setlistto create list with
Repeat an item
Creates a list with a given item
repeated for a specific number of
times.
5create list with itemrepeatedtimes
List Length
This block gives you the total number
of items in a given list.
length of
Is list empty?
This block checks if a given list is
empty. It returns “True” if the list is
empty, “False” if otherwise.
listis empty
List item position
This block gives you the position of an
item in a given list.
in listfindfirstoccurence of item
Get list item
This block gives you the value of a
specific item in a list, given the
position of the item. It can also
remove the item from the list.
in listget#
Set list item

This block replaces a specific item in a


list with another given item. It can
also insert the new item in the list at a
specific position.
in listset#as
Get sub-list
This block creates a list of items from
an existing list, using specific item
positions.
in listget sub-list from##
Create list from text
This block creates a list from a given
string of text, splitting it with the
given delimiter. It can also join items
in a list into a string of text.
makelist from text with delimiter ,
Sort list
Sorts the items in a given list, by their
numeric or alphabetical value, in
either ascending or descending order.
sortnumericascending
LOOPS:

Repeat (1)
This block repeats the instructions
contained within for a specific number
of times.
repeat10timesdo
Repeat (2)
This block is similar to the block
above, except that the number of
times it repeats is determined by a
given variable.
repeattimesdo
Repeat While/Until
This block repeats instructions as long
as a given condition is true.Learn
more
repeatwhiledo
Iterate (1)
This block uses the variable “i” to
control the iterations. With each
iteration, the value of “i” is
determined by the items in a given
list.Learn more
count withifromtobydo
Iterate (2)

This block uses the variable "i" to


control the iterations. With each
iteration, the value of "i" is
determined by the items in a given
list.Learn more
for each itemiin listdo
Break out/continue
This block is used to either terminate
or continue a loop, and can be placed
anywhere within a loop block.Learn
more
break outof loop

Miscellaneous

Loads from URL


This block allows you to load blocks
from a URL if you have them stored on
a remote server, and they will be
loaded only when your bot runs.
Load block from URL:http://
www.example.com/block.xml
Ignore
Use this block if you want some
instructions to be ignored when your
bot runs. Instructions within this block
won’t be executed.
Ignore
Console

This block displays messages in the


developer's console with an input that
can be either a string of text, a
number, boolean, or an array of
data.Learn more
abcConsoleLogvalue:

You might also like