Dominion Strategy Forum

Please login or register.

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

Author Topic: Scrying pool "fallacy"  (Read 10482 times)

0 Members and 1 Guest are viewing this topic.

popsofctown

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5477
  • Respect: +2860
    • View Profile
Scrying pool "fallacy"
« on: November 06, 2015, 03:14:07 pm »
+9

There's been an issue I've had with Scrying Pool for a long time.  I'm not sure if my mind keeps dipping into a fallacy, or is doing the odds correctly, but, I've felt confused for a long time.


In a deck that contains Copper, Estate, Peddlers, and Scrying Pools, someone Scrying Pools you and puts Estate on top while you have Scrying Pool and Peddler in hand.

Do you:

1) Play the Peddler so that you can use the Scrying Pool on a "fresh" deck, increasing the chance that the spy effect combs chaff out of your way and hits a stream of action cards.

2) Play the Scrying Pool first so the friendly spy effect is guaranteed to actually discard a card that is bad.  And the Peddler draws a "fresh" card later so this is really the better play.


I keep thinking it's the second one but my brain wants the first one so much it drives me crazy.
Logged

iguanaiguana

  • Minion
  • *****
  • Offline Offline
  • Posts: 600
  • Shuffle iT Username: iguana iguana
  • Respect: +1044
    • View Profile
Re: Scrying pool "fallacy"
« Reply #1 on: November 06, 2015, 03:18:01 pm »
+20

The root of the issue here is that scrying pool games give you way too much time to think about stuff like this.
Logged
Point iguana. Not that points really matter with a result, but still.
Igu is town or trying the hardest he ever has as scum.

ehunt

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1528
  • Shuffle iT Username: ehunt
  • Respect: +1856
    • View Profile
Re: Scrying pool "fallacy"
« Reply #2 on: November 06, 2015, 03:22:54 pm »
+2

I've always followed logic (2), but I think logic (1) is better.

Write X = junk, C = clump of actions A = exactly one action
Playing peddler first is the best move when the top of the deck is
X X C
Playing scrying pool first is the best move when the top of the deck is
X A X

They are equivalent in X X A X or X C  scenarios, and we don't have to worry about scenarios where X isn't on top.

So it looks like playing Peddler first is best if your deck is sufficiently clumpy that scenario 1 is more likely than scenario 2. If scenario 1 and scenario 2 are equally likely, Peddler first is still better (in this case, they're usually equivalent, but when they're not, Scrying Pool first makes you miss a clump worst-case-scenario whereas Peddler makes you miss a card worst-case-scenario).
Logged

