Author Topic: green up maths  (Read 547 times)

  • All members
  • Posts: 250
  • Karma: +1/-0
green up maths
« on: Sun, 10 June, 2018, 19:01 »
I am trying to write a trigger for greening up.

I want to be able to mimic the betfair cashout option, where clicking gives a reasonably equal amount to all outcomes, but I am struggling with the maths.

its a football strategy, using O/U 1.5 goals.

At some point in the game, I place an initial back bet for £10, at whatever price is on offer, then I place another £10 back bet once the first is matched, at bm_1_backp + 0.5, and repeat this, adding 0.5 to each last back price, until I have placed 4 back bets, and this gives £40 outlay, consisting of £10 at 4 different prices.

When a goal is scored, the price goes down, and it is at this time that I want to place my lay bet to green up, and I cannot figure the maths out to do this in the same way that betfair does.

Can anybody help?



  • All members
  • Posts: 618
  • Karma: +32/-5
  • Gender: Male
Re: green up maths
« Reply #1 on: Sun, 10 June, 2018, 20:17 »
Theres loads of examples in the triggered betting forum or learning forum.

you have to build it, its not inbuilt except on the engineer mode, tradeout all button, but that takes the lay price, it doesnt put in a lay price like you want to.

  • All members
  • Posts: 250
  • Karma: +1/-0
Re: green up maths
« Reply #2 on: Sun, 10 June, 2018, 20:45 »
Hi Larp,

Thanks for the response.

Yes, I have seen and downloaded the trigger, but they all look to use the green method with ticks or percentage, and that isn't what I want.

I want to do a lay, at current price, with the correct amount of stake, such that a green is equal on all outcomes. I am not comfortable using black box 'green up' - because I am not in control of it that way, and even while there are many features of MFP that can do many complex things, I still prefer to write my own.

For the standard Back then Lay to green, the maths is simple enough, where stake = backStake * backOdds / layOdds

But mine is moire complicated.

I will figure it out eventually if nobody has an immediate answer



  • Moderator
  • Posts: 2854
  • Karma: +233/-0
Re: green up maths
« Reply #3 on: Mon, 11 June, 2018, 17:53 »
the selection variable tradeout_net is effectively the cash-out figure on a given selection. You mention you are trading on one selection only, so this should be what you need.

If you are trading multiple selections in the same market, you need to update a user variable for the cash-out on all selections in the market. e.g:

trigger 1
set user variable, name: cash_out, value: 0, indiv. for each market, first matching selection, execute: 0.3  
trigger 2
set user variable, name: cash_out, value: cash_out+tradeout_net, indiv. for each market, all matching selections, execute: 0.3

so user variable cash_out will hold an up-to-date value of the market "cash out" and you can apply your own conditions using this user variable:

trigger 3
green up, ticks: -1, all matching selections, condition: selections trigger expression cash_out is greater than 10

also might be worth having a look at how unticking the green up option "against last matched bet" might help you, as this will green up all the bets on a selection.    
Please read the following disclaimer with regards to the information you may request and obtain on our forum. This specifically concerns trigger files and various instructions as to how to implement a strategy.

  • Administrator
  • Posts: 7216
  • Karma: +238/-0
  • Gender: Female
Re: green up maths
« Reply #4 on: Fri, 15 June, 2018, 20:15 »

You can find all the green-up formulae here:

10 Facts About Green-up in MarketFeeder Pro
Always try your triggers in Test Mode before switching to real money!

Follow us on Twitter.

Usuários brasileiros, bem vindos ao nosso WhatsApp chat!

Присоединяйтесь к нашей официальной группе ВКонтакте!