首页 > 其他分享 >数学建模习题9.2

数学建模习题9.2

时间:2024-12-13 09:33:48浏览次数:9  
标签:15.0 15.1 15.2 15.3 15.5 建模 print 习题 9.2

`import numpy as np
from scipy.stats import shapiro

data = [15.0, 15.8, 15.2, 15.1, 15.9, 14.7, 14.8, 15.5, 15.6, 15.3, 15.1, 15.3, 15.0, 15.6, 15.7, 14.8, 14.5, 14.2, 14.9, 14.9, 15.2, 15.0, 15.3, 15.6, 15.1, 14.9, 14.2, 14.6, 15.8, 15.2, 15.9, 15.2, 15.0, 14.9, 14.8, 14.5, 15.1, 15.5, 15.5, 15.1, 15.1, 15.0, 15.3, 14.7, 14.5, 15.5, 15.0, 14.7, 14.6, 14.2]

stat, p = shapiro(data)
print(f"Shapiro-Wilk Statistic: {stat}")
print(f"P-value: {p}")

alpha = 0.05
if p > alpha:
print("滚珠直径数据服从正态分布N(15.0780, 0.4325^2)。")
else:
print("滚珠直径数据不服从正态分布N(15.0780, 0.4325^2)。")

print("学号后两位为:05")`

标签:15.0,15.1,15.2,15.3,15.5,建模,print,习题,9.2
From: https://www.cnblogs.com/vvlin/p/18604170

相关文章