1. Welcome to Smogon Forums! Please take a minute to read the rules.
  2. Click here to ensure that you never miss a new SmogonU video upload!

XY BSR Calculator + Movepool Builder

Discussion in 'Create-A-Pokémon Project' started by bugmaniacbob, Oct 24, 2013.

  1. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    Birkal said I could post this

    XY BSR Calculator (Download) [Up to date through ORAS]
    XY Movepool Builder (Download)

    Here's what's been changed:

    Base Stat Ratings Calculator
    • Added the new Pokemon base stats, added Mega Evolution base stats, updated stats for previous Pokemon known to have had revisions.
    • As far as I'm aware, the calculation of stats from base stats hasn't changed, given the more or less identical stat ranges for existing Pokemon, so I'm assuming that the BSR formula does not need updating barring the traditional weighting for average and standard deviation (which has been done).
    • Also colours were changed. I think red suits "bad" better than "amazing". But do say if you find it too garish, or some other similarly inane critique.
    • We still need stats for Rebble, Bolderdash, Privatyke, Nohface, Monohm, Duohm, Colosshale, Protowatt and Voodoll (and yes this is a very trivial thing to be concerned about and no I don't know why it's annoying me so much either).
    • Hoopa, Diancie, and Volcanion are currently not filled in as they do not currently exist.
    Movepool Builder
    • For the 99% of you who don't know what this is, this was supposed to be a helpful tool to let people keep track of their RMs and such without having to repeatedly check with the lists or do re-counts. It's essentially just a hand-holding tool if you can't be bothered to use Notepad. Or to type out all the TM moves yourself.
    • Changed the word "VGM" to "RM" everywhere
    • 6th Gen RM lists have been implemented
    • New RM doubles have been added
    • Added type-move and move-move lists
    --------------

    So. The point of this thread is mainly to avoid any duplicated effort, in case anybody else wanted to update this as well - at the very least, you can use the above as a starting point for any further improvements you wish to make.

    Again, any comments you wish to make are appreciated. And, uh... nice to be back, I suppose. Sorry to those of you who expected a novel. Maybe next time.
    Last edited by a moderator: Jul 21, 2016
    Ignus, Agile Turtle, Eagle4 and 9 others like this.
  2. Luigifan

    Luigifan

    Joined:
    Sep 5, 2010
    Messages:
    169
    Hey, kudos on the Base Stat Rating Calculator. It's great to have an updated model. I do miss the old Offense-Defense Balance and Physical-Special Balance ratings, though. (Sure, in most cases it's obvious, but then you have Pokémon like Snorlax and Ho-Oh (high Attack and Special Defense, relatively low Defense and Special Attack) that make it rather interesting.) I'm also perturbed by the removal of the data readouts for normalized HP, Attack, Defense, Special Attack, and Special Defense, but I have to say that the new Speed Factor is much better than the old Speed Rating; the latter was thrown off by anything faster than Deoxys-S, resulting in sweepiness ratings lower than they should have been. Anyways, is there any possibility of the Base Stat Rating calculator being updated to re-include those old features?
  3. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    Um

    I'm pretty certain the formulae haven't included the normalised stat values for... about four years now... the current formulae use the values for the stats at level 100, rather than the original normalised values. We've also used Speed Factors for a similar length of time... I'm not sure why you seem so familiar with those formulae when they predate your join date, but eh. I removed ODB and PSB (well I removed them more than a year ago now but for sake of argument) because they don't actually have any relevance to the stat spread submissions stage any longer and they tend to clog up the document. If more people wanted them then I could add them, sure, but there doesn't seem to be a colossal demand for them at present.

    So... yeah I'm really confused right now. In answer to your question, I very much doubt that these features will be included again, at least before the calculator accurately reflects XY in its entirety, unless there's significant demand for it.

    EDIT: Oh and since I posted, I'll just mention that I updated the calculator to reflect the most recent changes to the old Pokemon stats. I also fixed a typo with Pidgeotto's Speed that rather threw off the sweepiness ratings a tad.
    Last edited: Nov 7, 2013
  4. xyril

    xyril

    Joined:
    Nov 20, 2013
    Messages:
    3
    Thanks for the sweet spreadsheets! Just want to point out a typo that's throwing off the calculations for those with 150 base speed. On the Speed Factor worksheet in the BSR Calculator, cell F151 should be =COUNTIF($C$1:$C$1000,"<=150") and not =COUNTIF($C$1:$C$1000,"<=110").

    Edit--
    Found a few more: F71, F72, F171, F172, and F251.
    Last edited: Nov 20, 2013
  5. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    That was well spotted, thank you! I fixed all the above for errors, adjusted the formulae appropriately and checked for more errors, so hopefully that's all settled now.
  6. Luigifan

    Luigifan

    Joined:
    Sep 5, 2010
    Messages:
    169
    Have you updated the download link?
  7. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    It should update automatically whenever I make changes to it. I just checked and it seems to have done so.
  8. RP2865

    RP2865

    Joined:
    Jan 5, 2014
    Messages:
    134
    I have something that I would like to point out. Keep in mind I just saw this today, and am not an expert by any means.

    I think that the calculator values speed a bit too much for PS and SS, and should have more input from the defenses. To illustrate, I put in a Pokemon that had 300/300/300/300/300/1 stats, and it was only "Above Average" as a sweeper in both categories. (120.5 PS and 124 SS). Imagine Dragonite (which in the calc has as 176.7 PS and 136 SS, "Excellent" and "Good" respectively" with triple the HP and defenses, more than double the attack, and a special attack that equaled that (which would require multiplying it by about 3.5). The one flaw it had was less speed, and speed is a problem for Dragonite anyway as of now. You might say "but now Dragonite can't really use Dragon Dance because the speed boost won't make a difference, and Agility is pointless, while Dragonite can't use Swords Dance etc.!". With that base 300 attack, it has more than a Swords Dance with no setup! (I know the calc doesn't take movepools into effect, but imagine dragonite seriously using Fire Blast, Draco Meteor, Surf, Ice Beam, Thunderbolt, and more as strong as it's physical moves!) Yet in the calc, as mentioned, it is only "Above Average", worse than it is now, as sweeping! With those HP and defenses, it can take hits fine! Speed isn't the issue.
    Thanks again, for the calc.
    EDIT: A pokemon with 1 HP and 350 in both defenses is "Amazing". Lol
    EDIT2: I may have found an actual error. While you put speed as "1", the SF is zero, when you put it as "0", the SF is 28. And why is Shuckle only a "bad" special sweeper, when it is tied for the lowest speed and special attack stats in the game?
    Last edited: Apr 5, 2014
  9. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    The defensive stats don't have any input into PS/SS; all that PS/SS are telling you is how well the Pokemon throws around hits, which is essentially calculated from its raw base stat in Attack or Special Attack, while factoring in the number of Pokemon it can outrun, which is really all that "sweepiness" actually means. Conversely, "tankiness" refers to how well the Pokemon takes hits, and is calculated from HP and one of the defences. In that case, your hypothetical 300/300/1 sweeper is a terrible sweeper by these specifications, since it will always be outrun; the fact that it takes little damage is not taken into account, as that's what the overall BSR calculation is for.

    Remember that in the real game, Speed is the single most important stat - outrunning something is the only thing that can make a literal world of difference.

    The 1 HP and 350 defences Pokemon is pretty amazing, since 350 defence is impossible (the highest you can get is 255 in any stat, unless they changed it for XY; even so, no Pokemon can or probably ever will have a stat that high), and the calculator doesn't take into account that 1 HP base is like Shedinja - it assumes that that Pokemon has 143 HP, since that's the lowest it can go.

    That's weird - I get 0 for SF when I input Speed as 0. Not sure if you want to double-check that.

    Also, Shuckle is only a "Bad" special sweeper because of the way the calculations are set up - all of the stats are scaled so that the average for PS/PT/SS/ST across every single Pokemon in the game is exactly 100, and the standard deviation between them is 50. If your PS is above 100, you're immediately above average. Unfortunately, this means that because of where the average is for SS, it is impossible to get a Pokemon with a "Horrible" rating - even 1 SpA and 1 Spe still gets you just above 25.0, which is a shame but not really of any consequence for our purposes.

    Feel free to point out anything else you see; feedback and critique are always welcome.
  10. RP2865

    RP2865

    Joined:
    Jan 5, 2014
    Messages:
    134
    Well, that makes a lot of sense, thanks. But for the first paragraph, I understand what you mean, but wish that the BSR calc would be changed so that HP and defenses have some sort of an impact, but I am not sure if that would be reasonable. As for the part about putting 0 in the Speed and having the SF be 28... things got weird when I double checked it. The first time (I put 0 for speed), I got an arbitrary SF of 5. Subsequent times gave me 14. Maybe it's just my computer, but that's quite unusual...
    Wait, there's more. Now, it's 27. And 43. And 47. So confused...
    Better idea. Here is what the SF equals, when I put speed as zero, for every row.
    Row 1: 5
    2:5
    3:14
    4:14
    5:14
    6:14
    7:14
    8:27
    9:27
    10:28
    11:32
    12:33
    13:43
    14:43
    15:43
    16:47
    17:50
    18:83
    19:85
    20:89
  11. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    Ultimately there always needs to be some sort of concession made when making what is essentially a theoretical model; some types make inherently better defensive or offensive typings than others, for example. The BSR calculation in its entirety takes all stats into account; the PS/SS/PT/ST is simply a neat way of breaking it up to measure and weigh the most metagame-relevant parts of the stats themselves.

    Yes, as I said earlier, a Pokemon's Speed stat cannot be zero, so there is no "zero" entry in the table in question, so you're asking the spreadsheet to search another spreadsheet for an entry that doesn't exist. I thought that this would throw up either an error message or, in my case, simply zero, but apparently in your case it's returning the values from the table it's searching from the same row as the row you entered the zero in - in "row 1" of the calculator, you're inputting the 0 into row 14 of the spreadsheet, so it returns the value from the lookup table from row 14 (which is 5, or the number of Pokemon that a CAP with 13 base Speed would outrun or speed tie). The same is happening in the rest of the rows (as you can see if you look at the "Speed Factors" tab). I presume that you have a different version of Excel.
  12. bugmaniacbob

    bugmaniacbob Was fun while it lasted
    is an Artist Alumnusis a CAP Contributor Alumnusis a Contributor Alumnusis a Smogon Media Contributor Alumnus

    Joined:
    Sep 19, 2008
    Messages:
    2,305
    BSR calc is up to date for ORAS, and everything got just a little bit worse apparently

    Movepool builder will probably have to be rebuilt to accommodate PRC changes so that's on ice for now
  13. jas61292

    jas61292 used substitute
    is a Forum Moderatoris a Community Contributoris a CAP Contributoris a Battle Server Moderator
    Moderator

    Joined:
    Sep 30, 2010
    Messages:
    3,423
    I've updated the link in the OP with the most up to date version of the calculator, featuring adjustments with respect to the fact that we are now building for the CAP metagame.
  14. Alondite

    Alondite

    Joined:
    Sep 3, 2016
    Messages:
    1
    I have a question regarding the BSR formula, specifically for RPS RSS. The formula reads as follows:


    RPS = SAtk * (SAtk * SSpe + 415) / (SAtk * (1 - SSpe) + 415)
    RSS = SSpA * (SSpA * SSpe + 415) / (SSpA * (1 - SSpe) + 415)

    My question is: What is the purpose of the +415 in this formula? And why is simply [Attacking Stat]*[Speed Percentile] not sufficient?
  15. Bughouse

    Bughouse Like ships in the night, you're passing me by
    is a Site Staff Alumnusis a Forum Moderator Alumnusis a CAP Contributor Alumnusis a Tiering Contributor Alumnusis a Contributor Alumnus

    Joined:
    May 28, 2010
    Messages:
    4,988
    The simple answer is that it's 415 because it's 415. It really could be other things. Over the history of BSR, it has not always been 415. You should be able to even find old articles on site where it was other values. Brief research turned up examples where it was 315 and 630.

    Now the longer answer...

    This is how I understand things, but DougJustDoug is probably best suited to address what X-Act did. Please correct me if I'm wrong.

    Let's look at an example: Consider a pokemon with 120 SpA and 120 Spe.

    This gives its a Special Sweepiness of 206.239 under the current formulation (Special Sweepiness is a metric that includes the RSS along the away, RSS itself isn't really a metric we ever talk about). But what if it used a different valuation of 315 instead of 415? Well, without making similar adjustments to later steps in the formula meant to normalize the data, the SS would jump to 228.365. What if we used 630? It would drop to 181.773. Do these necessarily mean anything? Not really. We could adjust our ending scale of what constitutes "Amazing" Special Sweepiness however we wanted in order to attain the same results. So why is one better than the others?

    Think about it very basically, if SSpA is 10 and SSpe is .9, you get an equation like (9+x)/(1+x). If x is 1, you get 5. If x is 3, you get 3. Basically, as x increases, your RSS goes down, all else equal, for all positive x. This is true across the board. But it's not true equally across the board. As x moves from 1 to 3, RSS goes down by 40%. But if we move x from 3 to 5, it goes from 3 to 2.33, aka 22%. So the higher x goes, you get a narrower distribution in RSS. Right if we take SSpA of 10 and SSpe of .9 again, but now x is 200... you get 209/201 = 1.04. If we instead used SSpA of 5 and SSpe of .6, we'd get 203/202 = 1.005. This is a difference of only 3% in outcome, despite the Pokemon being much slower and also less powerful.

    This is why if SSpA typically looked like 10 or 5, we would never use x of 200. It makes all Pokemon essentially look the same. X that is too high makes all Pokemon be perceived to be basically identical. We could adjust our eventual definitions of SS accordingly so the exact same Pokemon were called Excellent or Above Average etc, but perceptually, they would appear identical. It's good to have a sensible spread in data for easy understanding.

    And this is also why we use 415. It fits what SSpA typically looks like and produces results that are logical. It was obvious that using X that is too high is bad, but what about using X that is too low?

    Let's try another example: compare the 120/120 Pokemon to one that is 120 SpA / 110 Spe.

    In our current formula we get SS of 206.239 and 199.41. Basically, you get that they are comparable Pokemon. One is 3.3% more sweepy than the other.
    But if we had a much lower adjustment X of 100, (again leaving later stuff unchanged), these same two Pokemon would give 414.159 and 373.059. This is a difference of 9.9%.

    Which intuitively feels right? Is that Pokemon 10% better or only more marginally better? At this high of a speed tier, moving from 110 to 120 impacts the Pokemon's matchup against fewer and fewer Pokemon. You outspeed slower Pokemon, which is most every Pokemon, whether you compare to 110 or 120. The change only impacts matchups against Pokemon between 110 and 120, which is way less than 10% of matchups, so it feels right to say the Pokemon with 120 Spe is considerably less than 10% better of a special sweeper than the one with 110 speed.

    All this being said, 415 could change. But we don't change it. Instead, the only thing that CAP has tinkered with is the ending normalization process that happens converting RSS to SS. This is much easier to tinker with and so we just don't touch X-Act's magic 415.
  16. QxC4eva

    QxC4eva
    is a Pre-Contributor

    Joined:
    Feb 21, 2014
    Messages:
    228
    +415 is derived from [average attack stat] * [average turns per KO]. In gen 6 OU it's about 300 * 1.5 = 450. A stally meta like gen 2 is about 300 * 3 = 900.

    It's for weighting speed to attack, so the formula can adapt to different metagames. Like gen 6 is more offensive than gen 2, so speed is more important in gen 6. So a lower number will give speed a bigger influence on the final score.

    Gen 6 OU
    • 120 Atk / 110 Spe: 276*(276*0.931+450)/(276*(1-0.931)+450) = 416.0
    • 120 Atk / 120 Spe: 276*(276*0.964+450)/(276*(1-0.964)+450) = 429.7 (+3.3%)
    "Gen 2 OU"
    • 120 Atk / 110 Spe: 276*(276*0.931+900)/(276*(1-0.931)+900) = 347.4
    • 120 Atk / 120 Spe: 276*(276*0.964+900)/(276*(1-0.964)+900) = 353.7 (+1.8%)

    So why not just [Attacking Stat]*[Speed Percentile] - it's to do with the mathematical model being used. Gonna refer to my older post here :P
    http://www.smogon.com/forums/threads/mega-delta-worksheet.3570166/#post-6781385
    Show Hide
    Both RPS and RSS measure the average damage a pokemon can do before it gets hit. So there's only two things you can do to increase it:
    • Increase attack, so the damage output is higher
    • Increase speed, so it gets to claim damage on any extra enemies it outspeeds
    Attack is straightforward, but to model the speed part, X-Act had to came up with a idea called "half-turn ratio" (RHT). Half-turn is when ONE pokemon makes a move, instead of 'full turn' when BOTH sides make a move. Got it? Just a fancy word, nothing scary :S Anyway, the ratio is how many half-turns a pokemon can make per half-turn the average opponent makes:

    [​IMG]

    The higher your speed stat, the more likely you're gonna be faster in a random matchup. So we need to find the probability of being faster, which is basically the Speed Percentile (also called "Statistical Speed" or SSpe):

    [​IMG]

    I put a ? because in pokemon, both sides get to move on each turn. So you can't be more than 1 half-turn ahead or behind no matter how big the speed difference is. E.g. a 0.8 SSpe mon doesn't move twice as often against one with 0.4 SSpe. Both will move just as often, just that the 0.8 SSpe one will lead off each time. So when does being faster actually earn you an extra half-turn? Well, it depends how fast or slow paced the metagame is. We can describe that by the average number of turns per KO (t) added to both probabilities. By doing that, the probability (SSpe) now represents the final half-turn where the faster mon gets an extra hit for being faster.

    [​IMG]

    RPS is the damage output (SAtk) weighted by half-turn ratio:

    [​IMG]

    For the sake of what I'm trying to do, let's "expand" the formula:

    [​IMG]

    X-Act did some analysis on averages and found SAtk * t = 415.

    [​IMG]

    ^ and there we go - his mystery formula! :D
    Hope that explains it.


    Note: The person above me said it mimics the speed tiers. That's not correct. The formula is using Speed Percentile (as opposed to the actual Speed stat) to handle that already.
  17. Bughouse

    Bughouse Like ships in the night, you're passing me by
    is a Site Staff Alumnusis a Forum Moderator Alumnusis a CAP Contributor Alumnusis a Tiering Contributor Alumnusis a Contributor Alumnus

    Joined:
    May 28, 2010
    Messages:
    4,988
    This doesn't change the fact that the numbers themselves are meaningless without the context of a scale, which we can (and do) normalize and assign however we want. There really is no particular reason that 415 HAS to be the number as opposed to any other number or no adjustment there at all. All it does is create a spread of data that is visually appealing.

    Tellingly, we've been using the same 415 since DPP, when X-Act developed the formula, and no one has ever complained about our BSR statistics being bad at any point along the way... despite the fact that DPP, BW, BW2, XY, ORAS, and now CAP have all been very different metagames.
  18. QxC4eva

    QxC4eva
    is a Pre-Contributor

    Joined:
    Feb 21, 2014
    Messages:
    228
    XD No!

    415 has nothing to do with normalizing. The numbers are meaningless but their order is important. Changing 415 will change the numbers and the order. Normalizing will change the numbers only (the order stays the same), basically it's RPS / σ' + μ' with σ' and μ' set to whatever that makes things "visually appealing", 415 has nothing to do with it.

    [​IMG]

    http://www.smogon.com/forums/threads/restoring-x-acts-apps.3490377/#post-4951286
    Have a read sweeptank_stats_ratings.pdf p11-17 if you're interested :P
  19. Bughouse

    Bughouse Like ships in the night, you're passing me by
    is a Site Staff Alumnusis a Forum Moderator Alumnusis a CAP Contributor Alumnusis a Tiering Contributor Alumnusis a Contributor Alumnus

    Joined:
    May 28, 2010
    Messages:
    4,988
    I'm well aware of the MS paint sections you feel you need to highlight for me. You say you agree that the numbers themselves are meaningless and the point is the order. Which is correct. But I'm confused how you could understand that and continue insisting that 415 matters.

    Please show me how the order of anything changes when S = 415 or S = 315 as he originally used in this article.

    Adding a constant to both the numerator and denominator of a fraction should not affect the order of anything unless I'm forgetting basic rules of math.

    1/6 > 1/7 > 1/8 > 1/9 is true and so is 6/11 > 6/12 > 6/13 > 6/14
  20. Hesh Kadesh

    Hesh Kadesh

    Joined:
    Aug 2, 2016
    Messages:
    29
    Excuse me if I'm wrong, but isn't that number chosen so that there is a more pleasant spread of numbers to look at? The purpose of 415 means nothing, except that rather than trying to squeeze the BSR's into a smaller collection of numbers, or a larger one, 415 gives a pleasant spread to look at? Unless I've misunderstood what the discussion is over?
  21. QxC4eva

    QxC4eva
    is a Pre-Contributor

    Joined:
    Feb 21, 2014
    Messages:
    228
    Bughouse the basic rule is right, but you forgot there's a extra SSAtk (or SSpA) multiplied to that fraction!

    7*1/6 > 8*1/7 > 9*1/8 > 10*1/9 is true

    7*6/11 > 8*6/12 > 9*6/13 > 10*6/14 not true.

    Donphan: 120 Atk / 50 Spe
    Linoone: 70 Atk / 100 Spe

    Might be easier to see this on a graph (I used this site)

    [​IMG]
    ^ when x=415, Donphan is sweepier than Linoone. For x=315 it's the other way round =]


    ---
    For anyone else confused, here's a summary.

    Sweepiness = [SSpA * (SSpA * SSpe + 415) / (SSpA * ( 1 - SSpe) + 415) ] / σ' - μ'

    where:
    • SSpA = SpA*2+36 (standardized attack)
    • SSpe is the speed percentile, conversion of Spe from the spreadsheet's lookup table.
    • 415 is [average SpA]*[turns per KO]. Determines how much influence SSpe should have (relative to SSpA) on the final score. Affects the results order!!
    • σ' is the derivative of sweepiness standard deviation, the actual variable we use to adjust the spread -- not x or 415 as people seem to confuse with. For visual purpose only, doesn't affect the ordering.
    • μ' is the derivative of the mean sweepiness, used for offsetnig the zero point location. Visual purpose only no effect on ordering.
    IMO anyone claiming 415 has no functional purpose should tell us where they found it in X-Act's article~

    http://www.smogon.com/forums/threads/restoring-x-acts-apps.3490377/#post-4951286
    sweeptank_stats_ratings.pdf
  22. Bughouse

    Bughouse Like ships in the night, you're passing me by
    is a Site Staff Alumnusis a Forum Moderator Alumnusis a CAP Contributor Alumnusis a Tiering Contributor Alumnusis a Contributor Alumnus

    Joined:
    May 28, 2010
    Messages:
    4,988
    OK that seems fair. I did actually test a few pairs with one another and in no cases did I find any rank differences lol. But I guess when you get as big of a difference as Donphan and Linoone it does start changing things. For any reasonable S, ie not zero and not a billion, rank shifts are pretty minor.

    In any case, proving that 415 matters more or less means that the BSR calc is wrong because there's no way it's been a constant 415 across all the metagames CAP has used as the base for projects.

Users Viewing Thread (Users: 0, Guests: 0)