Thread Rating:

baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 1:56:41 AM permalink
Hello guys,

I'm new to this forum and want to thank anyone in advance for reading this thread.



Any moderate to serious baccarat players in any casino have their own strategies on how to win at the game. They will tell you, often passionately, about pattern analysis/recognition, betting systems, money management, etc. Almost always, the baccarat player will try to analyze the scoreboard as much as possible and bet based on their "pattern recognition." It can be as simple as riding/fighting the line or some even try to analyze the "Chinese line" aka Bead Plate at the top of the scoreboard, where the each result is recorded vertically and horizontally after 6-7 hands. It is interesting though because if you ask any of the players if they really, REALLY believe that there's any real pattern recognition/system/strategy that will allow them to win consistently in the long run, almost every player will humbly tell you there is none, and that it's all bs lol. Yet they do the same thing over and over again..

I'm not judging tho, as I'm exactly one of the baccarat players I've described above lol. After many years of heartaches and countless losses, I asked myself the ultimate question, "Is there a (profitable) pattern recognition or not??" and told myself that I either find some sort of working strategy or seriously consider quitting the game altogether.

Over the years, I have invested thousands of hours gathering thousands of shoe results manually using the game simulation on the Wizard of Odds website, analyzing the patterns and trying to figure out any possible strategies. Unfortunately, I need a lot more data to do my research, like at least hundreds of thousand more shoes, which would take me an unbelievable amount of time. I'm sure there's a lot easier way of gathering the data by programming but I don't know anything about programming and need someone to do it for me or at least show me ropes so I can learn how to do it myself. (I want the data based on actual eight decks of cards just like the Wizard of Odds, not just a random number generator)

To make things a little bit more complicated, I specifically analyzing and need lots of data of the three small rectangles with empty/solid circles and slashes on the Scoreboard also known as Big Eye Boy, Small Road, and Cockroach Pig. I'm not exactly sure how they work but the information can also be found in the Wizard of Odds website.

And if possible, I would really really want the data to be converted to numbers so I can easily search through them and analyze the patterns. If there's only one spot in the column, it'd be written as "0" and two to nine spots would be written "2-9" accordingly, and ten or more would have letter "T" and designated exactly how many after the data is written. For example, (B= red circle/slash, P= blue circle/slash) not actual Banker/Player and it doesn't matter which color comes first.

B PPP BB P BB P BBBBBBB PP BB PPP B PPPPPPPPPPPP BB P B P BB P

would be

03202072230T200020 twelve


So is there any genius coders out there that can help a fellow human? Show me some ropes please! I'd be forever grateful. lol. I really need to do this. Thank you so much!
SOOPOO
SOOPOO 
  • Threads: 123
  • Posts: 11495
Joined: Aug 8, 2010
Thanked by
Romes
May 27th, 2018 at 4:43:17 AM permalink
I can't help you with the code, but can I give you an analogy?

I have been watching apples fall from a tree (=losing at baccarat) for years and years. And this gravity thing (=house edge in baccarat) always seems to make the apples go down instead of up. Can someone help me figure out how to make the apples go up (=win at baccarat)?

In summary, you have to understand the concept that the next hand has nothing to do with the previous hand in baccarat. So noticing a pattern after it has occurred is not relevant to the NEXT hand.
GlenG
GlenG
  • Threads: 11
  • Posts: 410
Joined: Feb 5, 2018
May 27th, 2018 at 5:17:06 AM permalink
Quote: SOOPOO

I can't help you with the code, but can I give you an analogy?

I have been watching apples fall from a tree (=losing at baccarat) for years and years. And this gravity thing (=house edge in baccarat) always seems to make the apples go down instead of up. Can someone help me figure out how to make the apples go up (=win at baccarat)?

In summary, you have to understand the concept that the next hand has nothing to do with the previous hand in baccarat. So noticing a pattern after it has occurred is not relevant to the NEXT hand.



Yup..Thats why the TV screen is there on most games.
EdCollins
EdCollins
  • Threads: 20
  • Posts: 1739
Joined: Oct 21, 2011
May 27th, 2018 at 7:26:41 AM permalink
Quote: baccaratwizard

B PPP BB P BB P BBBBBBB PP BB PPP B PPPPPPPPPPPP BB P B P BB P

would be

03202072230T200020 twelve

So is there any genius coders out there that can help a fellow human? Show me some ropes please! I'd be forever grateful. lol. I really need to do this. Thank you so much!

That's an easy task. Should take me 20 minutes or less. My preference would be to code it in Excel. I'd set it up so you could select the raw data from a text file of your choosing. The macro would read that file, and output the desired result either into another text file or into a worksheet.
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 11:31:21 AM permalink
hahah i understand 100%. I read and thought a lot about gambling and I agree with what you just said. But at the same time, maybe I just really need to see it myself. Thanks for the response though.
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 11:48:54 AM permalink
Quote: EdCollins

That's an easy task. Should take me 20 minutes or less. My preference would be to code it in Excel. I'd set it up so you could select the raw data from a text file of your choosing. The macro would read that file, and output the desired result either into another text file or into a worksheet.



Thank you so much!!! You gave me hope!!!!

please allow me to remind you that

I need a simulation with actual eight deck, not just a random number generator. The one at the Wizard of Odds website would be ideal.

I'm not exactly sure if the cut card affects the result in any way. The casino always removes a decent amount of cards at the beginning and don't use some at the end. I would think that it doesn't affect the results though.

Also, I'm not interested in the main Banker/Player Big road. I need the data just for the other three roads at the bottom of the screen. They're also red/blue but not necessarily banker/player. They are recorded by comparing column sizes of the previous roads..? Confusing stuff..

Lastly, I need the data to be converted to the format with 0's, 2-9's and T's... just like I described above. Color doesn't matter.

RRR BB R B RRRRRRRRRRR BBBB R B R B RR B

would be


3200T4000020 eleven.


Thank you so much boss. If you can help me any or all of the parts I needed, I will appreciate it dearly, as you will have saved me tens of thousands of hours. When I get out of the financial struggle in the future in one way or the other, I will seriously send you a gift card or paypal you some gratitude or something LOL. seriously. thank you.
EdCollins
EdCollins
  • Threads: 20
  • Posts: 1739
Joined: Oct 21, 2011
May 27th, 2018 at 12:40:50 PM permalink
Ah, my mistake. When you said, "I have invested thousands of hours gathering thousands of shoe results manually using the game simulation on the Wizard of Odds website, analyzing the patterns and trying to figure out any possible strategies." I thought you wanted all of THAT data that you already had converted into your desired format. THAT would be just a 20 minute task, to read your file with that data in it, and convert that to your described format.

Now that I read you post a second time, I see that you did indeed say that you, "need a lot MORE data to do my research, like at least hundreds of thousand more shoes..." etc.

To set all of that up, to write what basically amounts to a baccarat simulation, is indeed a bit more work. It's not a LOT of work... just setting up the arrays for the shoe, shuffling the deck, setting up the loops to run the simulation for x amount of hands, saving the results, etc. It's still something I can probably help with... but I won't be able to get to it for awhile. That's definitely not something I can bang out in 15 or 20 minutes. :(
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 12:48:13 PM permalink
Quote: EdCollins

Ah, my mistake. When you said, "I have invested thousands of hours gathering thousands of shoe results manually using the game simulation on the Wizard of Odds website, analyzing the patterns and trying to figure out any possible strategies." I thought you wanted all of THAT data that you already had converted into your desired format. THAT would be just a 20 minute task, to read your file with that data in it, and convert that to your described format.

Now that I read you post a second time, I see that you did indeed say that you, "need a lot MORE data to do my research, like at least hundreds of thousand more shoes..." etc.

To set all of that up, to write what basically amounts to a baccarat simulation, is indeed a bit more work. It's not a LOT of work... just setting up the arrays for the shoe, shuffling the deck, setting up the loops to run the simulation for x amount of hands, saving the results, etc. It's still something I can probably help with... but I won't be able to get to it for awhile. That's definitely not something I can bang out in 15 or 20 minutes. :(





awww mannnnn. If you can still get to it one day, I'll be very grateful. Maybe show me some ropes to learn it myself? I meant it when I said I'll give back to you lol! I never let good deed go unnoticed. Thank you!
FinsRule
FinsRule
  • Threads: 129
  • Posts: 3945
Joined: Dec 23, 2009
Thanked by
baccaratwizard
May 27th, 2018 at 12:58:12 PM permalink
I feel bad for you. You wasted thousands of hours of your life!

We will say 4000 hours.

That’s 2 years of full time work or 6 months of life.

At $10 an hour. 40,000 dollars! That’s how much more you’d have had you just taken a crappy job instead.
DogHand
DogHand
  • Threads: 2
  • Posts: 1828
Joined: Sep 24, 2011
May 27th, 2018 at 1:23:00 PM permalink
Quote: baccaratwizard

<snip>Lastly, I need the data to be converted to the format with 0's, 2-9's and T's... just like I described above. Color doesn't matter.

RRR BB R B RRRRRRRRRRR BBBB R B R B RR B

would be


3200T4000020 eleven.<snip>



baccaratwizard,

Quick questions:

1. Why do you use a zero for a singleton rather than a one?

2. Do you really want to spell numbers greater than ten?

Dog Hand
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 1:38:22 PM permalink
Quote: DogHand

baccaratwizard,

Quick questions:

1. Why do you use a zero for a singleton rather than a one?

2. Do you really want to spell numbers greater than ten?

Dog Hand



Answers:

1. It can be "1" . It doesn't matter. I chose "0" because it was easier for to type that way.

2. Yes. I use the letter "T" which stands for ten or above because I want it to be a single digit. Having a double digit would disrupt my searching process.

thank you.
OnceDear
OnceDear
  • Threads: 64
  • Posts: 7540
Joined: Jun 1, 2014
May 27th, 2018 at 1:45:02 PM permalink
Quote: baccaratwizard

Hello guys,

I'm new to this forum and want to thank anyone in advance for reading this thread.


Hi BaccaratWizard,
Welcome to the forum.
Quote:

After many years of heartaches and countless losses, I asked myself the ultimate question, "Is there a (profitable) pattern recognition or not??" and told myself that I either find some sort of working strategy or seriously consider quitting the game altogether.

Hint: Seriously consider quitting the game altogether
Quote:

Over the years, I have invested thousands of hours gathering thousands of shoe results manually using the game simulation on the Wizard of Odds website


seriously consider quitting the game altogether
Quote:

Unfortunately, I need a lot more data to do my research...I'm sure there's a lot easier way of gathering the data by programming ...I want the data based on actual eight decks of cards just like the Wizard of Odds, not just a random number generator.


Erm..... Do you think with the Wizard's simulator that there is a real shoe full of 8 decks of real cards. Hint: I think you'll find that the nature of simulation is that he uses an RNG to shuffle an array of numbers that represent those cards. Or, maybe you want to programatically sit and watch millions of live dealer sessions and derive your test data from that? Can be done but totally pointless.

Regards OnceDear
Psalm 25:16 Turn to me and be gracious to me, for I am lonely and afflicted. Proverbs 18:2 A fool finds no satisfaction in trying to understand, for he would rather express his own opinion.
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 1:47:55 PM permalink
I just didn't want a number generator that doesn't use the card values. Not sure if it matters but I wanted it to be closest to the "real" game as possible. Thanks for your input.
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 1:52:53 PM permalink
i appreciate all the input from everyone but I have to say that this is something I have to do.

If anyone can actually guide me on how to gather the data, i'll be thankful.

any possible excel experts?
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 1:55:07 PM permalink
Quote: OnceDear

Hi BaccaratWizard,
Welcome to the forum.
Hint: Seriously consider quitting the game altogether

seriously consider quitting the game altogether

Erm..... Do you think with the Wizard's simulator that there is a real shoe full of 8 decks of real cards. Hint: I think you'll find that the nature of simulation is that he uses an RNG to shuffle an array of numbers that represent those cards. Or, maybe you want to programatically sit and watch millions of live dealer sessions and derive your test data from that? Can be done but totally pointless.

Regards OnceDear



i think there are number generators where you just put the odds in, like fourty something percent for banker/player and 9 for ties. and they just generate the shoe results.

Like i said, I don't know if it matters at all, but I just wanted it to be as close to the real game as possible by dealing out each hand.

so yes the generator you speak of would work.
OnceDear
OnceDear
  • Threads: 64
  • Posts: 7540
Joined: Jun 1, 2014
May 27th, 2018 at 2:03:33 PM permalink
Quote: baccaratwizard



Like i said, I don't know if it matters at all, but I just wanted it to be as close to the real game as possible by dealing out each hand.

so yes the generator you speak of would work.



OK, so as I see it, you are satisfied with realistic outcomes where the decks of cards are virtual and shuffled by a reliable rng so as to appear like real cards, then fed into sequential games to give realistic results.

Well, in that case, it's not hard to do. I'd advocate using random.org as the source of randomness. The rest is pretty simple programming to simulate the games. Could be done in fairly complex coding languages, or could be knocked up as an excel workbook with a bunch of formulae and procedures.

What do you propose to pay? especially for something where you get verbose descriptions of how it works?
What were your thousands of hours of wasted time worth?

You know there's no Holy Grail, don't you?
Psalm 25:16 Turn to me and be gracious to me, for I am lonely and afflicted. Proverbs 18:2 A fool finds no satisfaction in trying to understand, for he would rather express his own opinion.
baccaratwizard
baccaratwizard
  • Threads: 2
  • Posts: 10
Joined: May 26, 2018
May 27th, 2018 at 2:09:21 PM permalink
Quote: OnceDear

OK, so as I see it, you are satisfied with realistic outcomes where the decks of cards are virtual and shuffled by a reliable rng so as to appear like real cards, then fed into sequential games to give realistic results.

Well, in that case, it's not hard to do. I'd advocate using as the source of randomness. The rest is pretty simple programming to simulate the games. Could be done in fairly complex coding languages, or could be knocked up as an excel workbook with a bunch of formulae and procedures.

What do you propose to pay? especially for something where you get verbose descriptions of how it works?
What were your thousands of hours of wasted time worth?

You know there's no Holy Grail, don't you?



yes thank you i'll look into excel workbook. seems like a good starting point.

I'm rather looking for a closure. ive already spent enough time and money chasing lol. i understand people may see it as a dumb thing to do, but once again, this is something that i need to see for myself to move on. thank you for your help.
AlexR
AlexR
  • Threads: 5
  • Posts: 34
Joined: Jul 22, 2018
August 5th, 2018 at 7:50:04 PM permalink
I recently wrote a Baccarat simulator in MATLAB that I could try to add some pattern-recording features to. It currently only counts total wins and losses over a given number of games (using a specified number of decks shuffled together, including a cut card). As you can see, it fairly closely approximates the expected outcomes:

Games played: 10000 (8 deck)
Banker wins: 4616
Player wins: 4378
Ties: 1006
"At gambling, the deadly sin is to mistake bad play for bad luck." —Ian Fleming
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 5th, 2018 at 11:37:44 PM permalink
Quote: AlexR

As you can see, it fairly closely approximates the expected outcomes:

Games played: 10000 (8 deck)
Banker wins: 4616
Player wins: 4378
Ties: 1006

ok
"fairly closely approximates"
Hmmm

the expected outcomes: (from the Wizard of Odds)
Banker wins: 45.8597%
Player wins: 44.6247%
Ties: 9.5156%

I think you may need to check your code for an error as
I have yet to see ties over 1k in 10k shoe sims in my simulations in Excel

the sample error should be way smaller, I would think



thank you for sharing!

The OP request for specific code is interesting...
to say the least

Sally
I Heart Vi Hart
AlexR
AlexR
  • Threads: 5
  • Posts: 34
Joined: Jul 22, 2018
August 6th, 2018 at 1:30:59 AM permalink
Hmm, you're right, something was wonky with the banker drawing rules, but now I've somehow made it worse, and I'm getting more player wins than banker (but at least the ties are about where they should be).
"At gambling, the deadly sin is to mistake bad play for bad luck." —Ian Fleming
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 6th, 2018 at 8:04:09 AM permalink
Quote: AlexR

Hmm, you're right, something was wonky with the banker drawing rules, but now I've somehow made it worse, and I'm getting more player wins than banker (but at least the ties are about where they should be).

that can happen.
I thought at 1st read you had 10000 shoes, now I see it is just 10000 games.
Is that rounds (hands) played?
If yes, that is different from 10,000 shoes.
Your sim should play by shoes as that is how players want to see the data. from there it is easy to have data go across shoes.

as to simulation results:
the sd of P (standard deviation of the probability) for the Tie is 0.2934%
10.3959% would be the 3 sigma above the point estimate
so I missed that for 10k games played

for 10k shoes
the sd of P for the Tie is 0.0325%
9.6458% would be the 4 sigma above the point estimate

sample of 10k shoes would be preferred over just 10k games played
I would say so
Sally
Last edited by: mustangsally on Aug 6, 2018
I Heart Vi Hart
AlexR
AlexR
  • Threads: 5
  • Posts: 34
Joined: Jul 22, 2018
August 6th, 2018 at 11:01:22 PM permalink
Here's a typical example of what it's giving me now after some revision. I can't seem to find the source of the problem.

Shoes played: 10000 (8 deck)
Hands played: 798198
Banker wins: 354628 (0.44429)
Player wins: 367258 (0.46011)
Ties: 76312 (0.09561)
"At gambling, the deadly sin is to mistake bad play for bad luck." —Ian Fleming
DogHand
DogHand
  • Threads: 2
  • Posts: 1828
Joined: Sep 24, 2011
August 7th, 2018 at 6:41:13 AM permalink
AlexR,

Perhaps if you post your code, I or someone else here can help you track down the error.

Hope this helps!

Dog Hand
Wizard
Administrator
Wizard
  • Threads: 1520
  • Posts: 27096
Joined: Oct 14, 2009
Thanked by
Romes
August 7th, 2018 at 8:41:19 AM permalink
My program still works and I can give you as many shoes as you like -- even millions of them. I can also format the output however you like. Of course, I will ask a professional rate for my time.

I do have to go on the record that you're wasting your time and money trying to find a baccarat system. They are all equally worthless in the end.
"For with much wisdom comes much sorrow." -- Ecclesiastes 1:18 (NIV)
ThatDonGuy
ThatDonGuy
  • Threads: 122
  • Posts: 6710
Joined: Jun 22, 2011
August 7th, 2018 at 4:48:59 PM permalink
Quote: Wizard

My program still works and I can give you as many shoes as you like -- even millions of them. I can also format the output however you like. Of course, I will ask a professional rate for my time.

I do have to go on the record that you're wasting your time and money trying to find a baccarat system. They are all equally worthless in the end.



On the other hand, I can generate one million 8-deck shoes in about a minute, and separate them into 100 files of 10,000 shoes.
However, I did make one change; runs of 10 or more are represented by their own letters - A for 10, B for 11, C for 12, and so on. (I is skipped, as it looks too much like 1; while H = 17, J = 18.) The total size is about 400MB uncompressed, but it is 12 MB in a single ZIP file.
Wizard
Administrator
Wizard
  • Threads: 1520
  • Posts: 27096
Joined: Oct 14, 2009
August 7th, 2018 at 6:34:38 PM permalink
Quote: ThatDonGuy

On the other hand, I can generate one million 8-deck shoes in about a minute, and separate them into 100 files of 10,000 shoes.
However, I did make one change; runs of 10 or more are represented by their own letters - A for 10, B for 11, C for 12, and so on. (I is skipped, as it looks too much like 1; while H = 17, J = 18.) The total size is about 400MB uncompressed, but it is 12 MB in a single ZIP file.



I think if it comes down to a bidding war, I'm going to lose.
"For with much wisdom comes much sorrow." -- Ecclesiastes 1:18 (NIV)
AlexR
AlexR
  • Threads: 5
  • Posts: 34
Joined: Jul 22, 2018
August 7th, 2018 at 11:38:37 PM permalink
Okay, here goes. No promises about the quality of my code, I haven't written anything this complicated in a couple years.

clear; global deck

nshoe = 10000; %play n shoes
ndeck = 8; %number of decks in shoe
cut = 15; %cut n cards from end of deck

undeck = builddeck(ndeck); %create unshuffled deck
ngame = 0; %intl game counter
ppt = 0; bpt = 0; tpt = 0; %intl scores

deck = undeck(randperm(length(undeck))); %intl shuffled deck
shoe = 1; %intl shoe count

while shoe < nshoe

phand = draw; %draw two cards each
bhand = draw;
phand = [phand, draw];
bhand = [bhand, draw];

ptot = mod(sum(phand),10); %take initial score
btot = mod(sum(bhand),10);

if ptot>=8 || btot>=8 %check for naturals
natural=true;
else
natural=false;
end

if ptot<=5 && natural==false %player draw on 0,1,2,3,4,5
phand = [phand,draw];
ptot = mod(sum(phand),10);
end

if length(phand)==2 && natural==false %banker draw on two player cards
if btot<=5 %draw on 0,1,2,3,4,5
bhand = [bhand, draw];
end
btot = mod(sum(bhand),10);
elseif natural==false %banker draw on three player cards
if btot==6 && 6<=phand(3)<=7 %draw on 6 against 6,7
bhand = [bhand, draw];
elseif btot==5 && 4<=phand(3)<=7 %draw on 5 against 4-7
bhand = [bhand, draw];
elseif btot==4 && 2<=phand(3)<=7 %draw on 4 against 2-7
bhand = [bhand, draw];
elseif btot==3 && phand(3)~=8 %draw on 3 against any except 8
bhand = [bhand, draw];
elseif btot<=2 %draw on 0,1,2 against any
bhand = [bhand, draw];
end
btot = mod(sum(bhand),10);
end

if ptot == btot %score tally
tpt = tpt+1;
elseif ptot>btot
ppt = ppt+1;
else
bpt = bpt+1;
end

if length(deck)<cut %reshuffle if past cut card
deck = undeck(randperm(length(undeck)));
shoe = shoe+1;
end

ngame = ngame+1;
end

ppct = ppt/ngame; %win fractions
bpct = bpt/ngame;
tpct = tpt/ngame;

F = 'Shoes played: %u (%u deck)\rHands played: %u\rBanker wins: %u (%.5f)\rPlayer wins: %u (%.5f)\rTies: %u (%.5f)\r';
fprintf(F,nshoe,ndeck,ngame,bpt,bpct,ppt,ppct,tpt,tpct) %print results

function y = builddeck(x) %construct a deck
y=[]; suit = [1,2,3,4,5,6,7,8,9,0,0,0,0];
for p = 1:4*x
y = [y,suit];
end
end

function d = draw %draws top card of deck
global deck
d = deck(1);
deck(1) = [];
end


And here's a sample output of the current version:

Shoes played: 10000 (8 deck)
Hands played: 798484
Banker wins: 355136 (0.44476)
Player wins: 367292 (0.45999)
Ties: 76056 (0.09525)
"At gambling, the deadly sin is to mistake bad play for bad luck." —Ian Fleming
ThatDonGuy
ThatDonGuy
  • Threads: 122
  • Posts: 6710
Joined: Jun 22, 2011
August 8th, 2018 at 7:42:40 PM permalink
I don't recognize the language (MATLAB?), but I think I get the gist of how it works, and I can't find anything glaringly wrong either. It could be that randperm isn't working the way you expect it to.

Is there an easy way of printing out the contents of phand and bhand, as well as ptot and btot, for all of the hands in the first shoe (i.e. where shoe = 1)? That could give us a clue.

Also, actually it's only playing 9999 shoes - it shows 10,000 as it does not exit the loop until shoe >= 10,000, but it doesn't actually play out the shoe when shoe = 10,000.
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 8th, 2018 at 9:00:18 PM permalink
Quote: AlexR



shoe = 1; %intl shoe count


when I ran this for 1 shoe
I got this error
Shoes played: 1 (8 deck)
Hands played: 0
Banker wins: 0 (NaN)
Player wins: 0 (NaN)
Ties: 0 (NaN)


so I changed shoe = 0
and it gave a result

I agree to print out 1 shoe and see what is happening
actually if I get a chance tomorrow, I would run each block of code making sure
it does right 100%

I also do not see a major error and a few things I changed made no difference

I do not have matlab but can use an online version in Octave
it may timeout at 10k
Shoes played: 100 (8 deck)
Hands played: 7970
Banker wins: 3496 (0.43864)
Player wins: 3746 (0.47001)
Ties: 728 (0.09134)


thank you for sharing
Sally
I Heart Vi Hart
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 8th, 2018 at 9:31:35 PM permalink
edit:
I think I found your errors as i saved your code in notepad++
I moved
1) btot = mod(sum(bhand),10);
inside of
if end



if ptot<=5 && natural==false %player draw on 0,1,2,3,4,5
phand = [phand,draw];
ptot = mod(sum(phand),10);
end

if length(phand)==2 && natural==false %banker draw on two player cards
if btot<=5 %draw on 0,1,2,3,4,5
bhand = [bhand, draw];
btot = mod(sum(bhand),10);
end
%btot = mod(sum(bhand),10); <<<!!! this is outside of block


next:
now I had to change for example
6<=phand(3)<=7
to
phand(3)>=6 && phand(3)<=7
for btot=6,5 and 4

     elseif length(phand)==3 && natural==false %banker draw on three player cards
if btot==6 && phand(3)>=6 && phand3<=7 %draw on 6 against 6,7
bhand = [bhand, draw];
elseif btot==5 && phand(3)>=4 && phand3<=7 %draw on 5 against 4-7
bhand = [bhand, draw];
elseif btot==4 && phand(3)>=2 && phand3<=7 %draw on 4 against 2-7
bhand = [bhand, draw];
elseif btot==3 && phand(3)~=8 %draw on 3 against any except 8
bhand = [bhand, draw];
elseif btot<=2 %draw on 0,1,2 against any
bhand = [bhand, draw];
end
btot = mod(sum(bhand),10);
end


results
Shoes played: 299 (8 deck)
Hands played: 24465
Banker wins: 11275 (0.46086)
Player wins: 10795 (0.44124)
Ties: 2395 (0.09789)


online timed out at 500 shoes

hope this helps out some
Sally

for a little faster code I changed
'score tally'
to this block to have btot 1st
then ptot then tie
if btot>ptot %score tally
bpt = bpt+1;
elseif ptot>btot
ppt = ppt+1;
else
tpt = tpt+1;
end


I would post all the code but
I changed a lot to see how things worked
as I was on my cell and on an airplane

so I think you can go from here
I will try to clean all the code after I get home if you really need it

your code is very good, imo

Sally
Last edited by: mustangsally on Aug 9, 2018
I Heart Vi Hart
AlexR
AlexR
  • Threads: 5
  • Posts: 34
Joined: Jul 22, 2018
August 9th, 2018 at 12:04:34 AM permalink
Okay, I solved it. The problem is that MATLAB short-circuits relational operators, so for instance: 0<3<2 returns true. This was causing the banker to draw incorrectly. I broke all of them into two separate statements with an AND and it actually seems to work properly.

The mod(sum()) outside the if won't make a difference except that it'll be a little slower. I thought it would be tidier if there was only one needed for all the elsifs, but in the interest of not running it unnecessarily, I'll put one after each draw.

I've also reordered the score tally in case that helps with performance.

>> baccarat
Shoes played: 100000 (8 deck)
Hands played: 8180321
Banker wins: 3752277 (45.87%)
Player wins: 3649377 (44.61%)
Ties: 778667 (9.52%)
Last edited by: AlexR on Aug 9, 2018
"At gambling, the deadly sin is to mistake bad play for bad luck." —Ian Fleming
troopscott
troopscott
  • Threads: 20
  • Posts: 394
Joined: Apr 3, 2017
August 9th, 2018 at 2:01:09 AM permalink
Interesting thread. Be curious to see if anyone can find a pattern
Dalex64
Dalex64
  • Threads: 1
  • Posts: 1067
Joined: Feb 10, 2013
August 9th, 2018 at 6:03:16 AM permalink
I not sure what you mean by 0<3<2 is short-circuiting, but if it is evaluating like C, it is evaluating from left to right, and true/false is just an integer 1 or 0, so
0<3 returns true, which is 1
1<2 is then also true.

If you had 4<3<2,
4<3 would return false, which is 0,
And then also 0<2 is true

Oops
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 9th, 2018 at 7:54:28 AM permalink
Quote: troopscott

Interesting thread. Be curious to see if anyone can find a pattern

the OP as far as I could tell
did not state what he/she was looking for in a BP pattern. Just wanted something to look like what was spelled out.
I have had one computer search over 150 different BP patterns over 250 trillion shoes and not one BP pattern has turned the game to +ev over many shoes or bets.

imho,
each B or P pattern is a direct result of card removal and probability changes in the shoe and any study NOT looking at that fact
will always result in -ev sooner or later, over many many bets, unless a loss rebate is also considered.
*****
of course, many need to find out by themselves
as that carries more weight than
words from others can.
(and not understanding what a house edge is)

from the OP:
"Over the years,
I have invested thousands of hours
gathering thousands of shoe results manually
using the game simulation on the Wizard of Odds website,
analyzing the patterns and trying to figure out any possible strategies.
Unfortunately, I need a lot more data to do my research,
like at least hundreds of thousand more shoes, which would take me an unbelievable amount of time. "

not the 1st
and not the last

at least that was shared
I hope one did some code for the OP, yes
Sally
I Heart Vi Hart
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 9th, 2018 at 9:36:30 AM permalink
Quote: AlexR

Okay, I solved it.

excellent as there was no doubt!

what you were doing
I have done in an Excel function (iirc)
and I did not know how ML handled it
that is what I found too. Yahoo!

doing simulations for others can be frustrating
as they
spell out how they want things to end up and how the events should unfold.

For example, I did not see a burn card(s) in your code
the game (at least the 8 deck I have played) uses burn cards

My Mom told me she played a few 6 deck shoes and they did NOT burn a card
after the player cut the deck

well, this is easily accomplished, imo, in the code
of course

good luck
and thank you for sharing you code!
Sally
I Heart Vi Hart
ThatDonGuy
ThatDonGuy
  • Threads: 122
  • Posts: 6710
Joined: Jun 22, 2011
August 9th, 2018 at 6:08:26 PM permalink
Sally - having the btot = mod(sum(bhand),10) outside of the block would have no effect, as even if btot > 5, it would be set to mod(sum(bhand), 10), which is what it was already set to.

Alex - I installed GNU Octave on my computer, and ran the code, and got the same problem with player wins > banker wins.
However, when I replaced all of the "6<=phand(3)<=7" type code with "phand(3)>=6 && phand(3)<=7". the numbers came out accurately. It could be a problem with the Octave interpreter/compiler itself.
The strange thing is, when I check to see if 6 <= phand(3) <= 7 is false but 6 <= phand(3) && phand(3) <= 7 is true (which should be impossible), it doesn't report any errors.
Dalex64
Dalex64
  • Threads: 1
  • Posts: 1067
Joined: Feb 10, 2013
August 9th, 2018 at 6:55:01 PM permalink
That language does not support chained comparators, i.e. a < b < c

It will compare a and b, return 0 or 1, and then compare 0 or 1 to c.
mustangsally
mustangsally
  • Threads: 25
  • Posts: 2463
Joined: Mar 29, 2011
August 11th, 2018 at 1:26:08 PM permalink
Quote: ThatDonGuy

Alex - I installed GNU Octave on my computer, and ran the code,

lucky u

I tried to install it on my 2
win10 machines and it said right at the beginning it has not been tested 4 win10

there are so many run errors and
I can not even scroll in the console window to view them

that is why I used online (and it was a total pain as it was so slow, even for 1 shoe)

I do have 1 old win 7 laptop I may place it on
just 4 fun

it is what is left
fun
Sally
I Heart Vi Hart
ThatDonGuy
ThatDonGuy
  • Threads: 122
  • Posts: 6710
Joined: Jun 22, 2011
August 11th, 2018 at 4:26:52 PM permalink
The only problem I seem to have with it is, the output window won't scroll up, and I can't do any sort of select on the window, so anything that scrolls past the top of the window is pretty much lost (unless I go through the bother of outputting everything to a file).
AlexR
AlexR
  • Threads: 5
  • Posts: 34
Joined: Jul 22, 2018
August 11th, 2018 at 11:08:21 PM permalink
I've changed it over to run shoes in parallel for better performance. Now it can play through a million shoes in less than 58 seconds.

Shoes played: 1000000 (8 deck)
Hands played: 81198840
Banker wins: 37232521 (45.85%)
Player wins: 36239385 (44.63%)
Ties: 7726934 (9.52%)


It also generates a complete record of every hand in in plain text. I can share the one that produced the output above if anyone wants to look for patterns in it. :)
"At gambling, the deadly sin is to mistake bad play for bad luck." —Ian Fleming
RobertR
RobertR
  • Threads: 0
  • Posts: 2
