Title: Error with statistic calculation
Last modified: March 9, 2017

---

# Error with statistic calculation

 *  [albert211](https://wordpress.org/support/users/albert211/)
 * (@albert211)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/error-with-statistic-calculation/)
 * Hi all,
 * I am using sportpress for baseball, and the fields like average, SLG. PIP arent
   calculating although the formulas of the equations are set correctly.
 *  I have noticed that this is because when I use fields of the player’s performance,
   despite fill these variables in the player statistics, Sportpress takes them 
   as if its value was 0.
    -  This topic was modified 9 years, 3 months ago by [albert211](https://wordpress.org/support/users/albert211/).

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [Roch](https://wordpress.org/support/users/rochesterj/)
 * (@rochesterj)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/error-with-statistic-calculation/#post-8898932)
 * Hi!
 * Thanks for reaching out!
 * if the field data isn’t being read it’s posisble that the data entry is wrong.
   Please set all your events as drafts, publish just one of them, and there you’ll
   be able to check if the data entry is correct, and double check the formulas.
 * Also, you could send us screenshots of your wp-admin both for the event and the
   stats formulas.
 * Thanks!
    Kind Regards, -Roch
 *  Thread Starter [albert211](https://wordpress.org/support/users/albert211/)
 * (@albert211)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/error-with-statistic-calculation/#post-8903679)
 * ok, but still doesnt work
 * Screenchots:
 * All the variables in the configuration
 * [http://vvcap.com/9Bw6XhePQZx](http://vvcap.com/9Bw6XhePQZx)
 * Formula of statistic AVG
 * [http://vvcap.com/8qvzFRTiaNM](http://vvcap.com/8qvzFRTiaNM)
 * [http://vvcap.com/3IbyVQoVaop](http://vvcap.com/3IbyVQoVaop)
 * Example of the statistic not calculating
 * [http://vvcap.com/wXdrQUolURy](http://vvcap.com/wXdrQUolURy)
 * It is assumed that in the AVG formula I have established that H is divided between
   AB, but the result in AVG is still 0, despite having put 30 in H and 90 in AB,
   the result should be 0.333
 *  [Roch](https://wordpress.org/support/users/rochesterj/)
 * (@rochesterj)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/error-with-statistic-calculation/#post-8909442)
 * Hi!
 * That’s weird because you have AVG different in your first screenshot and in the
   second (and since the variable names are all letters it’s hard to make sense 
   of them).
 * Which one is the correct,
    H / AB or h-2 / ab
 * Please also double check which is the variable name. AB is different from ab 
   for example
 * Kind Regards,
    -Roch
 *  Thread Starter [albert211](https://wordpress.org/support/users/albert211/)
 * (@albert211)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/error-with-statistic-calculation/#post-8909753)
 * hi
 * Is the same, H is the name in the tag or title, and h-2 is the name in the variable.
 * [http://vvcap.com/qOK5hqWvuHP](http://vvcap.com/qOK5hqWvuHP)
 * I guess the “-2” was added when I deleted the variable and created it again to
   prove if the calculations worked. Same, I already tried without with “h” without“-
   2” and it does not work. I also installed sportpress on 2 computers more and 
   I do not work the automatic statistics, any ideas?

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Error with statistic calculation’ is closed to new replies.

 * ![](https://ps.w.org/sportspress/assets/icon-256x256.png?rev=1252005)
 * [SportsPress - Sports Club & League Manager](https://wordpress.org/plugins/sportspress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/sportspress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/sportspress/)
 * [Active Topics](https://wordpress.org/support/plugin/sportspress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/sportspress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/sportspress/reviews/)

## Tags

 * [baseball](https://wordpress.org/support/topic-tag/baseball/)
 * [equation](https://wordpress.org/support/topic-tag/equation/)
 * [sportpress](https://wordpress.org/support/topic-tag/sportpress/)

 * 4 replies
 * 2 participants
 * Last reply from: [albert211](https://wordpress.org/support/users/albert211/)
 * Last activity: [9 years, 2 months ago](https://wordpress.org/support/topic/error-with-statistic-calculation/#post-8909753)
 * Status: not resolved