import numpy as np

# Paths to your median‐theta arrays
m1_path = "/drive2/Kuntal/Pysindy-experiment/conformal_boundary/messidor1-output/messidor1_median_theta.npy"
m2_path = "/drive2/Kuntal/Pysindy-experiment/conformal_boundary/messidor2-output/messidor2_median_theta.npy"

# Load
theta_m1 = np.load(m1_path).ravel()
theta_m2 = np.load(m2_path).ravel()

# Compute stats
for name, data in [("Messidor1", theta_m1), ("Messidor2", theta_m2)]:
    μ = data.mean()
    σ = data.std(ddof=1)
    ci_lo = μ - 1.96*σ
    ci_hi = μ + 1.96*σ
    print(f"{name}: mean={μ:.4f}, std={σ:.4f}, 95% CI = [{ci_lo:.4f}, {ci_hi:.4f}]")
