Dominion Strategy Forum

Please login or register.

Login with username, password and session length
Pages: 1 2 [3] 4  All

Author Topic: A theorem about drawing and density  (Read 31998 times)

0 Members and 1 Guest are viewing this topic.

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: A theorem about drawing and density
« Reply #50 on: March 12, 2012, 10:46:02 am »
0

Believe it or not, I have actually fashioned a proof using Binomial coefficients http://en.wikipedia.org/wiki/Binomial_coefficient that the mean card value in the draw deck is unchanged after played a venture (for a deck of treasures and victory cards, at least 2 treasures). This is university level mathematics so I'm pretty pleased that I've remembered something about it after 20 years!

Essentially - Formulate the probability of discarding n victory cards when playing the venture and the mean card value in that case
                  - Use the weighted sum of these values to create a formula for the expected card value across all cases
                  - Cancel out the terms using Pascal's triangle to break down the more complex ones: (nk) = (n-1k-1) + (n-1k)
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4384
    • View Profile
    • WanderingWinder YouTube Page
Re: A theorem about drawing and density
« Reply #51 on: March 12, 2012, 11:01:45 am »
0

Well, sort of. It's unchanged from before you play the ventures to after you play the ventures, on average, assuming you don't have other ventures or banks or special treasures in your draw deck, assuming you don't reshuffle. Okay, all of these are are actually significant assumptions (that make it unclear as to whether playing the ventures when you don't need the money is good or not), but it's still something.

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #52 on: March 12, 2012, 12:09:03 pm »
0

Well, sort of. It's unchanged from before you play the ventures to after you play the ventures, on average, assuming you don't have other ventures or banks or special treasures in your draw deck, assuming you don't reshuffle. Okay, all of these are are actually significant assumptions (that make it unclear as to whether playing the ventures when you don't need the money is good or not), but it's still something.

The main point is that you shouldn't automatically play Venture in an attempt to improve future hands.  Assuming you have no use for additional treasure (so, no HoP or Loan) or the $1 from Venture, the effect of Venture is deck cycling.  The decision of whether or not to play Venture in that case is similar to the decision of whether or not to play Smithy when it can't draw anything to help your current hand.
Logged

DStu

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2627
  • Respect: +1490
    • View Profile
Re: A theorem about drawing and density
« Reply #53 on: March 12, 2012, 12:13:38 pm »
+2

I still haven't really understood the term "unchanged". "Unchanged" with respect to what? To not playing the Venture?

It seems that can not really be, because the Venture does not stop at a random card, but at a Treasure. So if you have an empty discard, a Venture in hand and a draw-deck of 99 Estates and a Gold, the probability that you will draw a Gold next turn without playing the Venture is 5%. When you play the Venture, the probability of drawing the Gold is a lot smaller, because if you don't reshuffle during drawing your next hand, it's exactly 0%. And even if you reshuffle, which has a probability of 5% (namely if your ventured Gold is on positions 96-100) it's smaller than 5% (namely if your Gold in the next reshuffle is on positions 1-5 [it's smaller because depending on which position the ventured Gold was, you have fewer spots).
So the probability of drawing the Gold next turn, given you play the Venture this turn is smaller than 0.05*0.05 = 0.25%

And that's not because I just have on treasure, you could do the same thing with 98 Estates, 2 Golds and the probability that you draw 2 Golds next turn:
Without Venture probability of drawing 2 Golds next turn is 5/100*4/99.
With Venture to draw 2 Golds, I need to trigger a reshuffle, that is both Golds have to be behind position 95, which has prob 5/100*4/99. Then after the Venture, I'm guaranteed to have the second Gold in hand, but I also need to redraw the first Gold again, which again has probability smaller than 5/100, which gives probability 5/100*5/100*4/99 to this event.

So the "thing" that didn't change (given you don't reshuffle) is the distribution of your cards minus a random Treasure.

And to rate if you want to play an unneeded Venture, these are the two important things: a) Which non-treasure cards are left in my draw, and do I want to play them? b) Which treasure cards are left in my draw deck, and do I want to play them?

Ok, that sounds like it's only thing, and maybe it is. Of course Treasures and non-Treasure act differently, because the less Treasures in my deck, the more other cards I skip (on average).

Edit: Or, what (an unneeded and uninformed) Venture does is to move you a random number of positions forward in your deck, at the cost of a random Treasure. Otherwise it does not change the distribution.
« Last Edit: March 12, 2012, 12:17:20 pm by DStu »
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4384
    • View Profile
    • WanderingWinder YouTube Page
Re: A theorem about drawing and density
« Reply #54 on: March 12, 2012, 12:25:47 pm »
0

I still haven't really understood the term "unchanged". "Unchanged" with respect to what? To not playing the Venture?
Yes, but it's the *average* money per card left in the deck. You also need to have at least two treasures, so that's going to knock the single gold example out. So, we go to your second example and say that, before you played this venture, your average money per card was $6/100 cards = $0.06. After playing the venture, it's going to be the same, $0.06, on weighted average, ignoring reshuffle. Now, of course, dominion is discrete, not continuous, so this $0.06 number is preposterous - you either have 0 in your hand, or $3, or $6. And I'd much rather have $8 10% of the time than $.8 100% of the time. So the whole finding the average value actually breaks down; you need to find what the distribution (not the average) is on a per-hand basis, like you say, for actually playing the game. The average is only a rule of thumb, a quick, easy-to-calculate approximation, which works decently well when your variance is low. But with high variance, toss it out the window.

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #55 on: March 12, 2012, 12:55:52 pm »
+1