Joined: Aug 12, 2018
August 12th, 2018 at 8:54:11 AM permalink
I've done it before.
Pattern recognition is not possible.

If you serialize 10 in rows.
You can see 2^10 combinations of the same frequency.
Because It's random. Everything is possible.

But if you analysis about 24 rows or more than, It certainly make viable edge.
There are definitely more frequent combinations.
But It's 2^24 = 16,777,216........

The more analyze, the more affect the card remaining on the deck.
It's as like as card counting.
But as you know, card counting is almost useless in baccarat.
To be honest, this is a waste of time.

If you want source code.
You can find source code written by python in gist.
Good luck.
kfmfe04
kfmfe04
  • Threads: 0
  • Posts: 8
Joined: Oct 2, 2018
October 2nd, 2018 at 4:25:21 PM permalink
For the OP: this is like a one-liner in Linux using R/Rscript, if you want to do it quick and dirty:

16:17 $ Rscript -e 'rle(strsplit(gsub(" ","",commandArgs(trailingOnly=TRUE)[1]), "")[[1]])$lengths' "B PPP BB P BB P BBBBBBB PP BB PPP B PPPPPPPPPPPP BB P B P BB P"
[1] 1 3 2 1 2 1 7 2 2 3 1 12 2 1 1 1 2 1

