|
|
本帖最后由 Menuett 于 2013-12-22 15:59 编辑
' P1 R' K0 H/ m- x" E3 o" r4 W煮酒正熟 发表于 2013-12-20 12:05 / L& \& u' `6 a* p! w
基本可以说是显著的。总的来说,在商界做统计学分析,95%信心水平是用得最多的,当95%上不显著时,都会去 ... ! b* O) k% a$ D
" X( b/ @" i( a0 ]7 y0 x4 J这个其实是一种binomial response,应该用Contigency Table或者Logisitic Regression(In case there are cofactors)来做。只记比率丢弃了Number of trial的信息(6841和1217个客户)。 , r: w8 o1 j) ~& [+ d6 V
5 o' M; Y/ ~) J2 ^6 p* A& i结果p=0.5731。 远远不显著。要在alpha level 0.05的水平上检验出76.42%和75.62%的区别,即使实验组和对照组各自样本大小相同,各自尚需44735个样本(At power level 80%)。see: Statistical Methods for Rates and Proportions by Joseph L. Fleiss (1981)2 Q! ]) @, u+ i
$ }5 u. ^) R& d3 l! L. T# mR example:
/ K) d- t7 p8 P+ W$ d" O& h7 t) i. A1 g) y" ], c
> M<-as.table(rbind(c(1668,5173),c(287,930)))
5 X* N7 l: |2 I4 h, j. u1 R> chisq.test(M)4 P- Q% S6 g' E: x( l" B
: k! m9 F1 f* P; r
Pearson's Chi-squared test with Yates' continuity correction+ A6 t' q, H( u Z) @* f) j
0 E% X p$ J: D$ `# k9 bdata: M. T3 o4 O1 u' m" G0 ^3 ?9 g, p
X-squared = 0.3175, df = 1, p-value = 0.5731& H: y& `, j, n
9 S- n7 U1 V( O) s
Python example:. v2 v6 I; _, H' V2 X! F( m! j' c
. j1 |/ U" a: {$ y( W$ m>>> from scipy import stats
) L) N. e2 u2 f! w/ e>>> stats.chi2_contingency([[6841-5173,5173],[1217-930,930]])+ A8 J1 M+ I, h; E, V& L/ N
(0.31748297614660292, 0.57312422493552839, 1, array([[ 1659.73628692, 5181.26371308],$ i0 x, G, {5 ^- w y6 j4 A) j
[ 295.26371308, 921.73628692]])) |
|