The code I posted earlier in the thread looked at variance as well.  It showed that, over a million trials, Venture does not impact the average coin value of your next hand or the variance of your next hand for the draw pile I tested.  Is there some other metric we should look at apart from mean and variance?

I just re-ran the simulation with a deck containing 6 coppers and 1000 dead cards.  It's the same story.  No change to average coin value, and no change to variance after playing Venture.

We have to be a little careful considering decks with fewer than 6 treasures, since there are cases where the next hand could cause a reshuffle.  It's not really worth considering what happens after the reshuffle, because at that point you're looking at the benefits of cycling not of filtering.

Venture will nearly always change the next hand that you draw in one way or another.  It does so unpredictably, though, (when played blindly) and on average it won't change the quality of the next hand.
Logged

DStu

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2627
  • Respect: +1490
    • View Profile
Re: A theorem about drawing and density
« Reply #56 on: March 12, 2012, 12:58:17 pm »
0

Ok thanks, I can believe that, because the average money of the deck without everything up to an average treasure should be the same as the average money of the deck, given you have at least two treasures in the deck.

:e @ecq: It looked at the variance, and while it may not change, it is nevertheless important. Because as WW said, if it is low, average coin value is a good measure, if it is high, it is not.

:e2 @ecq again: I'm just guessing at the moment, but it might be that with n+1 treasures of the same type in a deck, a played Venture does not change the distribution of n-tupels of the deck. At least it's true for n=0 (trivially), n=1 is I think also true. I mean with just Coppers and Estates we are talking about Bernoulli variables, they are fully characterized by their mean. If we add Silvers that might change...
From there on I'm just on my intuition, and I don't want to prove, but it might be true. In that case, if you had 6 Coppers, the distribution of a hand would not change on average...
« Last Edit: March 12, 2012, 01:10:32 pm by DStu »
Logged

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #57 on: March 12, 2012, 01:03:59 pm »
0

:e @ecq: It looked at the variance, and while it may not change, it is nevertheless important. Because as WW said, if it is low, average coin value is a good measure, if it is high, it is not.

What's a better measure?  Number of $8 hands?  Could you give me a sample draw pile containing at least 6 treasure cards and a metric?
Logged

DStu

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2627
  • Respect: +1490
    • View Profile
Re: A theorem about drawing and density
« Reply #58 on: March 12, 2012, 01:11:27 pm »
0

What's a better measure?  Number of $8 hands?  Could you give me a sample draw pile containing at least 6 treasure cards and a metric?

Quote from: me edited after your post
:e2 @ecq again: I'm just guessing at the moment, but it might be that with n+1 treasures of the same type in a deck, a played Venture does not change the distribution of n-tupels of the deck. At least it's true for n=0 (trivially), n=1 is I think also true. I mean with just Coppers and Estates we are talking about Bernoulli variables, they are fully characterized by their mean. If we add Silvers that might change...
From there on I'm just on my intuition, and I don't want to prove, but it might be true. In that case, if you had 6 Coppers, the distribution of a hand would not change on average...

If my guess is right then no.
Logged

O

  • Jester
  • *****
  • Offline Offline
  • Posts: 836
  • Respect: +605
    • View Profile
Re: A theorem about drawing and density
« Reply #59 on: March 12, 2012, 01:16:57 pm »
+1

This is all a bit too theoretical to be practical. What's being ignored is that if you have the option of not playing venture and retaining the same buy (so, in the majority of cases, 8$ pre-venture, so a 10+ hand), your current hand value is probably a significant enough outlier to make the average value of you hand+discard greater than the average value of your draw pile. Frequently (but not always) this is more important than the effect of the remaining green that you will add to your deck this shuffle, making it advantageous to play.

It's the same as with BM+8$+un-played smithy. If Bm+8$ +Smithy isn't significantly above your mean hand value in a province game, you probably already played incorrectly. So you play the smithy for the decrease in expected turns until you see it and the 8$ in coins again (assuming no reshuffle is triggered), and this is a more prevalent factor than the greening effect.

This obviously isn't picked up in the venture + 6 copper + 1000 dead cards simulation.
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: A theorem about drawing and density
« Reply #60 on: March 12, 2012, 01:26:57 pm »
0

Quote
What's being ignored is that if you have the option of not playing venture and retaining the same buy (so, in the majority of cases, 8$ pre-venture, so a 10+ hand), your current hand value is probably a significant enough outlier to make the average value of you hand+discard greater than the average value of your draw pile. Frequently (but not always) this is more important than the effect of the remaining green that you will add to your deck this shuffle, making it advantageous to play.

The result suggests that you can make card management decisions without worrying about the effect on your mean card value.
Logged

O

  • Jester
  • *****
  • Offline Offline
  • Posts: 836
  • Respect: +605
    • View Profile
Re: A theorem about drawing and density
« Reply #61 on: March 12, 2012, 01:35:50 pm »
0

Quote
What's being ignored is that if you have the option of not playing venture and retaining the same buy (so, in the majority of cases, 8$ pre-venture, so a 10+ hand), your current hand value is probably a significant enough outlier to make the average value of you hand+discard greater than the average value of your draw pile. Frequently (but not always) this is more important than the effect of the remaining green that you will add to your deck this shuffle, making it advantageous to play.

The result suggests that you can make card management decisions without worrying about the effect on your mean card value.