Awaclus

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 11815
  • Shuffle iT Username: Awaclus
  • (´。• ω •。`)
  • Respect: +12868
    • View Profile
    • Birds of Necama
Re: Scrying pool "fallacy"
« Reply #3 on: November 06, 2015, 04:03:51 pm »
+1

1.

If you play the Peddler first and then the top card is an Action, you don't get to use SP's spy effect to your advantage, but you super don't care because at least it's still confirmed to be a Lab or better. If you play the Scrying Pool first and the second card from top is not an Action, the SP is just a cantrip. Cycling one bad card is nice, but it's not as nice as drawing one extra card, and you still might get to cycle with the Scrying Pool even if you play the Peddler first.
Logged
Bomb, Cannon, and many of the Gunpowder cards can strongly effect gameplay, particularly in a destructive way

The YouTube channel where I make musicDownload my band's Creative Commons albums for free

popsofctown

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5477
  • Respect: +2860
    • View Profile
Re: Scrying pool "fallacy"
« Reply #4 on: November 06, 2015, 04:10:06 pm »
+2

my head huuuuurts
Logged

Deadlock39

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1722
  • Respect: +1758
    • View Profile
Re: Scrying pool "fallacy"
« Reply #5 on: November 06, 2015, 04:23:07 pm »
+5

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
Scry First: http://jsfiddle.net/z4ses8v9/2/
Scry Second: http://jsfiddle.net/asnnku5j/

So... those are currently set to make decks of 30 actions and 10 junks.  I started with 10 actions and 10 junks and saw no difference, so I thought I would see if higher action density would make a difference.

10,000,000 iterations was about the limit for what I could run before it started to take too long.

None of the tests I ran showed a difference in average number of (action) cards drawn that could be more than about 0.01 card, which leads me to believe the expected number of action cards drawn is the same.

It might be that one of the two options removes more dead cards from your deck on average, so maybe someone wants to tweak those tests a bit to count those.

JW

  • Jester
  • *****
  • Offline Offline
  • Posts: 979
  • Shuffle iT Username: JW
  • Respect: +1792
    • View Profile
Re: Scrying pool "fallacy"
« Reply #6 on: November 06, 2015, 04:29:25 pm »
+3

Do you:
1) Play the Peddler so that you can use the Scrying Pool on a "fresh" deck, increasing the chance that the spy effect combs chaff out of your way and hits a stream of action cards.

2) Play the Scrying Pool first so the friendly spy effect is guaranteed to actually discard a card that is bad.  And the Peddler draws a "fresh" card later so this is really the better play.

If you don't want the Estate that is on top, play the Scrying Pool first. If you do want the Estate, play Peddler first.

Deadlock's simulation is correct that the number of action cards drawn is the same on average. So if you don't want the Estate, you draw more useful non-action cards on average by discarding it
Logged

pacovf

  • Cartographer
  • *****
  • Offline Offline
  • Posts: 3500
  • Multiediting poster
  • Respect: +3838
    • View Profile
Re: Scrying pool "fallacy"
« Reply #7 on: November 06, 2015, 04:46:23 pm »
+5

Dunno, but if you want to draw your whole deck, you should play Peddler first. The amount of Action cards you can draw with Scrying Pool is infinite, so drawing an Action card with Peddler doesn't get you any closer to drawing your whole deck. So you want to draw non-Action cards with it, such as that Estate currently on top of your deck.

I don't know how relevant that is when you are under-drawing your deck.
Logged
pacovf has a neopets account.  It has 999 hours logged.  All his neopets are named "Jessica".  I guess that must be his ex.

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Scrying pool "fallacy"
« Reply #8 on: November 06, 2015, 04:58:38 pm »
0

Assuming you've got an empty discard pile, you generally want to discard as many non-action cards as possible with scrying pools and then the deck will draw well. If you know there is an estate on top of the deck you certainly do want to discard it.

The next deduction is that if you know the opponent has a useless action card on top of the deck, like a ruin, then leave it on top of the deck for their next turn. When the opponent plays the first scrying pool there isn't an immediate opportunity to discard a stop card.
Logged

-Stef-

  • 2012 & 2016 DS Champion
  • *
  • Offline Offline
  • Posts: 1574
  • Respect: +4419
    • View Profile
Re: Scrying pool "fallacy"
« Reply #9 on: November 06, 2015, 05:04:02 pm »
+5

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
...


Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.
Logged
Join the Dominion League!

pubby

  • Minion
  • *****
  • Offline Offline
  • Posts: 548
  • Respect: +1046
    • View Profile
Re: Scrying pool "fallacy"
« Reply #10 on: November 06, 2015, 05:06:55 pm »
0

The amount you gain by going with option #1 is minuscule. It may have a .1% better chance at drawing your deck, but why care? More importantly is the amount you can lose: a dead turn with option #1 is going to be strictly worse than a dead turn with option #2. For that reason, I prefer #2.
Logged

Deadlock39

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1722
  • Respect: +1758
    • View Profile
Re: Scrying pool "fallacy"
« Reply #11 on: November 06, 2015, 05:27:00 pm »
0

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
...


Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

GendoIkari

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 9707
  • Respect: +10765
    • View Profile
Re: Scrying pool "fallacy"
« Reply #12 on: November 06, 2015, 05:38:46 pm »
0

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
...


Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

One thing, that probably doesn't change the results.... you have the opponent always discarding at least 1 card from the top. So even if the top card is a non-Action, it gets discarded, then more cards get discarded until there's a non-action.
Logged
Check out my F.DS extension for Chrome! Card links; Dominion icons, and maybe more! http://forum.dominionstrategy.com/index.php?topic=13363.0

Thread for Firefox version:
http://forum.dominionstrategy.com/index.php?topic=16305.0

JW

  • Jester
  • *****
  • Offline Offline
  • Posts: 979
  • Shuffle iT Username: JW
  • Respect: +1792
    • View Profile
Re: Scrying pool "fallacy"
« Reply #13 on: November 06, 2015, 05:39:46 pm »
+1

Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.

I also got that the average number of action cards is the same (when you include the card drawn from Peddler). If you play the Peddler first, you draw the Estate on top of your deck, and you get one other non-action card. If you play the Pool first, you get 1 non-action card from Pool plus some probability of another non-Action card with Peddler.

If the Estate is worthless, the average number of "useful cards drawn" looks better when you play the Pool first. So the difference in results may just be a different way of looking at it.

I used calculations based on math derived here: http://forum.dominionstrategy.com/index.php?topic=11583.msg408311#msg408311 and http://forum.dominionstrategy.com/index.php?topic=11583.msg408300#msg408300
Logged

GendoIkari

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 9707
  • Respect: +10765
    • View Profile
Re: Scrying pool "fallacy"
« Reply #14 on: November 06, 2015, 05:40:43 pm »
0

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
...


Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

One thing, that probably doesn't change the results.... you have the opponent always discarding at least 1 card from the top. So even if the top card is a non-Action, it gets discarded, then more cards get discarded until there's a non-action.

It DID make a big difference. Not sure why. I used:

var top = deck[deck.length - 1];

First: 2.72386
Second: 3.284911

*Edit*
Pretty sure this is what's wrong:

top = 'A' //initialize

You can't just assume there's an action on top after the dead card was removed.
« Last Edit: November 06, 2015, 05:44:03 pm by GendoIkari »
Logged
Check out my F.DS extension for Chrome! Card links; Dominion icons, and maybe more! http://forum.dominionstrategy.com/index.php?topic=13363.0

Thread for Firefox version:
http://forum.dominionstrategy.com/index.php?topic=16305.0

-Stef-

  • 2012 & 2016 DS Champion
  • *
  • Offline Offline
  • Posts: 1574
  • Respect: +4419
    • View Profile
Re: Scrying pool "fallacy"
« Reply #15 on: November 06, 2015, 05:45:55 pm »
+3

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

Ah I now looked at what you did and we are counting different things yes.

This is what I did:

for every combination of coppers (5-10), estates (3-8), peddlers (2-4) and scrying pools (2-7):
    do 10000 times:
         shuffle all cards except for 1 estate, which goes on top.
         your hand starts with 1 peddler and 1 scrying pool.
         simulate playing the turn with
             #1 always play peddler when you can, pool otherwise
             #2 always play pool when you can, peddler otherwise
         Now what gets you the most coins? (both coppers and peddlers generate coins)

Given these circumstances, strategy #2 is just plain better.
Logged
Join the Dominion League!

Deadlock39

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1722
  • Respect: +1758
    • View Profile
Re: Scrying pool "fallacy"
« Reply #16 on: November 06, 2015, 05:49:19 pm »
0

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
...


Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

One thing, that probably doesn't change the results.... you have the opponent always discarding at least 1 card from the top. So even if the top card is a non-Action, it gets discarded, then more cards get discarded until there's a non-action.

It DID make a big difference. Not sure why. I used:

var top = deck[deck.length - 1];

First: 2.72386
Second: 3.284911

*Edit*
Pretty sure this is what's wrong:

top = 'A' //initialize

You can't just assume there's an action on top after the dead card was removed.

Which link and which line are you looking at in particular there.  I did some of that in a really dumb way because I didn't think to use array.peek(). I think the one you are looking at is there to seed the loop because if the pop before it was a non action, it gets discarded by Scrying Pool.

GendoIkari

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 9707
  • Respect: +10765
    • View Profile
Re: Scrying pool "fallacy"
« Reply #17 on: November 06, 2015, 05:54:40 pm »
0

my head huuuuurts

I agree... I tried to reason through this, but it was beyond my capability for mathematical proofiness.  Instead I tried to brute force it:
...


Are you sure you got it right though? I also tried to brute force it and I get significantly better results when you play the pool first.
Which also happens to be what I always do when playing dominion, and what my intuition tells me what is best.

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

One thing, that probably doesn't change the results.... you have the opponent always discarding at least 1 card from the top. So even if the top card is a non-Action, it gets discarded, then more cards get discarded until there's a non-action.

It DID make a big difference. Not sure why. I used:

var top = deck[deck.length - 1];

First: 2.72386
Second: 3.284911

*Edit*
Pretty sure this is what's wrong:

top = 'A' //initialize

You can't just assume there's an action on top after the dead card was removed.

Which link and which line are you looking at in particular there.  I did some of that in a really dumb way because I didn't think to use array.peek(). I think the one you are looking at is there to seed the loop because if the pop before it was a non action, it gets discarded by Scrying Pool.

My updates:

First: http://jsfiddle.net/z4ses8v9/3/
Second: http://jsfiddle.net/asnnku5j/1/

Ignore those results I posted first, I had other mistakes in my correction of your stuff.

*Edit* If I understand correctly, Array.Peek would just show you the bottom card of the deck, not the top.
« Last Edit: November 06, 2015, 05:56:03 pm by GendoIkari »
Logged
Check out my F.DS extension for Chrome! Card links; Dominion icons, and maybe more! http://forum.dominionstrategy.com/index.php?topic=13363.0

Thread for Firefox version:
http://forum.dominionstrategy.com/index.php?topic=16305.0

blueblimp

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2849
  • Respect: +1559
    • View Profile
Re: Scrying pool "fallacy"
« Reply #18 on: November 06, 2015, 05:55:55 pm »
+4

Do you:
1) Play the Peddler so that you can use the Scrying Pool on a "fresh" deck, increasing the chance that the spy effect combs chaff out of your way and hits a stream of action cards.

2) Play the Scrying Pool first so the friendly spy effect is guaranteed to actually discard a card that is bad.  And the Peddler draws a "fresh" card later so this is really the better play.

If you don't want the Estate that is on top, play the Scrying Pool first. If you do want the Estate, play Peddler first.

Deadlock's simulation is correct that the number of action cards drawn is the same on average. So if you don't want the Estate, you draw more useful non-action cards on average by discarding it
I'm pretty sure this is correct. The decision is, do you want the Estate in hand vs a chance at drawing some alternative non-action card into hand later. (Keep in mind that having the estate in hand means it's not in your discard pile, so if you're going to shuffle soon, having it in hand could be pretty helpful.)

Here's how I think of it. The spy effect on Scrying Pool might as well read "look at the top card of your deck; if it's an action, draw it, otherwise discard it", since that's typically how it's played. That makes it a lot simpler to think about, because then the spy effect and dig effect don't interact.

If we make a big simplifying assumption that all your non-actions are junk and it doesn't matter whether they are in hand or in discard (which also means we're ignoring reshuffling during your turn), then the spy effect on Scrying Pool is effectively "draw a card". With this simplifying assumption, no matter which order you play pool and peddler, the pool's dig will be digging into an unknown part of your deck, so it's equally good. And it doesn't matter which order you play the draw effects in, so, therefore _with this assumption_, the order of play doesn't matter.

Now let's discard the assumption. The difference between spying a non-action with pool and drawing it with peddler is whether you put it into hand or discard. If you play peddler first, you guarantee the Estate goes into your hand. If you play pool first, you guarantee the estate goes to discard, then when you play peddler after, it has a chance of drawing a non-action, which would go to your hand.
Logged

Deadlock39

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1722
  • Respect: +1758
    • View Profile
Re: Scrying pool "fallacy"
« Reply #19 on: November 06, 2015, 05:56:27 pm »
0

I wrote it hastily, so no, I am not certain I got it right.  It wasn't complicated though, so I am not sure what might have gone wrong.  If I didn't make a mistake coding, I might have made a mistake deciding what to count.  If you count how many cards into your deck you get, then you would get a number equal to action density better for Scrying first than what I got because I only counted the expected number of action cards drawn, and ignored the junks.

Ah I now looked at what you did and we are counting different things yes.

This is what I did:

for every combination of coppers (5-10), estates (3-8), peddlers (2-4) and scrying pools (2-7):
    do 10000 times:
         shuffle all cards except for 1 estate, which goes on top.
         your hand starts with 1 peddler and 1 scrying pool.
         simulate playing the turn with
             #1 always play peddler when you can, pool otherwise
             #2 always play pool when you can, peddler otherwise
         Now what gets you the most coins? (both coppers and peddlers generate coins)

Given these circumstances, strategy #2 is just plain better.

Yeah, I absolutely agree.  I think it really comes down to me answering the wrong question with what I did.

I think these are all true of just playing the first two cards:
The total expected number and ratio of junk/action is the same for both.
The total expected number of cards sifted is greater for #2 by the action density of your deck. (This should give you a better outlook for the rest of your turn)
The total expected value of the junk you drew after playing the first two cards is higher because you drew a random junk instead of a guaranteed Estate.

The first test I wrote answered the first question, but that wasn't a very useful thing to test.

Deadlock39

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1722
  • Respect: +1758
    • View Profile
Re: Scrying pool "fallacy"
« Reply #20 on: November 06, 2015, 05:58:07 pm »
0

*Edit* If I understand correctly, Array.Peek would just show you the bottom card of the deck, not the top.

I'd have to check the JavaScript spec to be sure, but in every other implementation I have used, "peek" is identical to "pop" except it does not remove anything from the structure.

Edit: Looks like you are right.  You would want .peekBack() for a stack operation. wierd...
Good thing I didn't try to use it.  :)
« Last Edit: November 06, 2015, 06:01:23 pm by Deadlock39 »
Logged

GendoIkari

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 9707
  • Respect: +10765
    • View Profile
Re: Scrying pool "fallacy"
« Reply #21 on: November 06, 2015, 06:02:16 pm »
0

*Edit* If I understand correctly, Array.Peek would just show you the bottom card of the deck, not the top.

I'd have to check the JavaScript spec to be sure, but in every other implementation I have used, "peek" is identical to "pop" except it does not remove anything from the structure.

Edit: Looks like you are right.  You would want .peekBack() for a stack operation. wierd...
Good thing I didn't try to use it.  :)

It appears peek isn't actually a part of JavaScript. At least, it doesn't run on Chrome. I found one framework that implements it as returning what shift() would; the first element.
Logged
Check out my F.DS extension for Chrome! Card links; Dominion icons, and maybe more! http://forum.dominionstrategy.com/index.php?topic=13363.0

Thread for Firefox version:
http://forum.dominionstrategy.com/index.php?topic=16305.0

-Stef-

  • 2012 & 2016 DS Champion
  • *
  • Offline Offline
  • Posts: 1574
  • Respect: +4419
    • View Profile
Re: Scrying pool "fallacy"
« Reply #22 on: November 06, 2015, 06:03:28 pm »
+3

thank god I used a real language
Logged
Join the Dominion League!

Deadlock39

  • Torturer
  • *****
  • Offline Offline
  • Posts: 1722
  • Respect: +1758
    • View Profile
Re: Scrying pool "fallacy"
« Reply #23 on: November 06, 2015, 06:10:45 pm »
+2

thank god I used a real language

Prolog?

SCSN

  • Mountebank
  • *****
  • Offline Offline
  • Posts: 2227
  • Respect: +7140
    • View Profile
Re: Scrying pool "fallacy"
« Reply #24 on: November 06, 2015, 06:17:29 pm »
+9

By real language he means Dutch; it makes all of Dominion obvious.
Logged
Pages: [1] 2  All
 

Page created in 3.128 seconds with 20 queries.