If you want to deal with the 12's or really care about 0 instead of 1, you'll have to muck around a bit more.

BTW, thanks to mustangsally and AlexR for their code and comments here - helped me narrow down and squash some bugs in my Baccarat simulator (golang).

- Ken
MDawg
MDawg
  • Threads: 41
  • Posts: 8088
Joined: Sep 27, 2018
October 3rd, 2018 at 7:55:11 PM permalink
A good shoe will follow a pattern. Some would say, "appear to follow a pattern," but what's the difference?

A random shoe will follow no pattern. Some will say, "all shoes are random."
I tell you it’s wonderful to be here, man. I don’t give a damn who wins or loses. It’s just wonderful to be here with you people. https://wizardofvegas.com/forum/gambling/betting-systems/33908-the-adventures-of-mdawg/
kfmfe04
kfmfe04
  • Threads: 0
  • Posts: 8
Joined: Oct 2, 2018
October 3rd, 2018 at 9:05:09 PM permalink
Quote: MDawg

A good shoe will follow a pattern. Some would say, "appear to follow a pattern," but what's the difference?

A random shoe will follow no pattern. Some will say, "all shoes are random."



"appear to follow a pattern" applies if there are enough samples taken. In fact, if all permutations of a finite space is taken, EVERY combination will appear.

Have you ever heard of Jorge Luis Borge's Library of Babel? It's a story about a library so large that every possible book that can be written has been written. It includes mostly random garbage, but if you look long enough, you will find works of Shakespeare or any other text you like.

Someone actually wrote a program which effectively generates a Library of Babel:

Google "Library of Babel online" to libraryofbabel dot info - I can't get this forum to embed links.

For example, type in "To be or not to be" or any other text you like.

Is there order or genius in these pages? Neither, because it's just the result of every possible combination of letters on a page being generated. Note that these books are deterministic in the sense that if you search for "To be or not to be" tomorrow, they will show up in exactly the same books on the same pages in the same places as your search just now. But in fact, they are random in the sense that they're just the permutation of every possible combination of letters. There was no Shakespeare writing these pages - just a bunch of monkeys on typewriters.

So what does this have to do with Baccarat? The analogous question here is, are those patterns real or just the result of a lot of samples with humans looking for patterns?

How can we tell the difference? If it's the former, we can exploit those patterns using a pattern recognition system to bet and gain a positive edge. If it's the latter, there will be no positive edge to be found, because all you've found is a case of a specific case of a lucky pattern - when looking at the entire sample space, most of the time, it will NOT fit your pattern. Theoretically, given sufficiently good shuffles, those positive edges should not exist.

However, in real life, how good are those physical shuffles by people or machine? The closer the shuffle is to an "ideal shuffle", the less of an edge there is. The further away from an "ideal shuffle", the more you will have clumping or other kinds of "memory" from the previous deal, the more chance for an inefficiency to be found. Note that baccarat is closer to BJ than craps or roulette in the sense that you are drawing from a finite deck.

In the extreme case, suppose you have just played out an entire shoe and you know the order of the deck. Not only that, you know how many riffles, cuts, etc... have been physically applied as part of the shuffle. Using calculations, it has already been shown that you can have an edge in guessing the order of the cards that will come out.

However, the hardest part about Baccarat for exploiting those inefficiencies are:
1. The deal is roughly symmetric so cards heavy in say 4's will roughly help/hurt both sides. This is why card counting may only help you exploit an imbalance in the form of a "tie" bet, not in guessing if a "player" or "banker" will win.
2. You cannot bet AFTER seeing cards (like in BJ) - so you cannot exploit that extra information by betting heavy or light after some beans are spilt.

Through evolution, human brains have evolved to look for patterns, even when they don't really exist. So it's easy to be "Fooled by Randomness". Either way, it's an interesting enough problem to be investigated.
MDawg
MDawg
  • Threads: 41
  • Posts: 8088
Joined: Sep 27, 2018
October 4th, 2018 at 8:21:47 AM permalink
Baccarat is a very interesting game.