This is where I'm a bit confused. By "mean card value" do you mean "mean card value of the rest of this particular shuffle"? That makes the most sense to me but once again seems still situational since the card value is discrete, as WanderingWinder pointed out. Unless you mean it has no effect even when considering discreteness, which is more interesting.
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4384
    • View Profile
    • WanderingWinder YouTube Page
Re: A theorem about drawing and density
« Reply #62 on: March 12, 2012, 01:45:56 pm »
0

:e @ecq: It looked at the variance, and while it may not change, it is nevertheless important. Because as WW said, if it is low, average coin value is a good measure, if it is high, it is not.
What's a better measure?  Number of $8 hands?  Could you give me a sample draw pile containing at least 6 treasure cards and a metric?

Draw deck:
5 copper
3 silver
2 gold
6 dead cards
(I don't know what point I'm trying to prove here, just trying to make the numbers look possible)

Give me, if you can, the distribution of money production in the next hand, i.e. what proportion of the time do you have $0,$1,$2,$3...... up through the highest amount (I guess $12). Also, how many trials you ran it for.
Edit: If you want to be really awesome, calculate the next 2 hands (I guess you need to add like a copper to do that...)

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #63 on: March 12, 2012, 02:18:25 pm »
+2

I *do* want to be really awesome!

5 million trials.  Draw deck was what you posted, except with 6 coppers to guarantee no reshuffles.

Here's the histogram twice.  The first contains the total number of hands at each coin value.  The second contains the percentage of hands at each value.

Code: [Select]
             Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13
  Next hand, no Venture |   4861 |  72618 | 278339 | 558143 | 860531 | 974781 | 912324 | 683080 | 392355 | 186457 |  61022 |  14700 |    789 |      0
Second hand, no Venture |   4862 |  72079 | 278714 | 558022 | 860659 | 973645 | 914068 | 683957 | 392132 | 185692 |  60838 |  14512 |    820 |      0
     Next hand, Venture |   4833 |  72559 | 279492 | 556025 | 860684 | 975051 | 912807 | 683532 | 393007 | 185622 |  60953 |  14640 |    795 |      0
   Second Hand, Venture |   4682 |  72674 | 278416 | 558581 | 860605 | 974627 | 912308 | 683844 | 392206 | 185923 |  60838 |  14557 |    739 |      0

             Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13
  Next hand, no Venture |  0.10% |  1.45% |  5.57% | 11.16% | 17.21% | 19.50% | 18.25% | 13.66% |  7.85% |  3.73% |  1.22% |  0.29% |  0.02% |  0.00%
Second hand, no Venture |  0.10% |  1.44% |  5.57% | 11.16% | 17.21% | 19.47% | 18.28% | 13.68% |  7.84% |  3.71% |  1.22% |  0.29% |  0.02% |  0.00%
     Next hand, Venture |  0.10% |  1.45% |  5.59% | 11.12% | 17.21% | 19.50% | 18.26% | 13.67% |  7.86% |  3.71% |  1.22% |  0.29% |  0.02% |  0.00%
   Second Hand, Venture |  0.09% |  1.45% |  5.57% | 11.17% | 17.21% | 19.49% | 18.25% | 13.68% |  7.84% |  3.72% |  1.22% |  0.29% |  0.01% |  0.00%

Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4384
    • View Profile
    • WanderingWinder YouTube Page
Re: A theorem about drawing and density
« Reply #64 on: March 12, 2012, 02:53:00 pm »
0

Okay, now a couple sets designed to try to have it make a big difference (if it's as easy as you say/it looks; if it takes more than 10 minutes to set up, don't bother):
3 copper, 3 silver, 3 gold, 3 platina, 10 dead cards.
10 copper, 2 platina, 0 dead cards.
Then do each of these with all the numbers getting multiplied by say 100, (i.e. 300 copper, 300 silver...), so that we can see if that makes any difference. The more I think about it, the more I think it doesn't, and the only issues it has are cycling issues, and most of all the reshuffle.

DStu

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2627
  • Respect: +1490
    • View Profile
Re: A theorem about drawing and density
« Reply #65 on: March 12, 2012, 03:08:23 pm »
0

My bet is also that it doesn't, but not really for the cycling issues. But to exclude cycling issues, you take >10 treasures, and with >10 treasures the distribution of 10 cards is preserved. So probably not only the distribution of treasure on each hand is the same, but probably also the joint distribution of hand1:hand2.

If you take less than 5 treasures, and condition on not reshuffling (by just throwing away everything that triggers a reshuffle), you should see a difference in the hands.

Edit: I rethought this and maybe you can also count it as reshuffling-issue...
« Last Edit: March 12, 2012, 03:39:45 pm by DStu »
Logged

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #66 on: March 12, 2012, 03:32:43 pm »
0

Here's the decks you asked for.  This time it's 500,000 trials because the big decks were taking a while, so it's slightly less accurate, though still good enough to get the idea.

Code: [Select]
Deck: 3x Platinum, 3x Gold, 3x Silver, 3x Copper, 10x dead

  Total hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15 |     16 |     17 |     18 |     19 |     20 |     21 |     22
    Next hand, no Venture |   4910 |  11976 |  18861 |  33175 |  35123 |  48489 |  53351 |  49353 |  58999 |  42756 |  43098 |  32980 |  21911 |  20212 |   9686 |   7867 |   3947 |   1557 |   1219 |    302 |    174 |     54 |      0
  Second hand, no Venture |   4685 |  11874 |  18897 |  33359 |  35226 |  48361 |  53826 |  49372 |  58633 |  43043 |  43187 |  33054 |  21746 |  19800 |   9550 |   7742 |   4162 |   1714 |   1247 |    308 |    162 |     52 |      0
       Next hand, Venture |   4757 |  12013 |  18746 |  33118 |  35163 |  48185 |  53475 |  49626 |  58436 |  42796 |  43446 |  33492 |  21825 |  20020 |   9707 |   7755 |   4021 |   1599 |   1288 |    291 |    177 |     64 |      0
     Second Hand, Venture |   4874 |  12164 |  18826 |  33891 |  35000 |  48310 |  53463 |  49301 |  58660 |  42887 |  43169 |  33022 |  21613 |  20201 |   9635 |   7576 |   3989 |   1661 |   1234 |    296 |    170 |     58 |      0

  Percentage of hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15 |     16 |     17 |     18 |     19 |     20 |     21 |     22
    Next hand, no Venture |  0.98% |  2.40% |  3.77% |  6.63% |  7.02% |  9.70% | 10.67% |  9.87% | 11.80% |  8.55% |  8.62% |  6.60% |  4.38% |  4.04% |  1.94% |  1.57% |  0.79% |  0.31% |  0.24% |  0.06% |  0.03% |  0.01% |  0.00%
  Second hand, no Venture |  0.94% |  2.37% |  3.78% |  6.67% |  7.05% |  9.67% | 10.77% |  9.87% | 11.73% |  8.61% |  8.64% |  6.61% |  4.35% |  3.96% |  1.91% |  1.55% |  0.83% |  0.34% |  0.25% |  0.06% |  0.03% |  0.01% |  0.00%
       Next hand, Venture |  0.95% |  2.40% |  3.75% |  6.62% |  7.03% |  9.64% | 10.70% |  9.93% | 11.69% |  8.56% |  8.69% |  6.70% |  4.37% |  4.00% |  1.94% |  1.55% |  0.80% |  0.32% |  0.26% |  0.06% |  0.04% |  0.01% |  0.00%
     Second Hand, Venture |  0.97% |  2.43% |  3.77% |  6.78% |  7.00% |  9.66% | 10.69% |  9.86% | 11.73% |  8.58% |  8.63% |  6.60% |  4.32% |  4.04% |  1.93% |  1.52% |  0.80% |  0.33% |  0.25% |  0.06% |  0.03% |  0.01% |  0.00%


Deck: 300x Platinum, 300x Gold, 300x Silver, 300x Copper, 1000x dead

  Total hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15 |     16 |     17 |     18 |     19 |     20 |     21 |     22 |     23 |     24 |     25 |     26
    Next hand, no Venture |   9547 |  14433 |  23064 |  34667 |  34385 |  49469 |  48603 |  47921 |  50568 |  38480 |  39471 |  31090 |  22561 |  20317 |  11385 |   9813 |   5845 |   3284 |   2716 |    909 |    852 |    373 |    115 |    108 |      0 |     24 |      0
  Second hand, no Venture |   9502 |  14636 |  23216 |  34279 |  34366 |  49279 |  48874 |  47579 |  50784 |  38572 |  39768 |  30530 |  22699 |  20116 |  11323 |  10024 |   5992 |   3312 |   2689 |   1018 |    856 |    334 |    127 |    103 |      0 |     22 |      0
       Next hand, Venture |   9558 |  14412 |  23231 |  34478 |  34525 |  49298 |  48560 |  47603 |  50959 |  38541 |  39699 |  30776 |  22642 |  20174 |  11285 |   9901 |   5988 |   3316 |   2694 |    912 |    824 |    380 |    111 |    112 |      0 |     21 |      0
     Second Hand, Venture |   9623 |  14626 |  23087 |  34725 |  34343 |  49423 |  48484 |  47678 |  50740 |  38078 |  39770 |  30644 |  22816 |  20093 |  11506 |   9971 |   5968 |   3292 |   2742 |    936 |    873 |    325 |    106 |    120 |      0 |     31 |      0

  Percentage of hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15 |     16 |     17 |     18 |     19 |     20 |     21 |     22 |     23 |     24 |     25 |     26
    Next hand, no Venture |  1.91% |  2.89% |  4.61% |  6.93% |  6.88% |  9.89% |  9.72% |  9.58% | 10.11% |  7.70% |  7.89% |  6.22% |  4.51% |  4.06% |  2.28% |  1.96% |  1.17% |  0.66% |  0.54% |  0.18% |  0.17% |  0.07% |  0.02% |  0.02% |  0.00% |  0.00% |  0.00%
  Second hand, no Venture |  1.90% |  2.93% |  4.64% |  6.86% |  6.87% |  9.86% |  9.77% |  9.52% | 10.16% |  7.71% |  7.95% |  6.11% |  4.54% |  4.02% |  2.26% |  2.00% |  1.20% |  0.66% |  0.54% |  0.20% |  0.17% |  0.07% |  0.03% |  0.02% |  0.00% |  0.00% |  0.00%
       Next hand, Venture |  1.91% |  2.88% |  4.65% |  6.90% |  6.91% |  9.86% |  9.71% |  9.52% | 10.19% |  7.71% |  7.94% |  6.16% |  4.53% |  4.03% |  2.26% |  1.98% |  1.20% |  0.66% |  0.54% |  0.18% |  0.16% |  0.08% |  0.02% |  0.02% |  0.00% |  0.00% |  0.00%
     Second Hand, Venture |  1.92% |  2.93% |  4.62% |  6.95% |  6.87% |  9.88% |  9.70% |  9.54% | 10.15% |  7.62% |  7.95% |  6.13% |  4.56% |  4.02% |  2.30% |  1.99% |  1.19% |  0.66% |  0.55% |  0.19% |  0.17% |  0.07% |  0.02% |  0.02% |  0.00% |  0.01% |  0.00%


