双因素随机区组方差分析程序

================精选公文范文,管理类,工作总结类,工作计划类文档,欢迎阅读下载==============

双因素随机区组方差分析程序

’’’***********************SS_df_AB_R 类************************** ‘‘‘双因素重复方差分析与自度分解程序 ‘‘‘a() As Integer,处理因子a,已索引化 ‘‘‘ b() As Integer,处理因子b,已索引化 ‘‘‘Var() As Double ,指标数值 ‘‘‘ByVal N As Intege,观察值组数 ‘‘‘ by Chen Tingmu ’’’***************************************************************** Public df As Integer, dft As Integer, dfa As Integer, dfb As Integer, dfab As Integer Public dfe As Integer, N As Integer, na As Integer, nb As Integer, nab As Integer Public SS As Double, SSt As Double, SSa As Double, SSb As Double, SSab As Double, SSe As Double Public c As Double, T As Double, SUM As Double, SUM2 As Double Public

--------------------精选公文范文,管理类,工作总结类,工作计划类文档,感谢阅读下载---------------------

~ 1 ~

================精选公文范文,管理类,工作总结类,工作计划类文档,欢迎阅读下载==============

MSa As Double, MSb As Double, MSab As Double, MSe As Double Sub ssanddf_AB_R(a() As Integer, B() As Integer, Var() As Double, ByVal N As Integer) Dim I As Integer Dim sumA() As Double, sumB() As Double, sumAB() As Double Dim sumR() As Double Dim nai() As Integer, nbi() As Integer, nabi() As Integer ‘‘‘为缺区估

计作准备 na = 1 nb = 1 For I = 1 To N If a(I) > na Then na = a(I) If B(I) > nb Then nb = B(I) Next nab = na * nb ReDim sumA(na) As Double, sumB(nb) As Double, sumAB(nab) As Double ’ReDim sumR(nr) As Double ReDim nai(na) As Integer, nbi(nb) As Integer, nabi(nab) As Integer ‘‘‘为缺区估

计作准备 SUM = 0 SUM2 = 0 For I = 1 To na sumA(I) = 0: nai(I) = 0 Next For I = 1 To nb sumB(I) = 0: nbi(I) = 0 Next

--------------------精选公文范文,管理类,工作总结类,工作计划类文档,感谢阅读下载---------------------

~ 2 ~

================精选公文范文,管理类,工作总结类,工作计划类文档,欢迎阅读下载==============

For I = 1 To nab sumAB(I) = 0: nabi(I) = 0 Next df = N - 1

dfa = na - 1 dfb = nb - 1 dfab = dfa * dfb dfe = df - dfa - dfb - dfab For I = 1 To N SUM = SUM + Var(I) SUM2 = SUM2 + Var(I) * Var(I) sumA(a(I)) = sumA(a(I)) + Var(I) sumB(B(I)) = sumB(B(I)) + Var(I) sumAB((a(I) - 1) * nb + B(I)) =[标签:内容]

--------------------精选公文范文,管理类,工作总结类,工作计划类文档,感谢阅读下载---------------------

~ 3 ~

联系客服:779662525#qq.com(#替换为@) 苏ICP备20003344号-4