All I know is that first years I played Baccarat I consistently killed the house, I mean I took them for well over a million, averaging a few hundred thousand a year net profit at Baccarat. And what is funny is that the only reason I was playing Bacc is because I was effectively banned from BJ at most of the casinos.

Then in the last year I gambled, about a decade ago, I started to lose heavily at Bacc., gave back over a hundred thousand. Then I quit.

Over the next decade that I did not gamble even a penny, I would still visit casinos, and occasionally I would stand behind a Baccarat shoe and watch it, and wonder how I ever won at this game. It's just not a game you may judge from the outside. When you are in it, betting real money, is the only real test. Sometimes your intuition is right on and you keep winning, and other times you lose far more than 50% of your bets. It is not logical, but this is my experience with the game.

And it comes back to what kind of shoe you are dealt - one that follows a pattern, or one that is random. I get what you are saying about how all the monkeys typing on all the typewriters may come up with Shakespeare, but I didn't play millions of shoes, so whatever patterns emerged emerged in far less than a statistically significant pool.

Here's one pattern that doesn't take a mathematician to describe: bank or player runs. If you are a believer in runs, as I am, and increase your bet on runs, as I do, and you run into runs, then you are going to kill the house. You get two banks and your mind tells you that there are many more coming, and you bet into them, if it happens, you are going to make a fortune. So right there is a simple example of a shoe with a pattern that will make you a lot of money, if your brain is wired to believe in it and accept it as it is happening.
I tell you it’s wonderful to be here, man. I don’t give a damn who wins or loses. It’s just wonderful to be here with you people. https://wizardofvegas.com/forum/gambling/betting-systems/33908-the-adventures-of-mdawg/
lilredrooster
lilredrooster
  • Threads: 240
  • Posts: 7072
Joined: May 8, 2015
Thanked by
Forager
October 4th, 2018 at 10:29:56 AM permalink
here is all you need to know about baccarat patterns:

if you choose to bet Player because you believe you see a pattern the underlying logic of your decision is that Player is more likely to come than Banker now.

and that is incorrect. on any given play assuming the player is not counting cards (where it has been shown that only a very tiny % can be gained and only very seldom) or does not have any advance knowledge of any card to be dealt to either hand - then the odds of Player coming have not changed. they are the same. the previous pattern does not change that fact.

at these 2 websites: gamblersforum.com and betselection.cc the posters have proposed and claimed thousands of systems to be winners based on either varying the size of your bet based on previous results or choosing which side to bet on based on previous results.

of all of these thousands of proposed systems, over all of these many years, not a single one has ever proved to overcome the edge of a house game. 𝐍𝐎𝐓 𝐎𝐍𝐄





patterns in the dark

I see patterns in the shadows on my walls at night coming from street lights outside

looks like ghosts from past lives
the foolish sayings of a rich man often pass for words of wisdom by the fools around him
MDawg
MDawg
  • Threads: 41
  • Posts: 8088
Joined: Sep 27, 2018
October 4th, 2018 at 11:42:14 AM permalink
All of what you say is mathematically sound, but anyone who has won consistently at Bacc. knows there is much more to it than dreamt of in your philosophy.

There is no "system" to winning at Bacc. - either you have it in you, or you don't. It's useless to try to discuss this with a non-believer, because the non-believers have never won consistently at any sort of gambling.
I tell you it’s wonderful to be here, man. I don’t give a damn who wins or loses. It’s just wonderful to be here with you people. https://wizardofvegas.com/forum/gambling/betting-systems/33908-the-adventures-of-mdawg/
lilredrooster
lilredrooster
  • Threads: 240
  • Posts: 7072
Joined: May 8, 2015
Thanked by
Forager
October 4th, 2018 at 12:12:08 PM permalink
Quote: MDawg

the non-believers have never won consistently at any sort of gambling.




you mean to say the non-believers have never won consistently counting cards in blackjack? is that really true?
and the non-believers have never won consistently as expert poker players? is that really true?


thousands of people like you have claimed to be long term winners at house games by somehow overcoming the house edge through recognizing patterns

𝐍𝐎𝐓 𝐎𝐍𝐄 has ever proved it
the foolish sayings of a rich man often pass for words of wisdom by the fools around him
MDawg
MDawg
  • Threads: 41
  • Posts: 8088
Joined: Sep 27, 2018
October 4th, 2018 at 12:55:28 PM permalink
I have the win/loss statements to prove it. But even those don't prove anything necessarily, maybe I was just lucky for ten years straight, with both BJ and Baccarat.

The problem with counting at BJ is they end up either kicking you out, or, as they did to me, effectively banning by limiting my spread on bets to 3X my previous hand.

Also, counting isn't always what makes a BJ player win, you may be getting 12s and 13s all night long and keep perfect count of the deck and bet accordingly and still lose. A strong intuition of when to jump the bet on BJ (or any gambling) may rake in far more chips than careful grinding and counting. There is no count that justifies jumping the BJ bet 100X from your prior bet, and yet I used to do that all the time and win consistently.

Same with poker, you may get bad beats that have nothing to do with the math. The same poker players no longer always end up in the winner's circle nowadays some random kid comes out of nowhere and beats them all. Some of the "best" poker plays have been losing their arses for the past two years straight. Whatever happened to Nick the Greek? So much for your theory that all that matters is skill.

Everything you're posting, with each post, is becoming more and more clear is based on just "theory." I don't dispute the theories, but there is much more to these games than just the numbers. A successful gambler feels when to jump the bet, and it has more to do with than just the math.

If you don't jump the bet over time you will lose, so unless you're playing to lose, you have to rely on something more than just math. You also may not be just gambling all the time. In and out after a run, abort if it's not happening, the times when things are going your way won't be every time.
I tell you it’s wonderful to be here, man. I don’t give a damn who wins or loses. It’s just wonderful to be here with you people. https://wizardofvegas.com/forum/gambling/betting-systems/33908-the-adventures-of-mdawg/
lilredrooster
lilredrooster
  • Threads: 240
  • Posts: 7072
Joined: May 8, 2015
October 4th, 2018 at 1:06:57 PM permalink
counting cards at blackjack is hard work
becoming an expert poker player is hard work



not saying you but the reason so many go for betting progressions or bet selection based on pattern recognition is because 𝐢𝐭'𝐬 𝐧𝐨𝐭 𝐡𝐚𝐫𝐝 𝐰𝐨𝐫𝐤
that is the nature of the gambler - looking for easy money


maybe you're different. I'm not saying you're not
but easy money is what it's really all about


I have intuition too
but I don't want to rely on my intuition
I don't trust it

I trust mathematics



I've heard others point out that Nick the Greek ended up without much
I don't buy that that is meaningful
he lived to be 83
if he lost a lot in his late 70s or 80s it was almost surely due to decreasing mental acuity which happens to just about all of us as we age
he was truly great. for much of his adult life he was flush with millions back when a million dollars was a lot of money
regardless of him living out the end of his life without his wealth he was truly a great gambler
a legend - deservedly so
the foolish sayings of a rich man often pass for words of wisdom by the fools around him
  • Jump to: