User Tools

Site Tools


anova

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revisionBoth sides next revision
anova [2018/10/18 08:34] – [논문 작성] hkimscilanova [2018/10/19 07:54] – [F and t value] hkimscil
Line 377: Line 377:
 ====== F and t value ====== ====== F and t value ======
 $$ F = t^{2}$$ $$ F = t^{2}$$
 +<code>> td <- read.csv("D:/Users/Hyo/Cs-Kant/CS/Rdata/t-test.csv")
 +> head(td)
 +  gender tmobconv out in. mobpeo
 +1      2       60          5
 +2      2       60          5
 +3      1       20    10      5
 +4      2       10          6
 +5      2       30          3
 +6      2       30          3
 +
 +</code>
 +<code>
 +> tmod <- t.test(tmobconv~gender, data=td, var.eq=T ,na.rm=T)
 +> tmod
 +
 + Two Sample t-test
 +
 +data:  tmobconv by gender
 +t = -3.0453, df = 1449, p-value = 0.002367
 +alternative hypothesis: true difference in means is not equal to 0
 +95 percent confidence interval:
 + -48.88717 -10.58088
 +sample estimates:
 +mean in group 1 mean in group 2 
 +       91.28457       121.01860 
 +
 +> tmod$statistic^2
 +       
 +9.273615 
 +</code>
 +
 +<code>
 +> fmod <- aov(tmobconv~gender, data=td)
 +> summary(fmod)
 +              Df   Sum Sq Mean Sq F value  Pr(>F)   
 +gender           320284  320284   9.274 0.00237 **
 +Residuals   1449 50044262   34537                   
 +---
 +Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
 +56 observations deleted due to missingness
 +
 +</code>
  
 ====== Example ====== ====== Example ======
anova.txt · Last modified: 2022/09/30 09:02 by hkimscil

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki