FxPro Quant

Dear herp,

Usually strategies like this require using variables to store some values between ticks.
However, in this particular case you can avoid it. Your strategy can be implemented with the following rules:

  1. MA Fast [2] < MA Slow [2]
  2. MA Fast [1] >= MA Slow [1]
  3. New bar

In square brackets candle index is shown. 0 - means current candle, 1 - previous candle, etc.
This way your position will be opened only when crossover happened on the first tick of the next candle. And new position will be opened only when Fast MA return below Slow and cross it upward again.

Kind regards,
FxPro Team

1 Like

Hi, sorry for the poor translation but I do not speak English well. I try to be brief. I want to know how to set limits on income and losses, apart from the “Stop Loss” and “Take Profit” established in the modules to buy and sell. That is, reach close operation when certain Pips gain or loss, a kind of Stop Loss and Take Profit hidden. Thank you very much.

Dear Torre777,

You can do this using the ‘Order Data’ node. You need to set Parameter to ‘Profit pips’ and compare it to desired value. It should be as follows:

IF
Order Data (Profit Pips) >= Target Profit in pips
OR
Order Data (Profit Pips) <= Max Loss in pips
THEN
Close Order


Kind regards,
FxPro Team

Thank you very much for the help

Hello guys, please advise with this:

I want strategy to open new trade only above the entry price of last opened short trade. Trades magic should be the same.

Lets say I have opened short trades at 1.050, 1.060, and 1.080. I want new short trade (with same magic) opened only at price above 1.080.

Please advise Iam struggling with this for days.


This is how iam trying to do it - buy trade example

hi! how to make so that after closing the order did not open a new one in the same direction and waited for an opposite signal? and no matter how he is closed to stop or manually

Dear mike111FXX,

You can do this by using the Number Variable node to store values between ticks.

See example on the screenshot below:

Kind regards,
FxPro Team

Dear lexahs,

If you are using the same magic index for Buy and Sell positions, you can save the last open time for Buy and for Sell orders. You will have 3 possible situations:

  1. Buy time > sell time => last position was Buy
  2. Buy time < sell time => last position was Sell
  3. Not one of the above => there was no trade

See example below:


Kind regards,
FxPro Team

Dear FxPro support

Thnak you for the answer ! I have been trying to implement it for days, but it is still not working. Here is the screenshot: Please let me know what is wrong

Dear mike111FXX,

Could you please export your strategy and send it to <[email protected]>? Please add the link to this thread in your email as well.

You can export your strategy from FxPro Quant via Menu -> Export to file.

Kind regards,
FxPro Team

hello I can’t figure out to to make this help me please
I’m trying to make better take profit stop loss system I want to make the ea close the position when profit reach 1 or 2% gain or 3% floating equities loss.
I don’t want to use pips system I want the equities gain loss % by percentage help me out please !

Dear abanobb,

You may use the Account Node, found under the ‘Info’ section. Selecting ‘Profit’ will return Profit and Loss in opened position, while selecting ‘Equity’ will return currency account equity.
This can also be calculated via the single order profit, for which you may use the Order Data Node with parameters set to Profit.

Kind regards,
FxPro team

Hello, I would like to know how to do to make an order not occur if the Spread goes up to a certain amount, for example 4 or 40?

Another question is, how can we do to avoid open operations during certain days of the week, for example from Friday at 20:30 until Monday at 01:30 and every week?

Thank you very much

how can I make martingale system what should I use I want to make grid + martingale system

I know how to make the grid but the martingale that I don’t know help me please

Dear Torre777,

Please use Ask - Bid to see the current spread value. Then, you may transform points to a whole number and compare it to the desired value. This comparison should be added to the AND node as one of the conditions to open a position.


Kind regards,
FxPro Team

Dear Torre777,

This can be done by checking date and time components like Day of Week, Hour and Minutes individually and combining them into one logical expression. See example on screenshot.


Kind regards,
FxPro Team

Dear abanobb,

In FxPro Quant, orders are usually managed with a Magic Index. Using this Index, the EA can distinguish different orders. If you have more than one order per Magic Index, you will not be able to get individual info for the order or modify it or close it on its own.

For the time being, it is not possible to create many martingale strategies in FxPro Quant. You may only create those that have a limited amount of steps or do not require information or action for individual orders.

Kind regards,
FxPro Team

HI

I am having a lot trouble trying to set up pending orders in the form of a sell stop and buy stop.
I would like to hedge my moving average cross by placing a sell stop 100 points away from a buy trade; alternatively I would like to place a buy stop 50 points from the current price and a sell stop 50 points from the current price.

I have tried to set price and the take profit and stop loss numerous times, but all I get is error message after error message ie. ordersend error 130.

PLEASE ASSIST

Got the pending order open, now my problem is that it keeps sending more than one order. how do i get the EA to send only one pending order per confirmation.