SlideShare a Scribd company logo
1 2 3 4
101520
trat
resp
Dilan Vergara. Actividad 21-11-2014
BANANAS
> #tratamiento empaques
> pok<-c(14.1,9.4,9.3,10.9,6.3);pok
[1] 14.1 9.4 9.3 10.9 6.3
> pol<-c(10.0,7.1,14.2,14.8,18.9);pol
[1] 10.0 7.1 14.2 14.8 18.9
> saco<-c(18.3,17.5,14.4,16.2,23.1);saco
[1] 18.3 17.5 14.4 16.2 23.1
> nada<-c(21,18,17.3,16.8,21.9)nada
nada<-c(21,18,17.3,16.8,21.9)nada
> spaq<-c(21.0,18.0,17.3,16.8,21.9);spaq
[1] 21.0 18.0 17.3 16.8 21.9
> resp<-c(pok,pol,saco,spaq)
> mean(resp)
[1] 14.975
> var(resp)
[1] 23.48092
> sd(resp)
[1] 4.845712
> boxplot(resp)
> trat<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4);trat
[1] 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 4 4 4 4 4
> datos<-data.frame(trat,resp);datos
trat resp
1 1 14.1
2 1 9.4
3 1 9.3
4 1 10.9
5 1 6.3
6 2 10.0
7 2 7.1
8 2 14.2
9 2 14.8
10 2 18.9
11 3 18.3
12 3 17.5
13 3 14.4
14 3 16.2
15 3 23.1
16 4 21.0
17 4 18.0
18 4 17.3
19 4 16.8
20 4 21.9
> tapply(resp,trat,summary)
$`1`
Min. 1st Qu. Median Mean 3rd Qu. Max.
6.3 9.3 9.4 10.0 10.9 14.1
$`2`
Min. 1st Qu. Median Mean 3rd Qu. Max.
7.1 10.0 14.2 13.0 14.8 18.9
$`3`
Min. 1st Qu. Median Mean 3rd Qu. Max.
14.4 16.2 17.5 17.9 18.3 23.1
$`4`
Min. 1st Qu. Median Mean 3rd Qu. Max.
16.8 17.3 18.0 19.0 21.0 21.9
> tapply(resp,trat,var)
1 2 3 4
8.040 20.825 10.625 5.285
> tapply(resp,trat,mean)
1 2 3 4
10.0 13.0 17.9 19.0
> t.test(pok,mu=15)
One Sample t-test
data: pok
t = -3.943, df = 4, p-value = 0.01692
alternative hypothesis: true mean is not equal to 15
95 percent confidence interval:
6.479275 13.520725
sample estimates:
mean of x
10
> t.test(pol,mu=15)
One Sample t-test
data: pol
t = -0.98, df = 4, p-value = 0.3826
alternative hypothesis: true mean is not equal to 15
95 percent confidence interval:
7.333739 18.666261
sample estimates:
mean of x
13
> t.test(saco,mu=15)
One Sample t-test
data: saco
t = 1.9894, df = 4, p-value = 0.1175
alternative hypothesis: true mean is not equal to 15
95 percent confidence interval:
13.85267 21.94733
sample estimates:
mean of x
17.9
> t.test(spaq,mu=15)
One Sample t-test
data: spaq
t = 3.8907, df = 4, p-value = 0.01768
alternative hypothesis: true mean is not equal to 15
95 percent confidence interval:
16.14552 21.85448
sample estimates:
mean of x
19
> #analisis de varianza
> trat<-factor(trat)
> mod<-aov(resp~trat,data=datos);mod
Call:
aov(formula = resp ~ trat, data = datos)
Terms:
trat Residuals
Sum of Squares 254.4025 191.7350
Deg. of Freedom 1 18
Residual standard error: 3.263732
Estimated effects may be unbalanced
> anova(mod)
Analysis of Variance Table
Response: resp
Df Sum Sq Mean Sq F value Pr(>F)
trat 1 254.40 254.403 23.883 0.0001186 ***
Residuals 18 191.74 10.652
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
> #boxplot de los tratamientos
> plot(resp~trat)
>
>
> #Kruskal Wallis
> comparacion<-kruskal(resp,trat,group=TRUE, main="Empaques")
Study: Empaques
Kruskal-Wallis test's
Ties or no Ties
Value: 11.48
degrees of freedom: 3
Pvalue chisq : 0.00939431
trat, means of the ranks
resp replication
1 4.2 5
2 8.4 5
3 14.0 5
4 15.4 5
t-Student: 2.119905
Alpha : 0.05
LSD : 5.437877
Means with the same letter are not significantly different
Groups, Treatments and mean of the ranks
a 4 15.4
a 3 14
b 2 8.4
b 1 4.2

More Related Content

Viewers also liked

Pinterest: Un babillard 2.0?
Pinterest: Un babillard 2.0?Pinterest: Un babillard 2.0?
Pinterest: Un babillard 2.0?Adrianne Langlois
 
Droit des cartels et de la concurrence déloyale
Droit des cartels et de la concurrence déloyaleDroit des cartels et de la concurrence déloyale
Droit des cartels et de la concurrence déloyale
fredericborel
 
Projet Fin d'année version finale
Projet Fin d'année version finaleProjet Fin d'année version finale
Projet Fin d'année version finaleHoussem AZZOUZ
 
Ba lanza
Ba lanzaBa lanza
Ba lanza
wil are flores
 
Eye Makeup That Matches Well With Your Eye Shape
Eye Makeup That Matches Well With Your Eye ShapeEye Makeup That Matches Well With Your Eye Shape
Eye Makeup That Matches Well With Your Eye Shape
Eyelash Enhancer
 

Viewers also liked (6)

Pinterest: Un babillard 2.0?
Pinterest: Un babillard 2.0?Pinterest: Un babillard 2.0?
Pinterest: Un babillard 2.0?
 
Droit des cartels et de la concurrence déloyale
Droit des cartels et de la concurrence déloyaleDroit des cartels et de la concurrence déloyale
Droit des cartels et de la concurrence déloyale
 
Projet Fin d'année version finale
Projet Fin d'année version finaleProjet Fin d'année version finale
Projet Fin d'année version finale
 
N°37
N°37N°37
N°37
 
Ba lanza
Ba lanzaBa lanza
Ba lanza
 
Eye Makeup That Matches Well With Your Eye Shape
Eye Makeup That Matches Well With Your Eye ShapeEye Makeup That Matches Well With Your Eye Shape
Eye Makeup That Matches Well With Your Eye Shape
 

Similar to Dilan

r studio presentation.pptx
r studio presentation.pptxr studio presentation.pptx
r studio presentation.pptx
DevikaRaj14
 
r studio presentation.pptx
r studio presentation.pptxr studio presentation.pptx
r studio presentation.pptx
DevikaRaj14
 
Ejercicio 8
Ejercicio 8Ejercicio 8
Ejercicio 8
hermesortiz1508
 
Arna Friend Controls II Final
Arna Friend Controls II FinalArna Friend Controls II Final
Arna Friend Controls II Final
Arna Friend
 
HCCMS 2nd 9 weeks review 2015
HCCMS 2nd 9 weeks review 2015HCCMS 2nd 9 weeks review 2015
HCCMS 2nd 9 weeks review 2015
martinmommy2
 
Slides ensae 11bis
Slides ensae 11bisSlides ensae 11bis
Slides ensae 11bis
Arthur Charpentier
 
Slides ensae-2016-11
Slides ensae-2016-11Slides ensae-2016-11
Slides ensae-2016-11
Arthur Charpentier
 
ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-
ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-
ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-
ssusere0a682
 
Modeling in regression
Modeling in regressionModeling in regression
Modeling in regression
Madurai
 
Chapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptxChapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptx
MdSazolAhmmed
 
Control charts
Control chartsControl charts
Control charts
Waqaruddin Siddiqui, MBA
 
logisticregression
logisticregressionlogisticregression
logisticregression
SahilShahPhD2020
 
logisticregression.ppt
logisticregression.pptlogisticregression.ppt
logisticregression.ppt
ShrutiPanda12
 
Logisticregression
LogisticregressionLogisticregression
Logisticregression
sujimaa
 
Logisticregression
LogisticregressionLogisticregression
Logisticregression
rnunoo
 
Design of experiment methodology
Design of experiment methodologyDesign of experiment methodology
Design of experiment methodology
CHUN-HAO KUNG
 
Property Based Testing with ScalaCheck
Property Based Testing with ScalaCheckProperty Based Testing with ScalaCheck
Property Based Testing with ScalaCheck
David Galichet
 
When RV Meets CEP (RV 2016 Tutorial)
When RV Meets CEP (RV 2016 Tutorial)When RV Meets CEP (RV 2016 Tutorial)
When RV Meets CEP (RV 2016 Tutorial)
Sylvain Hallé
 
第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」
第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」
第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」
Ken'ichi Matsui
 
Normal probability distribution
Normal probability distributionNormal probability distribution
Normal probability distribution
Nadeem Uddin
 

Similar to Dilan (20)

r studio presentation.pptx
r studio presentation.pptxr studio presentation.pptx
r studio presentation.pptx
 
r studio presentation.pptx
r studio presentation.pptxr studio presentation.pptx
r studio presentation.pptx
 
Ejercicio 8
Ejercicio 8Ejercicio 8
Ejercicio 8
 
Arna Friend Controls II Final
Arna Friend Controls II FinalArna Friend Controls II Final
Arna Friend Controls II Final
 
HCCMS 2nd 9 weeks review 2015
HCCMS 2nd 9 weeks review 2015HCCMS 2nd 9 weeks review 2015
HCCMS 2nd 9 weeks review 2015
 
Slides ensae 11bis
Slides ensae 11bisSlides ensae 11bis
Slides ensae 11bis
 
Slides ensae-2016-11
Slides ensae-2016-11Slides ensae-2016-11
Slides ensae-2016-11
 
ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-
ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-
ゲーム理論 BASIC 演習89 -安全保障理事会決議における投票力指数-
 
Modeling in regression
Modeling in regressionModeling in regression
Modeling in regression
 
Chapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptxChapter 12 Dynamic programming.pptx
Chapter 12 Dynamic programming.pptx
 
Control charts
Control chartsControl charts
Control charts
 
logisticregression
logisticregressionlogisticregression
logisticregression
 
logisticregression.ppt
logisticregression.pptlogisticregression.ppt
logisticregression.ppt
 
Logisticregression
LogisticregressionLogisticregression
Logisticregression
 
Logisticregression
LogisticregressionLogisticregression
Logisticregression
 
Design of experiment methodology
Design of experiment methodologyDesign of experiment methodology
Design of experiment methodology
 
Property Based Testing with ScalaCheck
Property Based Testing with ScalaCheckProperty Based Testing with ScalaCheck
Property Based Testing with ScalaCheck
 
When RV Meets CEP (RV 2016 Tutorial)
When RV Meets CEP (RV 2016 Tutorial)When RV Meets CEP (RV 2016 Tutorial)
When RV Meets CEP (RV 2016 Tutorial)
 
第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」
第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」
第13回数学カフェ「素数!!」二次会 LT資料「乱数!!」
 
Normal probability distribution
Normal probability distributionNormal probability distribution
Normal probability distribution
 

Dilan

  • 1. 1 2 3 4 101520 trat resp Dilan Vergara. Actividad 21-11-2014 BANANAS > #tratamiento empaques > pok<-c(14.1,9.4,9.3,10.9,6.3);pok [1] 14.1 9.4 9.3 10.9 6.3 > pol<-c(10.0,7.1,14.2,14.8,18.9);pol [1] 10.0 7.1 14.2 14.8 18.9 > saco<-c(18.3,17.5,14.4,16.2,23.1);saco [1] 18.3 17.5 14.4 16.2 23.1 > nada<-c(21,18,17.3,16.8,21.9)nada nada<-c(21,18,17.3,16.8,21.9)nada > spaq<-c(21.0,18.0,17.3,16.8,21.9);spaq [1] 21.0 18.0 17.3 16.8 21.9 > resp<-c(pok,pol,saco,spaq) > mean(resp) [1] 14.975 > var(resp) [1] 23.48092 > sd(resp) [1] 4.845712 > boxplot(resp) > trat<-c(1,1,1,1,1,2,2,2,2,2,3,3,3,3,3,4,4,4,4,4);trat [1] 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 4 4 4 4 4 > datos<-data.frame(trat,resp);datos trat resp
  • 2. 1 1 14.1 2 1 9.4 3 1 9.3 4 1 10.9 5 1 6.3 6 2 10.0 7 2 7.1 8 2 14.2 9 2 14.8 10 2 18.9 11 3 18.3 12 3 17.5 13 3 14.4 14 3 16.2 15 3 23.1 16 4 21.0 17 4 18.0 18 4 17.3 19 4 16.8 20 4 21.9 > tapply(resp,trat,summary) $`1` Min. 1st Qu. Median Mean 3rd Qu. Max. 6.3 9.3 9.4 10.0 10.9 14.1 $`2` Min. 1st Qu. Median Mean 3rd Qu. Max.
  • 3. 7.1 10.0 14.2 13.0 14.8 18.9 $`3` Min. 1st Qu. Median Mean 3rd Qu. Max. 14.4 16.2 17.5 17.9 18.3 23.1 $`4` Min. 1st Qu. Median Mean 3rd Qu. Max. 16.8 17.3 18.0 19.0 21.0 21.9 > tapply(resp,trat,var) 1 2 3 4 8.040 20.825 10.625 5.285 > tapply(resp,trat,mean) 1 2 3 4 10.0 13.0 17.9 19.0 > t.test(pok,mu=15) One Sample t-test data: pok t = -3.943, df = 4, p-value = 0.01692 alternative hypothesis: true mean is not equal to 15 95 percent confidence interval: 6.479275 13.520725 sample estimates: mean of x
  • 4. 10 > t.test(pol,mu=15) One Sample t-test data: pol t = -0.98, df = 4, p-value = 0.3826 alternative hypothesis: true mean is not equal to 15 95 percent confidence interval: 7.333739 18.666261 sample estimates: mean of x 13 > t.test(saco,mu=15) One Sample t-test data: saco t = 1.9894, df = 4, p-value = 0.1175 alternative hypothesis: true mean is not equal to 15 95 percent confidence interval: 13.85267 21.94733 sample estimates: mean of x 17.9
  • 5. > t.test(spaq,mu=15) One Sample t-test data: spaq t = 3.8907, df = 4, p-value = 0.01768 alternative hypothesis: true mean is not equal to 15 95 percent confidence interval: 16.14552 21.85448 sample estimates: mean of x 19 > #analisis de varianza > trat<-factor(trat) > mod<-aov(resp~trat,data=datos);mod Call: aov(formula = resp ~ trat, data = datos) Terms: trat Residuals Sum of Squares 254.4025 191.7350 Deg. of Freedom 1 18 Residual standard error: 3.263732 Estimated effects may be unbalanced
  • 6. > anova(mod) Analysis of Variance Table Response: resp Df Sum Sq Mean Sq F value Pr(>F) trat 1 254.40 254.403 23.883 0.0001186 *** Residuals 18 191.74 10.652 --- Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 > #boxplot de los tratamientos > plot(resp~trat) > > > #Kruskal Wallis > comparacion<-kruskal(resp,trat,group=TRUE, main="Empaques") Study: Empaques Kruskal-Wallis test's Ties or no Ties Value: 11.48 degrees of freedom: 3 Pvalue chisq : 0.00939431 trat, means of the ranks resp replication
  • 7. 1 4.2 5 2 8.4 5 3 14.0 5 4 15.4 5 t-Student: 2.119905 Alpha : 0.05 LSD : 5.437877 Means with the same letter are not significantly different Groups, Treatments and mean of the ranks a 4 15.4 a 3 14 b 2 8.4 b 1 4.2