Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture 12.

Similar presentations


Presentation on theme: "Lecture 12."— Presentation transcript:

1 Lecture 12

2 Project 2 Select and analyze a game of chance DUE: on November 10.
Use calculation, R or other mean to make QUANTITATIVE observations about the game Write a 5 page paper. Include: Description of the game Your analysis Conclusions References DUE: on November 10. Come to my office to discuss what makes a suitable project!

3 Black jack analysis We will use R to compute the probability of dealer going bust. We use hard 17 stop rule for the dealer. R code available on the website R function (from handout)

4 R function Function is a wrapper that allows us to write code in modules Back to Handout

5 Estimated Results 17 18 19 20 21 BJ bust 0.146 0.138 0.135 0.176 0.074
0.048 0.283

6 Counting cards Basic counting rule:
+1 for 2-6 0 for 7-9 -1 for 10-A We will again use R to compute the probability of dealer going bust. We only start playing when the count becomes 17 R code available in resource section of sakai

7 Estimated Results – Count +17
18 19 20 21 BJ bust Only +17 0.138 0.132 0.128 0.198 .064 .062 0.278 plain 0.146 0.135 0.176 0.074 0.048 0.283 Quote from wikipedia: “Another aspect of the probability of card counting is that, at higher counts, the player's probability of winning a hand is only slightly changed and still below 50%. The player's edge over the house on such hands does not come from the player's probability of winning the hands. Instead it comes from the increased probability of blackjacks, increased gain and benefit from doubling, splitting and surrender, and the insurance side bet, which becomes profitable at high counts.”

8 Homework Modify the R code to use soft 17.
Always stop if 18 or higher Stop on 17 unless there is A counted as 11 (in which case dealer hit himself/herself) What do you expect to happen? Suggestion: Code the basic strategy

9 Game theory So far we discussed: roulette and blackjack Roulette:
Outcomes completely independent and random Very little strategy (even that is curbed by minimums and maximum bet rules) Blackjack Dealers outcome completely random (no strategy) There is some dependence between draws Strategy can be useful (counting cards and adjusting play accordingly)

10 Game theory Poker What is a rational (best?) strategy? MAXIMIN
All the participant are following a strategy that uses the information based on the cards and behaviour other players What is a rational (best?) strategy? MAXIMIN Select a strategy S If the opponent new my strategy, what is the worst they can do to me? Select the strategy that maximizes this worst case scenario

11 Understanding role of strategy
Coin matching game: You and your friend each have a coin. You each secretly choose to show “heads” or “tails”. You simultaneously show your choice. The payoff: If the coins are both “heads”, your friend pays you $1. If the coins are both “tails”, your friend pays you $9. If the coins do not match, you pay your friend $5. Is this a fair game?

12 Coin matching game you\friend H T 1 -5 9 If both of us flip a coin:
Expected gain = 1*0.5*0.5+(-5)*0.5*0.5+(-5)*0.5*0.5+9*0.5*0.5=0 (Looks fair but is it?) Play matlab game We do not need to flip a fair coin – we can choose any proportion of H/T we want! Consider our proportion of H p and friends proportion of H q. For now assume independence between us and friend Expected gain = 1*p*q+(-5)*p*(1-q)+(-5)*(1-p)*q+9*(1-p)*(1-q)=9-14p-14q+20pq How to select p?

13 Maximin Main idea: We want select p to maximize expected win
if positive we might also want to minimize variance What is best depends on the friends strategy: (Depends on friends choices unknown to me) If I select p – if my friends selects all T gain =9-14p all H gain=-5+6p

14 Maximin Notice that smaller of the two lines is less than -0.8
The best option is p=0.7 – gain =-0.8 

15 Minimax (maximin for friend)
Friends choices What is best for the friend depends on my strategy (unknown to him) My friends select q – if I selects all H gain =9-14q all T gain=-5+6q Notice that larger (my gain his loss!) of the two less than -0.8 The best option is q=0.7 – expected gain =-0.8 (friend gains 0.8 on average) Nash equilibrium if the other player is playing optimally there is nothing to gain from changing strategies


Download ppt "Lecture 12."

Similar presentations


Ads by Google