Given a Hearthstone card collection how to determine the optimal card pack to purchase?

I think this would work. The OP has already accounted for needing two of all cards except legendary and one of each legendary in the collection counts.

For each rarity, the spreadsheet multiplies the chance of that card type by 5 (the size of a pack) then by the chance of that card being a new one for the user (not-owned / total). And then at the end of the line is just a sum of the chance for each rarity. To make it easier for people with a similar question in the future make a copy of this Google Sheet and then edit it with your own numbers.

It looks like in the OP's case it's very close to a toss-up for GvG vs. TGT packs, with each type of pack having slightly better than a 1-in-5 chance of giving the OP an unowned card. The chance of getting an unowned card from a Classic pack is only 4%, or 1-in-25.

Spreadsheet image

Edited to add: As documented in the answers to this question the probability of opening a specific rarity is the the same across all pack types. (Thanks to @KarouiHaythem for pointing out this related question in the comments.)

Also, I did not address dust cost because, as long as dusting a card yields less dust than it costs to craft, the optimal solution is to open a card rather than craft it. (As noted by @Dacio in the comments.) Therefore the solution focuses on the optimal type of pack to maximize chances of opening an unowned card.


To start on this, I had to make a few assumptions and simplifications:

  1. The probabilities of different rarities is consistent between expansions: i.e. a classic pack has the same chance of giving you a rare, epic or legendary as a GvG pack. This seems probable, given the low variance between different studies I found, but given the sample size, the real probabilities could be off by ~0.5%. This is unlikely to change the overall value of a pack.
  2. The probability between a Rare, Epic and Legendary is the same relative distribution for the one-rare-per-pack-or-better as it is for an extra rare-or-better cards per pack. I'll try to show this in the calculations below, but it's an important assumption that I don't have data to back up.
  3. The probability of an extra card being rare, epic or legendary is independent of the guaranteed rare-or-better card of having been rare, epic or legendary.
  4. All cards are valued in dust; a card you don't have is valued in the dust it costs to create.
  5. A card you do have is valued by the dust it would give you from disenchanting.
  6. We can ignore the impact of golden cards if we assume the probability of getting a golden cards is equal between each expansion pack type. This will depress the actual expected dust values for each pack reported in this answer, but should do so equally for each pack type.

I made a Google spreadsheet, but here are the pertinent parts.

A pack is guaranteed to have a rare in it - the probabilities for that card being a Rare, Epic or Legendary are obviously higher than the 4 other cards in the pack.

Rarity   Count  % Total   Rare+ Card %  Other 4 Cards %
Common   99836   71.65%       0.00%      89.56%
Rare     31821   22.84%      80.55%       8.41%
Epic      6152    4.42%      15.57%       1.63%
Legend    1531    1.10%       3.88%       0.40%
Total   139340  100.00%     100.00%     100.00%

Table 1 - breakdown of card probabilities accounting for the guaranteed Rare+ card

  • Of the 139340 cards in the linked meta study, 39504 were rare or better (i.e. Rare+).
  • There were 27868 packs opened in the linked meta study, therefore 27868 expected Rare+ cards (also 1/5 the total number of cards).
  • Which leaves us with 11636 extra Rare+ cards.
  • And 111472 cards which were not guaranteed to be rare or better (4/5 the total number of cards).
  • Rare+ Card %: The rare-or-better card in the pack has a 0% chance of being common. To calculate it's chance of being each of the Rare+ rarities (Rare, Epic and Legend), you take the total number of cards of that rarity and divide by the total number of Rare+ cards in the study. (This is assumption 2 in practice.)
    • For rares, this is 31821 / 39405 = 80.55%.
    • Epic: 6152 / 39405 = 15.57%
    • Legend: 1531 / 39405 = 3.88%
  • The chance of one of the other, not-guaranteed-to-be-rare-or-better being Rare+ is the number of extra rare cards divided by four-fifths of the total cards: 11636 / 111472 = 10.44%
  • Other 4 Cards %: Obviously much more likely to be common, but also demanding different calculations for the Common% than the Rare+%.
    • Common%: Total number of commons divided by the 4/5s of the total cards. 99836 / 111472 = 89.56%
    • Rare+%: Probability of the rarity times the probability of the card being rare+
    • For Rare, this is 80.55% * 10.44% = 8.41%
    • Epic: 15.57% * 10.44% = 1.63%
    • Legendary: 3.88% * 10.44% = 0.40%

This elevates the expected dust value of that card (and the pack in general) significantly higher than the pure-disenchanting dust found in other studies (Reddit says ~105 dust, the wiki linked in the question and cited for much of the data of this answer says ~98 dust), even though we ignore the impact of golden cards.

Now we need to apply those probabilities for receiving each type of card to your collection specifics.

  • GvG: 178/226 (123 collectible cards, need 2x Common, Rare and Epic, 1x Legendary)
    Counts, including duplicates: have/total
    • Common 80/80 - 100% chance to be duplicate, 0% chance to be new
    • Rare 70/74 - 94.59% dupe, 5.41% new
    • Epic 22/52 - 42.31% dupe, 57.69% new
    • Legendary 6/20 - 30.00% dupe, 70.00% new
Rarity  Rare+ % Rare+ Dust  Other 4 %   Other 4 Dust
Common   0.00%   0          89.56%      17.91
Rare    80.55%  19.59        8.41%       8.18
Epic    15.57%  42.53        1.63%      17.76
Legend  3.88%   48.06        0.40%      20.07
        Sum     110.18      Sum         63.92

Total Pack Dust Value   174.09

Table 2 - The expected dust value of each card in a pack of Goblins vs. Gnomes (GvG) for @ashteele's collection.

Here's where it gets a little arcane. The probabilities (columns 2 and 4) are copied from the Table 1 above. The dust value is calculated by taking the rarity probability and multiplying the sum of respective dust values times the probability for a duplicate and a new, needed card.

So for a GvG Rare on the Rare+ card, that's 80.55% chance to be a rare, 70/74 chance to be a dupe for 20 dust and 4/74 chance to be a new card for 100 dust.

  80.55% * ( 20 dust * 70/74  + 100 dust * 4/74  )  
= 80.55% * ( 20 dust * 0.9459 + 100 dust * 0.0541)
= 80.55% * ( 18.92 dust       + 5.41 dust        )
= 80.55% *   24.25 dust
= 19.59 dust

Repeat for each card rarity and probability pair on Rare+ and Other4 and you get an expected dust value for a GvG pack of 174.09 dust. As you get more new GvG cards and your collection nears completion, this will decrease and approach the disenchant-only dust value of a pack of ~100 dust, thus my comment on the heuristic approach of picking a pack by the least complete collection.

But it remains to be seen if that approach holds for the rest of collection, since they each have a unique number of needed and missing cards. I expect it will, because you are missing fewer TGT rares and epics and an equal number of TGT legendaries, and even fewer Classic Epics and Legendaries and no Classic Rares. But for completeness, here are the charts.

Rarity  Rare+ % Rare+ Dust  Other 4 %   Other 4 Dust
Common   0.00%    0         89.56%      19.19
Rare    80.55%   18.80       8.41%       7.85
Epic    15.57%   38.07       1.63%      15.89
Legend   3.88%   48.06       0.40%      20.07
        Sum     104.92      Sum         63.00

        Total Pack Value    167.92      

Table 3 - The expected dust value of each card in a pack of The Grand Tournament (TGT) for @ashteele's collection.

Rarity  Rare+ % Rare+ Dust  Other 4 %   Other 4 Dust
Common   0.00%   0          89.56%      17.91
Rare    80.55%  16.11        8.41%       6.73
Epic    15.57%  20.62        1.63%       8.61
Legend   3.88%  29.60        0.40%      12.36
        Sum     66.33       Sum         45.61

        Total Pack Value    111.94

Table 4 - The expected dust value of each card in a Classic Pack for @ashteele's collection.

So I came to the same conclusion as lasarusL's answer: GvG is the most beneficial for you to open, followed closely by TGT with Classic being a distant 3rd. My numbers are a little higher than even 5 times his, but as I kind of suspected when I started doing the math, the one-rare-or-better per pack guarantee doesn't really tip the scales that much. What would be worthwhile I think would be re-crunching the numbers for each expansion and card rarity to simplify my 5 page spreadsheet down to a simple formula of just 4 multiplications and one summation for each expansion.


The expected value per pack is going to be the probability of you getting a card you need*its price in dust. So for each pack we can calculate its expected value in cards you need as:

commonCost(commonsRemaining/possibleCommons)commonProbability + rareCost(raresRemaining/possibleRares)rareProbability + epicCost(epicsRemaining/possibleEpics)epicProbability + legendaryCost(legendariesRemaining/possibleLegendaries)legendaryProbability

Technically, it is 5 times that, since you get 5 cards, but we will only use this as a comparison tool.

So for your example: Classic is 0 + 0 + 400(8/74).0442 + 1600(10/33).0110 = 7.24

GvG is 0 + 100(4/74).2284 + 400(30/52).0442 + 1600(14/20).0110 = 23.75

TGT is 40(1/90).7165 + 100(3/72).2284 + 400(26/54).0442 + 1600(14/20).0110 = 22.10

So you should buy GvG packs and craft classic cards (since they're the most expensive for you to get through packs).

I think you could get a slightly better calculation if you factored in that needing 2 of one rare makes your odds worse than needing 1 of 2 each of 2 different rares.

Tags:

Hearthstone