|
@@ -1,31 +1,35 @@
|
|
# github_score
|
|
# github_score
|
|
|
|
|
|
-github 得分公式:
|
|
|
|
-
|
|
|
|
|
|
+GitHub Score Formula:
|
|
$$
|
|
$$
|
|
-rank=1 - \frac{1}{W} \sum_{i=1}^{n} w_i \cdot f_i \left( \frac{x_i}{m_i} \right)
|
|
|
|
|
|
+rank = 1 - \frac{1}{W} \sum_{i=1}^{n} w_i \cdot f_i \left( \frac{x_i}{m_i} \right)
|
|
$$
|
|
$$
|
|
-其中:
|
|
|
|
-
|
|
|
|
-- WWW 是总权重
|
|
|
|
-- wiw_iwi 是第 iii 个参数的权重
|
|
|
|
-- fif_ifi 是第 iii 个参数的得分函数(`exponential_cdf` 或 `log_normal_cdf`)
|
|
|
|
-- xix_ixi 是第 iii 个参数的实际值
|
|
|
|
-- mim_imi 是第 iii 个参数的中位数
|
|
|
|
|
|
+Where:
|
|
|
|
+- \(W\) is the total weight
|
|
|
|
+- \(w_i\) is the weight of the \(i\)-th parameter
|
|
|
|
+- \(f_i\) is the score function for the \(i\)-th parameter (`exponential_cdf` or `log_normal_cdf`)
|
|
|
|
+- \(x_i\) is the actual value of the \(i\)-th parameter
|
|
|
|
+- \(m_i\) is the median of the \(i\)-th parameter
|
|
|
|
|
|
-通过这个公式计算出总得分(`rank`),然后根据 `rank` 值确定用户的等级。
|
|
|
|
|
|
+Calculate the total score (`rank`) using this formula, and then determine the user's level based on the `rank` value.
|
|
|
|
|
|
-其中:
|
|
|
|
-(`COMMITS_WEIGHT`、`PRS_WEIGHT`、`ISSUES_WEIGHT`、`REVIEWS_WEIGHT`、`STARS_WEIGHT`、`FOLLOWERS_WEIGHT`),这些权重分别是:2、3、1、1、4、1。
|
|
|
|
|
|
+Weights for parameters:
|
|
|
|
+- (`COMMITS_WEIGHT`, `PRS_WEIGHT`, `ISSUES_WEIGHT`, `REVIEWS_WEIGHT`, `STARS_WEIGHT`, `FOLLOWERS_WEIGHT`) are 2, 3, 1, 1, 4, 1 respectively.
|
|
|
|
|
|
|
|
|
|
https://github-readme-stats.vercel.app/api?username=jianboy&hide_title=true&hide_border=true&show_icons=true&include_all_commits=true&count_private=true&line_height=21&text_color=000&icon_color=000&bg_color=0,ea6161,ffc64d,fffc4d,52fa5a&theme=graywhite
|
|
https://github-readme-stats.vercel.app/api?username=jianboy&hide_title=true&hide_border=true&show_icons=true&include_all_commits=true&count_private=true&line_height=21&text_color=000&icon_color=000&bg_color=0,ea6161,ffc64d,fffc4d,52fa5a&theme=graywhite
|
|
|
|
|
|
|
|
+## Usage
|
|
|
|
+
|
|
|
|
+modify index.js to yourself, then run:
|
|
|
|
+```
|
|
|
|
+node index.js
|
|
|
|
+```
|
|
|
|
|
|
## License
|
|
## License
|
|
|
|
|
|
## Reference
|
|
## Reference
|
|
|
|
|
|
|
|
+- [anuraghazra/github-readme-stats](https://github.com/anuraghazra/github-readme-stats/blob/master/src/calculateRank.js) rank.js
|
|
|
|
|
|
-https://github.com/anuraghazra/github-readme-stats/blob/master/src/calculateRank.js
|
|
|
|
|
|
|