applicazioni - analisi della varianza ad un fattorestatic.gest.unipd.it/~livio/pdf/applicazioni -...
TRANSCRIPT
1
1/59
APPLICAZIONI
Analisi della varianza ad un fattore
Douglas C. Montgomery
Controllo statistico della qualità 2/ed© 2006 McGraw-Hill
Insegnamento: Metodi ed Applicazioni StatisticheCorso di Laurea Specialistica in Ingegneria GestionaleFacoltà di Ingegneria, Università di PadovaDocenti: Prof. L. Salmaso, Dott. L. Corain
2/59
SOMMARIO
Analisi della varianza ad un fattore: modello ed assunzioni
Applicazioni dell’Analisi della varianza ad un fattore e confronti multipli (Esempio 1-4)
Applicazioni dell’Analisi della varianza ad un fattore con variabile di blocco (Esempio 5-6)
Applicazioni dell’Analisi della varianza ad un fattore con covariate (Esempio 7-8)
2
3/59
ANALISI DELLA VARIANZA AD UN FATTORESupponiamo di avere c diversi livelli per un fattore e di considerare n repliche sperimentare per ciascun livello.La risposta osservata per ciascuno dei livelli del fattore èinterpretata come una variabile casuale.Per l’osservazione ij-esima della risposta Y, in corrispondenza del i-esimo livello del fattore e della j-esima replica si considera il seguente modello
Yij = µ + τi + εij i=1, …, c; j=1, …,n
µ = media generale della variabile rispostaτi = effetto sulla media dell’i-esimo livello del fattore εij = errore casualen = numero di osservazioni per ogni livello del fattoreSi suppone che gli errori del modello siano variabili casuali indipendenti e distribuite normalmente con media nulla e varianza σ 2: εij ~IIN(0; σ 2).
4/59
Questo modello è chiamato modello di analisi della varianza ad una via.Obiettivo verificare ipotesi riguardo gli effetti sulla media dei livelli del fattore
ESPERIMENTI CON UN FATTORE
Gli effetti dei fattori sono qui definiti come i parametri che rappresentano le deviazioni dalla media generale, per i quali deve valere il vincolo Στi = 0.Praticamente la media della risposta per l’i-esimo livello è
µi = µ + τi i=1, …, cL’analisi inferenziale di interesse nel modello di analisi della varianza ad una via corrisponde alla verifica d’ipotesi
H0: τ1 = τ2 = … = τc = 0H1: τi ≠ 0 per almeno un livello i
Il numero di osservazioni complessive è N = n · c.
3
5/59
L’analisi della varianza è una procedura inferenziale che sottopone a verifica l’ipotesi di uguaglianza delle medie dei trattamentiSe questa ipotesi viene rigettata esiste evidenza che vi sono delle differenze sistematiche tra le medie dei trattamenti ma non viene specificato quali specifiche medie siano differentiDeterminare quali specifiche medie differiscono, a seguito di un rifiuto del test ANOVA, è chiamato problema dei confronti multipliI metodi dei confronti multipli sono delle procedure inferenziali che sottopongono a verifica l’ipotesi di uguaglianza delle coppie di medie di trattamenti:
H0ij: µi = µj contro H1ij: µi ≠ µj, i,j = 1,…,c, i ≠ j
CONFRONTO TRA MEDIE DEI TRATTAMENTI
6/59
Vi sono molti metodi per condurre i confronti multipli e tra questi i più utilizzati sono
i t-test a coppie per le medie (spesso chiamato metodo Fisher’s LSD, Least Significant Difference)
metodo di Tukey
che fa uso della distribuzione della statistica del “range studentizzato”
CONFRONTO TRA MEDIE DEI TRATTAMENTI
0 2i j
ij N cE
Y YT t
MS n −
−= i i ∼
max min ( , )E
Y YQ q c fMS n
−= ∼
4
7/59
ESEMPIO 1
Una ditta che produce elettrodomestici ha condotto un esperimento su alcuni prototipi di lavatrice, misurando il loro livello di rumorosità durante alcune prove di lavaggio.OBIETTIVO: individuare il prototipo a cui è associata una minore rumorositàVARIABILE RISPOSTA: rumorositàFATTORE: prototipo di lavatrice (A, B e C)BLOCCO: NOCOVARIATE: NO
8/59
ESEMPIO 1
MODELLO STATISTICO:Yij = µ + τi + εij i=A,B,C; j=1,…,6
STATISTICA DESCRITTIVA:
CBA
35
30
25
20
Prototipo
Rum
oros
ità
Dotplots of Rumorosità by Prototip
CBA
35
30
25
20
Prototipo
Rum
oros
ità
Boxplots of Rumorosità by Prototip
Descriptive Statistics: Rumorosità by Prototipo Variable Prototip N Mean Median TrMean StDev Rumorosi A 6 30.92 29.85 30.92 3.60 B 6 24.57 23.95 24.57 3.75 C 6 24.27 22.80 24.27 3.75 Variable Prototip SE Mean Minimum Maximum Q1 Q3 Rumorosi A 1.47 27.70 36.90 28.00 34.05 B 1.53 19.40 29.60 21.65 28.48 C 1.53 20.90 30.80 21.50 27.65
5
9/59
ESEMPIO 1
TABELLA ANOVA:Factor Type Levels Values Prototip fixed 3 A B C Analysis of Variance for Rumorosi, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Prototip 2 169.27 169.27 84.64 6.18 0.011 Error 15 205.33 205.33 13.69 Total 17 374.61
CBA
31
30
29
28
27
26
25
24
Prototipo
Rum
oros
ità
Main Effects Plot - LS Means for Rumorosità
10/59
ESEMPIO 1
CONFRONTI MULTIPLI (verifica di ipotesi):
Bonferroni Simultaneous Tests Response Variable Rumorosi All Pairwise Comparisons among Levels of Prototip Prototip = A subtracted from: Level Difference SE of Adjusted Prototip of Means Difference T-Value P-Value B -6.350 2.136 -2.973 0.0285 C -6.650 2.136 -3.113 0.0214 Prototip = B subtracted from: Level Difference SE of Adjusted Prototip of Means Difference T-Value P-Value C -0.3000 2.136 -0.1404 1.000
6
11/59
ESEMPIO 1
CONFRONTI MULTIPLI (intervalli di confidenza):
Bonferroni 95.0% Simultaneous Confidence Intervals Response Variable Rumorosi All Pairwise Comparisons among Levels of Prototip Prototip = A subtracted from: Prototip Lower Center Upper -----+---------+---------+--------+- B -12.10 -6.350 -0.5959 (----------*-----------) C -12.40 -6.650 -0.8959 (-----------*----------) -----+---------+---------+--------+- -10.0 -5.0 0.0 5.0 Prototip = B subtracted from: Prototip Lower Center Upper -----+---------+---------+--------+- C -6.054 -0.3000 5.454 (----------*----------- -----+---------+---------+--------+- -10.0 -5.0 0.0 5.0
12/59
ESEMPIO 1
ANALISI DEI RESIDUI:
6420-2-4-6
6
5
4
3
2
1
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is Rumorosi)
50-5
2
1
0
-1
-2
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is Rumorosi)
3130292827262524
5
0
-5
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is Rumorosi)
18161412108642
5
0
-5
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is Rumorosi)
7
13/59
ESEMPIO 2
Un’azienda produce angolari di metallo mediante piegatura a freddo di lamiere. Si vuole valutare l’effetto della velocità della pressa che può funzionare su 5 livelli di velocità di piegatura.OBIETTIVO: studiare l’effetto della velocità di piegatura su angolari di metalli VARIABILE RISPOSTA: resistenza (in MPa)FATTORE: velocità di piegatura (A, B, C, D, E) BLOCCO: NOCOVARIATE: NO
14/59
EDCBA
640
630
620
610
600
590
580
570
Velocità
Res
iste
nza
Dotplots of Resistenza by Velocità
EDCBA
640
630
620
610
600
590
580
570
Velocità
Res
iste
nza
Boxplots of Resistenza by Velocità
ESEMPIO 2
MODELLO STATISTICO:Yij = µ + τi + εij i=A,B,C,D,E; j=1,…,20
STATISTICA DESCRITTIVA:Descriptive Statistics: Resistenza by Velocità Variable Velocità N Mean Median TrMean StDev Resisten A 20 604.05 602.50 603.39 11.26 B 20 598.15 596.00 597.50 17.59 C 20 604.45 605.50 605.06 15.47 D 20 606.25 612.50 607.17 14.58 E 20 621.05 621.00 621.06 9.68 Variable Velocità SE Mean Minimum Maximum Q1 Q3 Resisten A 2.52 589.00 631.00 595.75 611.50 B 3.93 574.00 634.00 581.75 611.25 C 3.46 571.00 627.00 594.25 616.75 D 3.26 573.00 623.00 592.75 617.00 E 2.16 602.00 640.00 615.75 628.25
8
15/59
ESEMPIO 2
VERIFICA DI IPOTESI SULLE VARIANZE:
302010
95% Confidence Intervals for Sigmas
P-Value : 0.146
Test Statistic: 1.750
Levene's Test
P-Value : 0.082
Test Statistic: 8.290
Bartlett's Test
Factor Levels
E
D
C
B
A
Test for Equal Variances for Resistenza
Test for Equal Variances Response Resistenza Factors Velocità ConfLvl 95.0000 Bonferroni confidence intervals for standard deviations Lower Sigma Upper N Factor Levels 7.8984 11.2553 18.7534 20 A 12.3457 17.5927 29.3126 20 B 10.8535 15.4663 25.7698 20 C 10.2300 14.5778 24.2893 20 D 6.7941 9.6816 16.1314 20 E Bartlett's Test (normal distribution) Test Statistic: 8.290 P-Value : 0.082 Levene's Test (any continuous distribution) Test Statistic: 1.750 P-Value : 0.146
16/59
ESEMPIO 2
TABELLA ANOVA:Factor Type Levels Values Velocità fixed 5 A B C D E Analysis of Variance for Resisten, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Velocità 4 5825.4 5825.4 1456.4 7.42 0.000 Error 95 18651.1 18651.1 196.3 Total 99 24476.6
EDCBA
620
610
600
Velocità
Res
iste
nza
Main Effects Plot - LS Means for Resistenza
9
17/59
ESEMPIO 2
CONFRONTI MULTIPLI (verifica di ipotesi):Tukey Simultaneous Tests Response Variable Resisten All Pairwise Comparisons among Levels of Velocità Velocità = A subtracted from: Level Difference SE of Adjusted Velocità of Means Difference T-Value P-Value B -5.900 4.431 -1.332 0.6723 C 0.400 4.431 0.090 1.0000 D 2.200 4.431 0.497 0.9875 E 17.000 4.431 3.837 0.0021 Velocità = B subtracted from: Level Difference SE of Adjusted Velocità of Means Difference T-Value P-Value C 6.300 4.431 1.422 0.6153 D 8.100 4.431 1.828 0.3637 E 22.900 4.431 5.168 0.0000 Velocità = C subtracted from: Level Difference SE of Adjusted Velocità of Means Difference T-Value P-Value D 1.800 4.431 0.4062 0.9942 E 16.600 4.431 3.7464 0.0028 Velocità = D subtracted from: Level Difference SE of Adjusted Velocità of Means Difference T-Value P-Value E 14.80 4.431 3.340 0.0103
18/59
ESEMPIO 2
CONFRONTI MULTIPLI (intervalli di confidenza):Tukey 95.0% Simultaneous Confidence Intervals Response Variable Resisten All Pairwise Comparisons among Levels of Velocità Velocità = A subtracted from: Velocità Lower Center Upper ---+--------+---------+---------+--- B -18.21 -5.900 6.413 (-------*-------) C -11.91 0.400 12.713 (-------*-------) D -10.11 2.200 14.513 (-------*--------) E 4.69 17.000 29.313 (-------*--------) ---+---------+---------+--------+--- -15 0 15 30 Velocità = B subtracted from: Velocità Lower Center Upper ---+---------+---------+--------+--- C -6.013 6.300 18.61 (-------*-------) D -4.213 8.100 20.41 (-------*--------) E 10.587 22.900 35.21 (-------*-------) ---+---------+---------+--------+--- -15 0 15 30 Velocità = C subtracted from: Velocità Lower Center Upper ---+---------+--------+---------+--- D -10.51 1.800 14.11 (-------*-------) E 4.29 16.600 28.91 (-------*-------) ---+--------+---------+---------+--- -15 0 15 30 Velocità = D subtracted from: Velocità Lower Center Upper ---+---------+---------+--------+--- E 2.487 14.80 27.11 (-------*-------) ---+---------+---------+---------+-- -15 0 15 30
10
19/59
403020100-10-20-30-40
20
10
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is Resisten)
403020100-10-20-30-40
3
2
1
0
-1
-2
-3
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is Resisten)
620610600
40
30
20
10
0
-10
-20
-30
-40
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is Resisten)
100908070605040302010
40
30
20
10
0
-10
-20
-30
-40
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is Resisten)
ESEMPIO 2
ANALISI DEI RESIDUI:
20/59
ESEMPIO 3
Si vuole valutare l’influenza del tipo di polvere metallica per individuare la lega preferibile per un tipo di ingranaggio (corone coniche).OBIETTIVO: studiare l’effetto del tipo di polvere sulle proprietà superficiali dei pezzi meccaniciVARIABILE RISPOSTA: microdurezza (HV0,1)FATTORE: tipo di polvere metallica (A, B, C, D) BLOCCO: NOCOVARIATE: NO
11
21/59
DCBA
900
800
700
600
500
400
300
Lega
Mic
rodu
rezz
a
Dotplots of Microdurezza by Lega
DCBA
900
800
700
600
500
400
300
Lega
Mic
rodu
rezz
a
Boxplots of Microdurezza by Lega
ESEMPIO 3
MODELLO STATISTICO:Yij = µ + τi + εij i=A,B,C,D; j=1,…,7
STATISTICA DESCRITTIVA:Descriptive Statistics: Microdurezza by Lega Variable Lega N Mean Median TrMean StDev Microdur A 7 672.4 677.0 672.4 51.9 B 7 839.0 833.0 839.0 33.1 C 7 708.3 712.0 708.3 40.9 D 7 345.7 350.0 345.7 28.8 Variable Lega SE Mean Minimum Maximum Q1 Q3 Microdur A 19.6 610.0 741.0 621.0 720.0 B 12.5 798.0 880.0 798.0 870.0 C 15.5 633.0 757.0 684.0 741.0 D 10.9 306.0 381.0 320.0 378.0
22/59
150100500
95% Confidence Intervals for Sigmas
P-Value : 0.330
Test Statistic: 1.204
Levene's Test
P-Value : 0.522
Test Statistic: 2.249
Bartlett's Test
Factor Levels
D
C
B
A
Test for Equal Variances for Microdurezza
ESEMPIO 3
VERIFICA DI IPOTESI SULLE VARIANZE:Test for Equal Variances Response Microdurezza Factors Lega ConfLvl 95.0000 Bonferroni confidence intervals for standard deviations Lower Sigma Upper N Factor Levels 29.9538 51.8712 148.401 7 A 19.0942 33.0656 94.599 7 B 23.6213 40.9052 117.028 7 C 16.6457 28.8254 82.468 7 D Bartlett's Test (normal distribution) Test Statistic: 2.249 P-Value : 0.522 Levene's Test (any continuous distribution) Test Statistic: 1.204 P-Value : 0.330
12
23/59
Factor Type Levels Values Lega fixed 4 A B C D Analysis of Variance for Microdur, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Lega 3 923386 923386 307795 195.80 0.000 Error 24 37729 37729 1572 Total 27 961114
ESEMPIO 3
TABELLA ANOVA:
DCBA
850
750
650
550
450
350
Lega
Mic
rodu
rezz
a
Main Effects Plot - LS Means for Microdurezza
24/59
Bonferroni Simultaneous Tests Response Variable Microdur All Pairwise Comparisons among Levels of Lega Lega = A subtracted from: Level Difference SE of Adjusted Lega of Means Difference T-Value P-Value B 166.6 21.19 7.86 0.0000 C 35.9 21.19 1.69 0.6216 D -326.7 21.19 -15.42 0.0000 Lega = B subtracted from: Level Difference SE of Adjusted Lega of Means Difference T-Value P-Value C -130.7 21.19 -6.17 0.0000 D -493.3 21.19 -23.28 0.0000 Lega = C subtracted from: Level Difference SE of Adjusted Lega of Means Difference T-Value P-Value D -362.6 21.19 -17.11 0.0000
ESEMPIO 3
CONFRONTI MULTIPLI (verifica di ipotesi):
13
25/59
Bonferroni 95.0% Simultaneous Confidence Intervals Response Variable Microdur All Pairwise Comparisons among Levels of Lega Lega = A subtracted from: Lega Lower Center Upper ---+---------+---------+---------+--- B 105.6 166.6 227.5 (--*-) C -25.1 35.9 96.8 (-*--) D -387.6 -326.7 -265.8 (--*-) ---+---------+---------+---------+--- -500 -250 0 250 Lega = B subtracted from: Lega Lower Center Upper ---+---------+---------+---------+--- C -191.6 -130.7 -69.8 (--*-) D -554.2 -493.3 -432.4 (-*--) ---+---------+---------+---------+--- -500 -250 0 250 Lega = C subtracted from: Lega Lower Center Upper ---+---------+---------+---------+--- D -423.5 -362.6 -301.6 (-*--) ---+---------+---------+---------+--- -500 -250 0 250
ESEMPIO 3
CONFRONTI MULTIPLI (intervalli di confidenza):
26/59
6040200-20-40-60-80
8
7
6
5
4
3
2
1
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is Microdur)
500-50
2
1
0
-1
-2
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is Microdur)
850750650550450350
50
0
-50
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is Microdur)
252015105
50
0
-50
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is Microdur)
ESEMPIO 3
ANALISI DEI RESIDUI:
14
27/59
ESEMPIO 4
Una acciaieria vuole studiare la resistenza allo snervamento di un certo tipo di barre di acciaio in funzione del diametro delle barre stesse.OBIETTIVO: studiare l’effetto del diametro sulle proprietà meccaniche delle barreVARIABILE RISPOSTA: resistenza allo snervamento FATTORE: diametro della barra in mm (12, 14, 16) BLOCCO: NOCOVARIATE: NO
28/59
Descriptive Statistics: Snervamento by Diametro Variable Diametro N Mean Median TrMean StDev Snervame 10 20 512.25 511.00 512.00 10.74 12 20 513.30 512.00 513.06 9.29 14 20 521.05 520.00 521.28 10.47 Variable Diametro SE Mean Minimum Maximum Q1 Q3 Snervame 10 2.40 495.00 534.00 505.25 519.75 12 2.08 500.00 531.00 505.50 520.00 14 2.34 501.00 537.00 516.25 531.75
141210
540
530
520
510
500
490
Diametro
Sne
rvam
ento
Dotplots of Snervamento by Diametro
141210
540
530
520
510
500
490
Diametro
Sne
rvam
ento
Boxplots of Snervamento by Diametro
ESEMPIO 4
MODELLO STATISTICO:Yij = µ + τi + εij i=10,12,14; j=1,…,20
STATISTICA DESCRITTIVA:
15
29/59
141210
521
520
519
518
517
516
515
514
513
512
Diametro
Sne
rvam
ento
Main Effects Plot - LS Means for Snervamento
ESEMPIO 4
TABELLA ANOVA:Factor Type Levels Values Diametro fixed 3 10 12 14 Analysis of Variance for Snervame, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Diametro 2 924.0 924.0 462.0 4.45 0.016 Error 57 5912.9 5912.9 103.7 Total 59 6836.9
30/59
ESEMPIO 4
CONFRONTI MULTIPLI (verifica di ipotesi):
Bonferroni Simultaneous Tests Response Variable Snervame All Pairwise Comparisons among Levels of Diametro Diametro = 10 subtracted from: Level Difference SE of Adjusted Diametro of Means Difference T-Value P-Value 12 1.050 3.221 0.3260 1.0000 14 8.800 3.221 2.7322 0.0251 Diametro = 12 subtracted from: Level Difference SE of Adjusted Diametro of Means Difference T-Value P-Value 14 7.750 3.221 2.406 0.0581
16
31/59
ESEMPIO 4
CONFRONTI MULTIPLI (intervalli di confidenza):
Bonferroni 90.0% Simultaneous Confidence Intervals Response Variable Snervame All Pairwise Comparisons among Levels of Diametro Diametro = 10 subtracted from: Diametro Lower Center Upper ----------+---------+---------+----- 12 -5.974 1.050 8.074 (-----------*----------) 14 1.776 8.800 15.824 (-----------*---------- ----------+---------+---------+----- 0.0 6.0 12.0 Diametro = 12 subtracted from: Diametro Lower Center Upper ----------+---------+---------+----- 14 0.7258 7.750 14.77 (-----------*-----------) ----------+---------+---------+----- 0.0 6.0 12.0
32/59
ESEMPIO 4
ANALISI DEI RESIDUI:
20151050-5-10-15-20
10
5
0
Residual
Freq
uenc
y
Histogram of Residuals
6050403020100
30
20
10
0
-10
-20
-30
Observation Number
Res
idua
l
I Chart of Residuals
5
Mean=3.03E-14
UCL=26.23
LCL=-26.23
521520519518517516515514513512
20
10
0
-10
-20
Fit
Res
idua
l
Residuals vs. Fits
210-1-2
20
10
0
-10
-20
Normal Plot of Residuals
Normal Score
Res
idua
l
Residual Model Diagnostics
17
33/59
LA PRESENZA DI BLOCCO O DI COVARIATE
Il modello di analisi della varianza ad un fattore può essere facilmente adattato al caso della presenza
di una variabile di blocco:Yijk = µ + τi + βj + εijk i=1, …, c; j=1, …,b; k=1, …,ndi covariate:
Yij = µ + τi + xij′ β + εij i=1, …, c; j=1, …,n
L’analisi inferenziale di interesse corrisponde alle verifiche d’ipotesi
H0F: τ1 =…= τc = 0 contro H1F: τi ≠ 0 per almeno un livello i
H0B: β1=…= βb=0 contro H1B:βi ≠ 0 per almeno un livello jH0C: β = 0 contro H1C: β ≠ 0
34/59
ESEMPIO 5
Per studiare le prestazioni di resistenza dei travi di cemento in relazione alla durata della stagionatura si utilizzano due distinte metodologie per la conduzione della prova sperimentale, misurando su alcuni provini la forza massima di rottura.OBIETTIVO: studiare l’effetto della durata della stagionatura sulla resistenza dei travi di cementoVARIABILE RISPOSTA: forza massima di rotturaFATTORE: giorni di stagionatura (3, 7, 28)BLOCCO: tipo di metodo (A e B)COVARIATE: NO
18
35/59
Descriptive Statistics: Forza Max by Stagion Variable Stagion N Mean Median TrMean StDev Forza Ma 3 8 24956 24861 24956 1449 7 8 36627 36694 36627 2093 28 8 38812 38943 38812 1181 Variable Macchina N Mean Median TrMean StDev Forza Ma A 12 32099 34727 32460 6238 B 12 34831 38585 35264 6538
2873
40000
30000
20000
Stagion
Forz
a M
ax
Boxplots of Forza Max by Stagion
BA
40000
30000
20000
Macchina
Forz
a M
ax
Boxplots of Forza Max by Macchina
ESEMPIO 5
MODELLO STATISTICO:Yijk = µ + τi + βj + εijk i=3,7,28; j=A,B; k=1,…,4
STATISTICA DESCRITTIVA:
36/59
Factor Type Levels Values Stagion fixed 3 3 7 28 Macchina fixed 2 A B Analysis of Variance for Forza Ma, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Stagion 2 887893652 887893652 443946826 856.72 0.000 Macchina 1 44772836 44772836 44772836 86.40 0.000 Error 20 10363813 10363813 518191 Total 23 943030301
MacchinaStagion
BA28 7 3
37000
34000
31000
28000
25000
Forz
a M
ax
Main Effects Plot - LS Means for Forza Max
ESEMPIO 5
TABELLA ANOVA:
19
37/59
ESEMPIO 5
CONFRONTI MULTIPLI (verifica di ipotesi):Tukey Simultaneous Tests Response Variable Forza Ma All Pairwise Comparisons among Levels of Stagion Stagion = 3 subtracted from: Level Difference SE of Adjusted Stagion of Means Difference T-Value P-Value 7 11670 359.9 32.42 0.0000 28 13856 359.9 38.50 0.0000 Stagion = 7 subtracted from: Level Difference SE of Adjusted Stagion of Means Difference T-Value P-Value 28 2185 359.9 6.072 0.0000
38/59
ESEMPIO 5
CONFRONTI MULTIPLI (intervalli di confidenza):
Tukey 95.0% Simultaneous Confidence Intervals Response Variable Forza Ma All Pairwise Comparisons among Levels of Stagion Stagion = 3 subtracted from: Stagion Lower Center Upper -------+---------+---------+--------- 7 10759 11670 12582 (-*-) 28 12945 13856 14767 (--*-) -------+---------+---------+--------- 4000 8000 12000 Stagion = 7 subtracted from: Stagion Lower Center Upper -------+---------+---------+--------- 28 1274 2185 3097 (-*--) -------+---------+---------+--------- 4000 8000 12000
20
39/59
10000-1000
5
4
3
2
1
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is Forza Ma)
10000-1000
2
1
0
-1
-2
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is Forza Ma)
40000350003000025000
1000
0
-1000
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is Forza Ma)
2015105
1000
0
-1000
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is Forza Ma)
ESEMPIO 5
ANALISI DEI RESIDUI:
40/59
ESEMPIO 5
ANALISI DEI RESIDUI (test di normalità):
P-Value: 0.081A-Squared: 0.646
Anderson-Darling Normality Test
N: 24StDev: 671.268Average: 0.0000000
10000-1000
.999
.99
.95
.80
.50
.20
.05
.01
.001
Pro
babi
lity
RESI1
Normal Probability Plot
Approximate P-Value: 0.116D+: 0.096 D-: 0.159 D : 0.159
Kolmogorov-Smirnov Normality Test
N: 24StDev: 671.268Average: 0.0000000
10000-1000
.999
.99
.95
.80
.50
.20
.05
.01
.001
Pro
babi
lity
RESI1
Normal Probability Plot
21
41/59
ESEMPIO 6
Si vuole valutare la variabilità di comportamento nella deformazione di membrane elastomeriche di forma circolare, al fine di verificare l’affidabilità del processo produttivo delle stesse.OBIETTIVO: studiare l’effetto della durata della stagionatura sulla resistenza dei travi di cementoVARIABILE RISPOSTA: deflessione in mmFATTORE: livello di pressione in mbar (10, 20, 30, 40)BLOCCO: membrana (la prova viene ripetuta sulla stessa membrana, facendo variare il livello di pressione)COVARIATE: NO
42/59
ESEMPIO 6
DATASET:Campione Mbar=10 Mbar=20 Mbar=30 Mbar=40
1 2.3 3.6 4.7 62 2.6 4.6 5.8 7.43 2.7 4.4 6.2 7.84 2.7 4.7 5.6 6.85 2.1 3.6 4.8 66 1.9 3.1 4.6 5.67 2.2 4.4 6.8 88 1.9 3.7 4.9 6.19 2.1 3.6 4.7 5.410 2.3 3.9 5 6.411 2 3.4 4.5 5.612 2.7 4.4 5.8 6.813 2.1 3.5 4.7 5.914 2.4 4 5.4 6.715 2.4 4.1 5.5 6.716 2.3 3.6 5.1 617 2.3 3.8 5.4 6.718 2.9 3.4 4.7 5.919 2 3.3 4.5 5.720 2.1 3.5 4.5 5.7
22
43/59
2019181716151413121110987654321
8
7
6
5
4
3
2
Campione
Def
orm
Boxplots of Deform by Campione
40302010
8
7
6
5
4
3
2
Mbar
Def
orm
Boxplots of Deform by Mbar
ESEMPIO 6
MODELLO STATISTICO:Yij = µ + τi + βj + εij i=10,20,30,40; j=1,…,20
STATISTICA DESCRITTIVA:Descriptive Statistics: Deform by Mbar Variable Mbar N Mean Median TrMean StDev Deform 10 20 2.3000 2.3000 2.2889 0.2920 20 20 3.830 3.650 3.822 0.462 30 20 5.160 4.950 5.106 0.637 40 20 6.360 6.050 6.322 0.740 Variable Mbar SE Mean Minimum Maximum Q1 Q3 Deform 10 0.0653 1.9000 2.9000 2.1000 2.5500 20 0.103 3.100 4.700 3.500 4.325 30 0.142 4.500 6.800 4.700 5.575 40 0.165 5.400 8.000 5.750 6.775
44/59
ESEMPIO 6
TABELLA ANOVA:
DCBA
850
750
650
550
450
350
Lega
Mic
rodu
rezz
a
Main Effects Plot - LS Means for Microdurezza
CampioneMbar
2019181716151413121110 9 8 7 6 5 4 3 2 140302010
6.5
5.5
4.5
3.5
2.5
Def
orm
Main Effects Plot - LS Means for Deform
Factor Type Levels Values Mbar fixed 4 10 20 30 40 Campione fixed 20 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 Analysis of Variance for Deform, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Mbar 3 183.0695 183.0695 61.0232 632.36 0.000 Campione 19 18.2975 18.2975 0.9630 9.98 0.000 Error 57 5.5005 5.5005 0.0965 Total 79 206.8675
23
45/59
Bonferroni Simultaneous Tests Response Variable Deform All Pairwise Comparisons among Levels of Mbar Mbar = 10 subtracted from: Level Difference SE of Adjusted Mbar of Means Difference T-Value P-Value 20 1.530 0.09823 15.57 0.0000 30 2.860 0.09823 29.11 0.0000 40 4.060 0.09823 41.33 0.0000 Mbar = 20 subtracted from: Level Difference SE of Adjusted Mbar of Means Difference T-Value P-Value 30 1.330 0.09823 13.54 0.0000 40 2.530 0.09823 25.75 0.0000 Mbar = 30 subtracted from: Level Difference SE of Adjusted Mbar of Means Difference T-Value P-Value 40 1.200 0.09823 12.22 0.0000
ESEMPIO 6
CONFRONTI MULTIPLI (verifica di ipotesi):
46/59
Bonferroni 95.0% Simultaneous Confidence Intervals Response Variable Deform All Pairwise Comparisons among Levels of Mbar Mbar = 10 subtracted from: Mbar Lower Center Upper -+---------+---------+---------+----- 20 1.261 1.530 1.799 (-*--) 30 2.591 2.860 3.129 (--*-) 40 3.791 4.060 4.329 (--*-) -+---------+---------+---------+----- 1.0 2.0 3.0 4.0 Mbar = 20 subtracted from: Mbar Lower Center Upper -+---------+---------+---------+----- 30 1.061 1.330 1.599 (-*--) 40 2.261 2.530 2.799 (-*--) -+---------+---------+---------+----- 1.0 2.0 3.0 4.0 Mbar = 30 subtracted from: Mbar Lower Center Upper -+---------+---------+---------+----- 40 0.9315 1.200 1.469 (--*--) -+---------+---------+---------+----- 1.0 2.0 3.0 4.0
ESEMPIO 6
CONFRONTI MULTIPLI (intervalli di confidenza):
24
47/59
0.80.60.40.20.0-0.2-0.4-0.6-0.8-1.0
30
20
10
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is Deform)
10-1
2.5
2.0
1.5
1.0
0.5
0.0
-0.5
-1.0
-1.5
-2.0
-2.5
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is Deform)
7.56.55.54.53.52.51.5
1
0
-1
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is Deform)
8070605040302010
1
0
-1
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is Deform)
ESEMPIO 6
ANALISI DEI RESIDUI:
48/59
ESEMPIO 7
Nello studio di un impianto di laminazione di billettedi acciaio si vuole stabilire se la tipologia del rullo influenza la velocità di laminazione, tenendo conto dei parametri di laminazione dell’impiantoOBIETTIVO: studiare l’effetto della tipologia del rullo sulla velocità di laminazioneVARIABILE RISPOSTA: velocità di laminazione in m/sFATTORE: tipologia di rullo (H–orizzontale, V–verticale)BLOCCO: NOCOVARIATE: parametri di laminazione (carico applicato – CA, momento – M, potenza – P)
25
49/59
Descriptive Statistics: speed by type Variable type N Mean Median TrMean StDev speed H 9 4.29 2.16 4.29 4.75 V 9 5.06 2.78 5.06 5.35 Variable type SE Mean Minimum Maximum Q1 Q3 speed H 1.58 0.19 13.32 0.49 8.37 V 1.78 0.24 15.00 0.63 9.74
VH
15
10
5
0
type
spee
d
Dotplots of speed by type
VH
15
10
5
0
type
spee
d
Boxplots of speed by type
ESEMPIO 7
MODELLO STATISTICO:yij = µ + τi + β1CAij + β2Mij + β3Pij + εij i=H,V; j=1,…,9
STATISTICA DESCRITTIVA:
50/59
550450350250150
15
10
5
0
power
spee
d
3002001000
15
10
5
0
torque
spee
d
ESEMPIO 7
STATISTICA DESCRITTIVA(diagrammi di dispersione):
25002000150010005000
15
10
5
0
load
spee
d
26
51/59
VH
5.1
5.0
4.9
4.8
4.7
4.6
4.5
4.4
4.3
type
spee
d
Main Effects Plot - LS Means for speed
ESEMPIO 7
TABELLA ANOVA:Factor Type Levels Values type fixed 2 H V Analysis of Variance for speed, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P load 1 213.706 53.091 53.091 6.55 0.024 torque 1 47.746 43.755 43.755 5.40 0.037 power 1 43.660 23.062 23.062 2.85 0.115 type 1 1.446 1.446 1.446 0.18 0.680 Error 13 105.359 105.359 8.105 Total 17 411.917
52/59
ESEMPIO 7
STIMA E VERIFICA DI IPOTESI SULLE COVARIATE:
Term Coef SE Coef T P Constant 4.585 5.258 0.87 0.399 load -0.020158 0.007876 -2.56 0.024 torque 0.15051 0.06477 2.32 0.037 power 0.01747 0.01036 1.69 0.115
27
53/59
43210-1-2-3-4
4
3
2
1
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is speed)
543210-1-2-3-4
2
1
0
-1
-2
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is speed)
1050
5
4
3
2
1
0
-1
-2
-3
-4
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is speed)
18161412108642
5
4
3
2
1
0
-1
-2
-3
-4
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is speed)
ESEMPIO 7
ANALISI DEI RESIDUI:
54/59
ESEMPIO 8
In uno studio sui materiali di rivestimento stradale si vuole studiare la resistenza al derapaggio in relazione al tipo di rivestimento, tenendo conto della temperatura del rivestimento.OBIETTIVO: studiare l’effetto del tipo di rivestimento sulla resistenza al derapaggioVARIABILE RISPOSTA: resistenza al derapaggio (SRT) FATTORE: tipo di rivestimento (pavimentazione – P, segnaletica – S)BLOCCO: NOCOVARIATE: temperatura – T
28
55/59
Descriptive Statistics: SRT by Rivestimento Variable Rivestim N Mean Median TrMean StDev SRT P 15 48.600 50.000 48.538 2.530 S 15 46.267 46.000 46.231 0.884 Variable Rivestim SE Mean Minimum Maximum Q1 Q3 SRT P 0.653 45.000 53.000 46.000 50.000 S 0.228 45.000 48.000 46.000 47.000
SP
53
52
51
50
49
48
47
46
45
Rivestimento
SR
T
Boxplots of SRT by Rivestim
ESEMPIO 8
MODELLO STATISTICO:Yij = µ + τi + β Tij + εij i=P,S; j=1,…,15
STATISTICA DESCRITTIVA:
29.528.527.526.5
53
52
51
50
49
48
47
46
45
Temp
SR
T
56/59
4.53.52.51.50.5
95% Confidence Intervals for Sigmas
P
S
535251504948474645
Boxplots of Raw Data
SRT
P-Value : 0.035Test Statistic: 4.936
Levene's Test
P-Value : 0.000Test Statistic: 8.195
F-Test
Factor Levels
S
P
Test for Equal Variances for SRT
ESEMPIO 8
VERIFICA DI IPOTESI SULLE VARIANZE:Test for Equal Variances Response SRT Factors Rivestimento ConfLvl 95.0000 Bonferroni confidence intervals for standard deviations Lower Sigma Upper N Factor Levels 1.77553 2.52982 4.28791 15 P 0.62023 0.88372 1.49785 15 S F-Test (normal distribution) Test Statistic: 8.195 P-Value : 0.000 Levene's Test (any continuous distribution) Test Statistic: 4.936 P-Value : 0.035
29
57/59
SP
49.5
48.5
47.5
46.5
45.5
Rivestimento
SR
T
Main Effects Plot - LS Means for SRT
ESEMPIO 8
TABELLA ANOVA:Factor Type Levels Values Rivestim fixed 2 P S Analysis of Variance for SRT, using Adjusted SS for Tests Source DF Seq SS Adj SS Adj MS F P Temp 1 30.409 78.735 78.735 97.52 0.000 Rivestim 1 89.158 89.158 89.158 110.43 0.000 Error 27 21.799 21.799 0.807 Total 29 141.367 Term Coef SE Coef T P Constant 98.723 5.196 19.00 0.000 Temp -1.8776 0.1901 -9.88 0.000
58/59
ESEMPIO 8
CONFRONTI MULTIPLI:Tukey 95.0% Simultaneous Confidence Intervals Response Variable SRT All Pairwise Comparisons among Levels of Rivestim Rivestim = P subtracted from: Rivestim Lower Center Upper -+---------+---------+---------+---- S -4.509 -3.773 -3.036 (----*----) -+---------+---------+---------+---- -4.5 -3.0 -1.5 0.0 Tukey Simultaneous Tests Response Variable SRT All Pairwise Comparisons among Levels of Rivestim Rivestim = P subtracted from: Level Difference SE of Adjusted Rivestim of Means Difference T-Value P-Value S -3.773 0.3590 -10.51 0.0000
30
59/59
2.01.51.00.50.0-0.5-1.0-1.5
6
5
4
3
2
1
0
Residual
Freq
uenc
y
Histogram of the Residuals(response is SRT)
210-1
2
1
0
-1
-2
Nor
mal
Sco
re
Residual
Normal Probability Plot of the Residuals(response is SRT)
51504948474645
2
1
0
-1
Fitted Value
Res
idua
l
Residuals Versus the Fitted Values(response is SRT)
30252015105
2
1
0
-1
Observation Order
Res
idua
l
Residuals Versus the Order of the Data(response is SRT)
ESEMPIO 8
ANALISI DEI RESIDUI: