简体   繁体   English

如何为 scipy.stats 测试设置显着性水平

[英]How to set significance level for scipy.stats test

I'm using scipy.stats.ttest_ind and scipy.stats.wilcoxon to perform t test and the Wilcoxon test, but I have no idea how can I set the significant level for them.我正在使用scipy.stats.ttest_indscipy.stats.wilcoxon执行 t 检验和 Wilcoxon 检验,但我不知道如何为它们设置显着水平。 In the official documents, nothing about it is mentioned and it seems like no arguments of these two methods are about it.在官方文档中没有提到它,这两种方法似乎没有 arguments 是关于它的。 Does anyone know how to set it?有谁知道如何设置它?

The official documents:官方文件:

https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.ttest_ind.html https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.ttest_ind.html https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.ttest_ind.html https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.ttest_ind.html

The tests also report the p-value to the user.测试还向用户报告 p 值。 This p-value can be used to test a hypothesis at the significance level of your choice.此 p 值可用于在您选择的显着性水平上检验假设。 We reject the null hypothesis if the p-value is less than the significance level.如果 p 值小于显着性水平,我们拒绝null 假设。 For example, with a p-value of 0.073 we reject at the significance level of 10% but do not reject at a significance level of 5%.例如,p 值为 0.073,我们在 10% 的显着性水平上拒绝,但在 5% 的显着性水平上不拒绝。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM