SciPy - Curve Fitting and Regression
Find the bug in this code snippet:
import numpy as np from scipy.stats import t data = np.array([2, 4, 6, 8, 10]) mean = np.mean(data) std_err = np.std(data) / np.sqrt(len(data)) df = len(data) - 1 ci = t.interval(0.95, df, loc=mean, scale=std_err) print(ci)