Deck: 2x Platinum, 10x Copper

  Total hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14
    Next hand, no Venture |      0 |      0 |      0 |      0 |      0 | 158923 |      0 |      0 |      0 | 265084 |      0 |      0 |      0 |  75993 |      0
  Second hand, no Venture |      0 |      0 |      0 |      0 |      0 | 159042 |      0 |      0 |      0 | 265094 |      0 |      0 |      0 |  75864 |      0
       Next hand, Venture |      0 |      0 |      0 |      0 |      0 | 158997 |      0 |      0 |      0 | 265351 |      0 |      0 |      0 |  75652 |      0
     Second Hand, Venture |      0 |      0 |      0 |      0 |      0 | 158954 |      0 |      0 |      0 | 265035 |      0 |      0 |      0 |  76011 |      0

  Percentage of hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14
    Next hand, no Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 31.78% |  0.00% |  0.00% |  0.00% | 53.02% |  0.00% |  0.00% |  0.00% | 15.20% |  0.00%
  Second hand, no Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 31.81% |  0.00% |  0.00% |  0.00% | 53.02% |  0.00% |  0.00% |  0.00% | 15.17% |  0.00%
       Next hand, Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 31.80% |  0.00% |  0.00% |  0.00% | 53.07% |  0.00% |  0.00% |  0.00% | 15.13% |  0.00%
     Second Hand, Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 31.79% |  0.00% |  0.00% |  0.00% | 53.01% |  0.00% |  0.00% |  0.00% | 15.20% |  0.00%


Deck: 200x Platinum, 1000x Copper

  Total hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15 |     16 |     17 |     18 |     19 |     20 |     21 |     22 |     23 |     24 |     25 |     26
    Next hand, no Venture |      0 |      0 |      0 |      0 |      0 | 200453 |      0 |      0 |      0 | 201531 |      0 |      0 |      0 |  80374 |      0 |      0 |      0 |  16024 |      0 |      0 |      0 |   1555 |      0 |      0 |      0 |     63 |      0
  Second hand, no Venture |      0 |      0 |      0 |      0 |      0 | 200667 |      0 |      0 |      0 | 201323 |      0 |      0 |      0 |  80491 |      0 |      0 |      0 |  15867 |      0 |      0 |      0 |   1593 |      0 |      0 |      0 |     59 |      0
       Next hand, Venture |      0 |      0 |      0 |      0 |      0 | 200165 |      0 |      0 |      0 | 201823 |      0 |      0 |      0 |  80386 |      0 |      0 |      0 |  15991 |      0 |      0 |      0 |   1570 |      0 |      0 |      0 |     65 |      0
     Second Hand, Venture |      0 |      0 |      0 |      0 |      0 | 200995 |      0 |      0 |      0 | 201436 |      0 |      0 |      0 |  80013 |      0 |      0 |      0 |  15977 |      0 |      0 |      0 |   1507 |      0 |      0 |      0 |     72 |      0

  Percentage of hands by coin value:

               Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15 |     16 |     17 |     18 |     19 |     20 |     21 |     22 |     23 |     24 |     25 |     26
    Next hand, no Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 40.09% |  0.00% |  0.00% |  0.00% | 40.31% |  0.00% |  0.00% |  0.00% | 16.07% |  0.00% |  0.00% |  0.00% |  3.20% |  0.00% |  0.00% |  0.00% |  0.31% |  0.00% |  0.00% |  0.00% |  0.01% |  0.00%
  Second hand, no Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 40.13% |  0.00% |  0.00% |  0.00% | 40.26% |  0.00% |  0.00% |  0.00% | 16.10% |  0.00% |  0.00% |  0.00% |  3.17% |  0.00% |  0.00% |  0.00% |  0.32% |  0.00% |  0.00% |  0.00% |  0.01% |  0.00%
       Next hand, Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 40.03% |  0.00% |  0.00% |  0.00% | 40.36% |  0.00% |  0.00% |  0.00% | 16.08% |  0.00% |  0.00% |  0.00% |  3.20% |  0.00% |  0.00% |  0.00% |  0.31% |  0.00% |  0.00% |  0.00% |  0.01% |  0.00%
     Second Hand, Venture |  0.00% |  0.00% |  0.00% |  0.00% |  0.00% | 40.20% |  0.00% |  0.00% |  0.00% | 40.29% |  0.00% |  0.00% |  0.00% | 16.00% |  0.00% |  0.00% |  0.00% |  3.20% |  0.00% |  0.00% |  0.00% |  0.30% |  0.00% |  0.00% |  0.00% |  0.01% |  0.00%
Logged

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #67 on: March 12, 2012, 05:35:02 pm »
0

I still haven't really understood the term "unchanged". "Unchanged" with respect to what? To not playing the Venture?

