Advertisement
rockbard

How Many Lands Should I Use In My EDH Deck?

Mar 3rd, 2020
465
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 2.06 KB | None | 0 0
  1. # How Many Lands Should I Use In My EDH Deck?
  2. # Script in Python written by Gabriel G.S.
  3.  
  4. # This script calculates a baseline number of lands you should run in your EDH deck based on your deck's converted mana cost.
  5. # I use an equation derived from the work of Mr. Frank Karsten for 60-card decks and apply it for 99-card decks:
  6. # y = 4.6071x + 24.3465, where x is the converted mana cost of the deck and y yields the number of lands the deck should use.
  7.  
  8. # Step 1: Calculate the average converted mana cost of your deck (including your commander) and type it in the next row:
  9. avg_cmc = 3.03 # This example is from my Sidisi, Brood Tyrant deck @ 2020.03.01
  10.  
  11. # Step 2: Type the converted mana cost of your commander in the next row:
  12. comm_cmc = 5 # This example is from my Sidisi, Brood Tyrant deck @ 2020.03.01
  13. # This formula calculates the average converted mana cost of your deck without your commander
  14. deck_avg_cmc = ( avg_cmc * 100 - comm_cmc ) / 99
  15.  
  16. # Step 3: The commander's converted mana cost has to be accounted for in calculating the number of lands/cheap mana rocks/cheap land fetch spells you should use.
  17. # The next formula calculates the adjusted average converted mana cost of your deck by applying the following weights:
  18. deck_weight = 7/8
  19. comm_weight = 1/8
  20. adj_avg_cmc = deck_weight * deck_avg_cmc + comm_weight * comm_cmc
  21. # The assumption is that the commander is the 8th card in your hand, so I chose to apply the 1/8 weight to the commander's converted mana cost.
  22.  
  23. # Step 4: Apply the equation with the deck's variables:
  24. m = 4.6071
  25. b = 24.3465
  26. x = adj_avg_cmc
  27. y = m * x + b
  28. # The recommended number of lands is rounded to the nearest integer.
  29. lands = int(round(y,0))
  30.  
  31. # Step 5: Print the results.
  32. print("The deck's average converted mana cost is " + str(round(avg_cmc,2)))
  33. print("The commander's converted mana cost is " + str(comm_cmc))
  34. print("The adjusted average converted mana cost is " + str(round(adj_avg_cmc,2)))
  35. print("The recommended number of lands for this deck is " + str(lands))
  36.  
  37. # Script last updated on 2020.03.03
  38. # =^.^= Happy Cat MTG
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement