from scipy.stats import t

def StudentTCI(loc, scale, df, alpha=0.95):
    return t.interval(alpha, df, loc, scale)
print(StudentTCI(1, 2, 10))
print(StudentTCI(1, 2, 10, 0.99))
student t confidence interval in python