It seems that can not really be, because the Venture does not stop at a random card, but at a Treasure. So if you have an empty discard, a Venture in hand and a draw-deck of 99 Estates and a Gold, the probability that you will draw a Gold next turn without playing the Venture is 5%. When you play the Venture, the probability of drawing the Gold is a lot smaller, because if you don't reshuffle during drawing your next hand, it's exactly 0%. And even if you reshuffle, which has a probability of 5% (namely if your ventured Gold is on positions 96-100) it's smaller than 5% (namely if your Gold in the next reshuffle is on positions 1-5 [it's smaller because depending on which position the ventured Gold was, you have fewer spots).
So the probability of drawing the Gold next turn, given you play the Venture this turn is smaller than 0.05*0.05 = 0.25%

And that's not because I just have on treasure, you could do the same thing with 98 Estates, 2 Golds and the probability that you draw 2 Golds next turn:
Without Venture probability of drawing 2 Golds next turn is 5/100*4/99.
With Venture to draw 2 Golds, I need to trigger a reshuffle, that is both Golds have to be behind position 95, which has prob 5/100*4/99. Then after the Venture, I'm guaranteed to have the second Gold in hand, but I also need to redraw the first Gold again, which again has probability smaller than 5/100, which gives probability 5/100*5/100*4/99 to this event.

So the "thing" that didn't change (given you don't reshuffle) is the distribution of your cards minus a random Treasure.

And to rate if you want to play an unneeded Venture, these are the two important things: a) Which non-treasure cards are left in my draw, and do I want to play them? b) Which treasure cards are left in my draw deck, and do I want to play them?

Ok, that sounds like it's only thing, and maybe it is. Of course Treasures and non-Treasure act differently, because the less Treasures in my deck, the more other cards I skip (on average).

Edit: Or, what (an unneeded and uninformed) Venture does is to move you a random number of positions forward in your deck, at the cost of a random Treasure. Otherwise it does not change the distribution.

I ran some tests, and it turns out that Venture is actually quite bad for hands on the shuffle boundary in a greening deck.  I'll try to put together a write-up of the results later (no time now), but basically what DStu says here is correct.  Venture hurts your chances of seeing two treasures in the same hand.

I'm sure this will all be further complicated by the fact that bad hands on the shuffle boundary are a good thing in Dominion.
Logged

blueblimp

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2849
  • Respect: +1559
    • View Profile
Re: A theorem about drawing and density
« Reply #68 on: March 12, 2012, 06:15:51 pm »
+1

Lots of good discussion here. I'd just add that the (non-)effect of Venture on the next hand in ecq's simulation is explained by imagining that Venture draws from the bottom of the deck rather than the top. If you don't know your deck order, this is equivalent to how it actually works. With this viewpoint, it's clear that if you have at least 6 treasures in your draw deck, then Venture doesn't change your next hand. In fact, if you have 11 treasures in your draw deck, it doesn't change your next two hands, and so on. (By "doesn't change" here, I mean that the probability of drawing any particular hand is the same.)

That viewpoint (imagining Venture draws from the bottom of the deck) doesn't prove the density result, and it doesn't follow from the density result either. It's a different fact that also suggests that Venture does not help much with sifting.

For this reason, I think that the only consideration is the effect of reshuffles. (But this can be big!)

One other thing: since the cases where you don't want to play Venture are going to be pretty rare, I think the implications here are mostly strategic. For example, in the thread on Venture, there was originally a suggestion that Venture goes well with green-heavy decks due to a claimed sifting effect. If there actually is no sifting effect (as seems to be the case), then there's no reason to expect Venture to be good in a green-heavy deck.
« Last Edit: March 12, 2012, 06:24:55 pm by blueblimp »
Logged

O

  • Jester
  • *****
  • Offline Offline
  • Posts: 836
  • Respect: +605
    • View Profile
Re: A theorem about drawing and density
« Reply #69 on: March 12, 2012, 07:04:50 pm »
0

Lots of good discussion here. I'd just add that the (non-)effect of Venture on the next hand in ecq's simulation is explained by imagining that Venture draws from the bottom of the deck rather than the top. If you don't know your deck order, this is equivalent to how it actually works. With this viewpoint, it's clear that if you have at least 6 treasures in your draw deck, then Venture doesn't change your next hand. In fact, if you have 11 treasures in your draw deck, it doesn't change your next two hands, and so on. (By "doesn't change" here, I mean that the probability of drawing any particular hand is the same.)

That viewpoint (imagining Venture draws from the bottom of the deck) doesn't prove the density result, and it doesn't follow from the density result either. It's a different fact that also suggests that Venture does not help much with sifting.

For this reason, I think that the only consideration is the effect of reshuffles. (But this can be big!)

One other thing: since the cases where you don't want to play Venture are going to be pretty rare, I think the implications here are mostly strategic. For example, in the thread on Venture, there was originally a suggestion that Venture goes well with green-heavy decks due to a claimed sifting effect. If there actually is no sifting effect (as seems to be the case), then there's no reason to expect Venture to be good in a green-heavy deck.

Assuming, of course, that non-venture treasures remain in large. 8 Ventures in a green heavy deck with no other treasures is a helluva lot better than 8 silvers (and often 8 gold). The point to be made here is not that a combo-venture-deck does particularly well in a green-heavy deck: it's that it really doesn't do any worse than in a non-green deck, which is hard to say about most cards.
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: A theorem about drawing and density
« Reply #70 on: March 12, 2012, 08:46:38 pm »
0

Quote
For example, in the thread on Venture, there was originally a suggestion that Venture goes well with green-heavy decks due to a claimed sifting effect. If there actually is no sifting effect (as seems to be the case), then there's no reason to expect Venture to be good in a green-heavy deck.

I think there is already confusion here and I suggest avoiding this line of reasoning as it will be a distraction. A cellar does not change the distribution of the (remainder of) the draw deck when you play it but it is clearly better in a green-heavy deck. You are not fully assessing the value of the venture in the current hand due to the cards in play and cards discarded.
« Last Edit: March 12, 2012, 08:50:46 pm by DG »
Logged

ecq

  • Conspirator
  • ****
  • Offline Offline
  • Posts: 224
  • Respect: +162
    • View Profile
Re: A theorem about drawing and density
« Reply #71 on: March 12, 2012, 10:22:01 pm »
+1

Ok, as promised...

I started simulating what happens at the reshuffle.  Since we're interested in testing the filtering effect of Venture, I only shuffled in cards that were in the original draw pile.  I didn't shuffle in Venture itself, whatever was in the Venture hand, or any buys or previous hands.  All of that stuff would be there in reality, but it seems irrelevant when looking for a filtering effect.

Let T be the number of treasures, and D be the number of non-treasure draws (dead cards).  The expected number of cards that Venture draws is (T + D + 1) / (T + 1).

I construct a deck with 3 treasures and 8 dead cards.  We expect Venture will draw 3 cards in this case.  Because of this, we'll compare it to a Smithy when running the numbers.

That math has been eating at me for a while.  Let's say all the treasures are Copper.  We expect that Venture's draw has a value of $1/3 per card, but the deck's average card value is $3/11.

On to the experiments:

First, we take a deck containing a Platinum, a Gold, a Copper, and 8 dead cards.  We look at the next two hands in if we draw them normally, if we play a Smithy this turn, and if we play a Venture this turn.

Code: [Select]
Deck: 1x Platinum, 1x Gold, 1x Copper, 8x dead

Percentage of hands by coin value (500000 trials):

          Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10
   Next hand, normal | 12.17% | 15.09% |  0.00% | 15.14% | 12.16% | 15.06% | 12.23% |  0.00% | 12.11% |  6.03% |  0.00%
 Second hand, normal | 12.14% | 15.11% |  0.00% | 15.23% | 12.09% | 15.11% | 12.14% |  0.00% | 12.11% |  6.07% |  0.00%
  Next hand, Venture | 12.07% | 15.25% |  0.00% | 15.09% | 13.79% | 15.12% | 13.76% |  0.00% | 13.74% |  1.18% |  0.00%
Second hand, Venture | 16.91% | 16.95% |  0.00% | 17.12% |  9.59% | 17.05% |  9.68% |  0.00% |  9.64% |  3.07% |  0.00%
   Next hand, Smithy | 12.16% | 15.17% |  0.00% | 15.21% | 12.07% | 15.13% | 12.15% |  0.00% | 12.09% |  6.02% |  0.00%
 Second hand, Smithy | 12.00% | 15.11% |  0.00% | 15.17% | 12.13% | 15.19% | 12.22% |  0.00% | 12.11% |  6.07% |  0.00%

The normal hands and Smithy hands all have comparable coin values.  The next Venture hands are significantly worse.  I strongly suspect that it's only the reshuffle hand that's worse on average.  Note that the hand after Venture is almost as good, and that hand is also the least likely to trigger a reshuffle.

In a normal game, though, having a crappy hand at the reshuffle is a good thing.  Let's try a different experiment.  This time, we'll construct two decks.  The first deck contains 6 Coppers, 14 dead cards, and 1 Silver.  The second is the same, but it contains a Venture instead of the Silver.  Note that the Venture will always be worth as much as the Silver.  We'll run through those decks a bunch of times and check the distribution of hand values drawn.

Code: [Select]
Deck 1: 14x dead, 6x Copper, 1x Silver
Deck 2: 14x dead, 6x Copper, 1x Venture

Percentage of hands by coin value (5000000 turns):

Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7
    Deck 1 |  9.84% | 29.51% | 31.74% | 19.68% |  7.75% |  1.41% |  0.07% |  0.00%
    Deck 2 |  9.87% | 29.35% | 31.49% | 19.82% |  7.93% |  1.46% |  0.08% |  0.00%

Those numbers are interesting.  With that many trials, I think the percentages indicate a legitimate difference that can be chalked up to Venture's filtering; however, it's imperceptibly small.  Venture gets ever so slightly better hands.

Let's try it again, this time with a 20-card deck so that nothing misses the shuffle in the Silver deck:
Code: [Select]
Deck 1: 6x Copper, 13x dead, 1x Silver
Deck 2: 6x Copper, 13x dead, 1x Venture

Percentage of hands by coin value (5000000 turns):

Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7
    Deck 1 |  8.28% | 27.69% | 32.29% | 21.13% |  8.79% |  1.72% |  0.10% |  0.00%
    Deck 2 |  8.37% | 27.55% | 31.91% | 21.16% |  9.10% |  1.81% |  0.10% |  0.00%

Similar results.  Venture gets ever-so-slightly better hands.

Finally, let's look at a more realistic deck, where Venture has an average value of $3 and replaces a Gold.

Code: [Select]
Deck: 3x Copper, 5x dead, 4x Gold, 3x Silver
Deck: 5x dead, 3x Copper, 3x Gold, 3x Silver, 1x Venture

Percentage of hands by coin value (5000000 turns):

