Skip to content

Instantly share code, notes, and snippets.

@ultimatile
Last active October 12, 2018 15:42
Show Gist options
  • Save ultimatile/68917dcc1a70de9f7cf7aa15ea5a0f9f to your computer and use it in GitHub Desktop.
Save ultimatile/68917dcc1a70de9f7cf7aa15ea5a0f9f to your computer and use it in GitHub Desktop.
Tスコアを実行時の変数として与えると自分の順位が大体わかるpythonスクリプトです. 小数点は切り捨てです. 自分の審査区分の申請者数をtotalに入れてお使いください. 例: python tscore2rank.py 3.0
from scipy.stats import norm
import sys
import numpy as np
total=584#DC1 数物系科学
#total=342#DC1 化学
rv = norm(loc=3,scale=0.6)
print("Your rank is {}/{}.".format(np.int(np.trunc(rv.sf(float(sys.argv[1]))*total)),total))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment