Author Topic: Condition met for x time prior to trigger  (Read 315 times)

  • All members
  • Posts: 8
Condition met for x time prior to trigger
« on: 19 Oct 2022, 09:19 »
Good Morning,

To describe what I'm looking for I will have to describe what I have in mind. I want to lay before the off and green up or distribute loss whilst in-play. The problem I'm having is a condition attached to distributing the loss is the selection needs to be ranked 1 in-play. The further issue with this is it triggers instantly once this plus numerous conditions are met.

From what I've observed is that the selection can be rank 1 for a second and move to a different rank. So I'm looking for a condition that will time how long the selection is rank 1 in-play, and once it's rank 1 for a pre-determined sum of time, trigger. 

E.g. 1. index 3 is rank 1 in-play for 5 seconds, trigger.

2. Index 3 is rank 1 in-play for 3 seconds don't trigger. If changed to rank 4 then back to rank 1 for 5 seconds trigger.

If any questions please let me know.

  • All members
  • Posts: 8
Re: Condition met for x time prior to trigger
« Reply #1 on: 21 Oct 2022, 12:00 »
Good Afternoon, 

Any update? 

  • Administrator
  • Posts: 8937
  • Gender: Female
*
Re: Condition met for x time prior to trigger
« Reply #2 on: 29 Oct 2022, 21:34 »
Hello!

Please see your triggers attached.

Use the constants inside the file to adjust the trigger settings.

The idea behind this is to remember the index of each new favourite and the time it has changed, e.g. switched from 1st selection to 5th or then to 3rd and so on. You do it in the trigger called "marking the time when favourite has changed", and the important thing is to execute this trigger repeatedly, hence "no often than 0.3 sec".

Then you simply place the stop-loss bet after (now_time - last_fav_time)/mf_second is equal or greater than the predefined number of seconds you specify.

Make sure you've tested the triggers in Test Mode before you switch to real money. I recommend testing triggers in Time Machine, as you can run your strategy by multiple markets in minutes, and the data is very cheap. 

If you'd like to make any changes to the original trigger description, please make a new trigger request.
Always try your triggers in Test Mode before switching to real money!

Follow us on Twitter.

Join our WhatsApp chat!

Присоединяйтесь к официальному Telegram-каналу!

 

Please note, BetFair is seems to be currently OFFLINE