Coin value |      0 |      1 |      2 |      3 |      4 |      5 |      6 |      7 |      8 |      9 |     10 |     11 |     12 |     13 |     14 |     15
    Deck 1 |  0.03% |  0.50% |  1.51% |  4.01% |  8.00% | 11.46% | 16.47% | 16.57% | 15.49% | 12.41% |  7.19% |  4.20% |  1.57% |  0.50% |  0.10% |  0.00%
    Deck 2 |  0.04% |  0.51% |  1.56% |  4.13% |  7.88% | 11.69% | 15.86% | 16.59% | 15.38% | 12.06% |  7.78% |  4.10% |  1.80% |  0.52% |  0.11% |  0.00%

That one is more complex.  Venture is beneficial depending on your target treasure value.

Before anyone says it, I've run these trials multiple times with a few different parameters, and the results are consistent with one another to the point that I'm convinced we're not looking at statistical noise.

Conclusion:

Because of the expected value formula, we expect Venture to draw cards that are worth more than the average value from the draw pile.  Simulations show this to be the case.  Venture is sending better-than-average cards to the discard, filtering in the wrong direction.  You don't notice the effect until you reach the end of the draw pile, though.  At the reshuffle, you tend to draw a slightly worse hand.

There's another side of this.  Venture, being a card that draws, is more likely to miss the reshuffle.  It's also a better than average treasure by definition. 

In Dominion, it's a good thing to have bad hands miss the reshuffle.  It's a bad thing to have better than average treasures miss the reshuffle.  These effects nearly cancel each other out if you always play Venture.  There is an slight difference in hand values that you'd never notice in practice.

I'd be really interested in someone explaining the math of what happens near the reshuffle point.  It's been way too long since I've done any statistics work.
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: A theorem about drawing and density
« Reply #72 on: March 12, 2012, 11:36:01 pm »
0

Quote
I'd be really interested in someone explaining the math of what happens near the reshuffle point.  It's been way too long since I've done any statistics work.

If there are no treasures left in the draw deck after a venture is played then our current measure of quality, mean card value, is no longer relevant. There will either be no cards in the draw deck so there is no mean, or there are a number of victory cards in the draw deck with mean value of zero and we'd far rather count these cards instead. Perhaps your simulation could count the number of victory cards in the hand carried over the reshuffle and see whether this is a venture advantage. Another useful total to simulate might be the hand values based on the number of treasures remaining in the deck when a venture is played . 

Shuffle maths is very complicated since you have to consider the number of cards drawn before and after the reshuffle, the distribution of the draw pile and the distribution of the discard pile, any adjustments for extra card drawing, size and expansion of decks, etc. There's also a consideration that cards missing one shuffle are ready in the discard pile for the next shuffle along with any cards gained with that hand. If you're wanting to derive the quality and quantity of gained cards between each shuffle and feed those into the new draw deck then this adds further complications and dependencies. I've yet to see anyone put any meaningful maths together regarding shuffles except for chancellors.

Quote
Finally, let's look at a more realistic deck, where Venture has an average value of $3 and replaces a Gold.

You're looking at the hand value of a venture and this is not necessarily the same as a deck value of a venture. You need to compare without shuffles the value of the venture deck with the value of the control deck to confirm the venture is equivalent to the card it is replacing.
Logged

DStu

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2627
  • Respect: +1490
    • View Profile
Re: A theorem about drawing and density
« Reply #73 on: March 13, 2012, 02:09:09 am »
0

So just look at this first:
Quote
Code: [Select]
Next hand, Venture | 12.07% | 15.25% |  0.00% | 15.09% | 13.79% | 15.12% | 13.76% |  0.00% | 13.74% |  1.18% |  0.00%
Second hand, Venture | 16.91% | 16.95% |  0.00% | 17.12% |  9.59% | 17.05% |  9.68% |  0.00% |  9.64% |  3.07% |  0.00%
It seems that in this example, playing Venture slightly increases the chance of having 2 treasure in the next hand ($8, $6, $4), and a little bit more decreases it in the next to next hand. It decreases the chance of having 3 treasures in both hands.
And it increases the chance of having 0 or 1 treasure in the second hand.

Why is that the case? I think 3 treasures is easy, to get 3 treasures in the next hand you actually need to trigger the reshuffle with Venture, and directly redraw the discarded Treasure. To get 3 treasures in the second hand... you may have no treasures in your next hand. That means you have to Venture has to be played in such a way that the second hand triggers a reshuffle, there are no treasures in the next 5 cards, and you directly redraw the discarded Treasure.
I think the part behind the and in both parts is what drops the probability.  Seems in line with what i calculated at the beginning of this page.

For having 2 treasures in hand ... In the next hand that's just the lost percentages of having three treasures in hand, that gets distributed to the 2 treasure hands.
Logged

MasterAir

  • Alchemist
  • ***
  • Offline Offline
  • Posts: 39
  • Respect: +8
    • View Profile
Re: A theorem about drawing and density
« Reply #74 on: March 13, 2012, 05:02:44 am »
0

Slightly off topic, but another good thing about venture in a greening deck is if Venture is played with only dead cards in the draw pile those dead cards miss this shuffle and next shuffle.  (If I'm reading Venture correctly).  Unfortunately, the same is true of action cards, so if they are important to you, you may wish to avoid playing venture.

As an aside, you've convinced me about the mean value of the draw deck, I think the point WanderingWinder makes about the difference between mean value and distribution is very important here.
Logged
Pages: 1 2 [3] 4  All
 

Page created in 0.102 seconds with 20 queries.