Il confronto fra proporzioni - Formazione e Sicurezza
Il confronto fra proporzioni - Formazione e Sicurezza
Il confronto fra proporzioni - Formazione e Sicurezza
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
L. Boni<br />
<strong>Il</strong> rapporto<br />
Un rapporto (ratio), attribuendo un<br />
ampio significato al termine, è il<br />
risultato della divisione di una certa<br />
quantità a per un’altra quantità b<br />
<strong>Il</strong> rapporto<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Spesso, in maniera più specifica, si<br />
parla di rapporto quando numeratore<br />
e denominatore rappresentano due<br />
quantità separate e distinte, nessuna<br />
delle due contenuta nell’altra<br />
Sex ratio=(N° di maschi)/(N° femmine)<br />
Fetal death ratio=(N° di morti fetali)/(N° di nati vivi)<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
1
La proporzione<br />
La proporzione è un particolare tipo<br />
di rapporto in cui il numeratore è<br />
compreso nel denominatore<br />
La proporzione<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
(N° di maschi) / [(N° di maschi) + (N° di femmine)]<br />
Una proporzione ha sempre<br />
numeratore e denominatore discreti<br />
ed un valore compreso <strong>fra</strong> 0 e 1<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Come analizzare le <strong>proporzioni</strong><br />
FIGURA 5.1 GLANTZ<br />
VARIABILE CASUALE BINARIA<br />
P destro = P(X=0) = 150/200 = 0.75<br />
P mancino = P(X=1) = 50/200 = 0.25<br />
P destro = 1 - P mancino<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
2
Media di una variabile binaria<br />
e generalizzando:<br />
cioè la proporzione della popolazione con<br />
la caratteristica studiata<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Deviazione standard di una variabile binaria<br />
NOTA: Possiamo descrivere completamente<br />
la struttura della popolazione con il singolo<br />
parametro P<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Relazione <strong>fra</strong> media e deviazione<br />
standard di una proporzione<br />
FIGURA 5.3 GLANTZ<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
3
Stima di <strong>proporzioni</strong><br />
ottenute da campioni<br />
Qual è la precisione con la quale la proporzione<br />
di individui con un certa caratteristica di un<br />
campione riflette la proporzione di individui con<br />
la stessa caratteristica nella popolazione ?<br />
FIGURA 5.4 GLANTZ<br />
Stima di <strong>proporzioni</strong><br />
ottenute da campioni<br />
FIGURA 5.5 GLANTZ<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Errore standard della stima di<br />
una proporzione<br />
FIGURA 5.6 GLANTZ<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
4
Distribuzione binomiale<br />
Distribuzione binomiale<br />
Distribuzione binomiale<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
5
Distribuzione binomiale<br />
dove<br />
Assunti<br />
Stiamo analizzando esperimenti di tipo<br />
bernoulliano, nei quali:<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Ogni singolo esperimento ha solo due<br />
possibili esiti mutuamente esclusivi<br />
La probabilità P di un certo esito rimane<br />
costante<br />
Tutti gli esperimenti sono indipendenti<br />
Assunti<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Utilizzando il concetto di popolazione,<br />
possiamo riformulare gli assunti nel modo<br />
seguente:<br />
Ogni unità della popolazione appartiene<br />
ad una sola delle due classi<br />
La proporzione P di unità della<br />
popolazione appartenenti ad una delle<br />
due classi rimane costante<br />
Ogni unità del campione è estratta<br />
indipendentemente da tutte le altre unità<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
6
Confronto <strong>fra</strong> una proporzione<br />
ed un valore atteso<br />
RICORDA: <strong>Il</strong> teorema del limite<br />
centrale afferma che la distribuzione di<br />
p per campioni abbastanza numerosi è<br />
approssimativamente normale con<br />
media P e deviazione standard p<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Confronto <strong>fra</strong> una proporzione<br />
ed un valore atteso<br />
Se estraiamo ripetutamente un<br />
campione di numerosità n da una<br />
popolazione con parametro P, il 68%<br />
dei campioni forniranno una stima di P<br />
compresa nell’intervallo P 1 E.S. ed<br />
il 95% nell’intervallo P 2 E.S.<br />
Un esempio<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
7
Un esempio<br />
Questa approssimazione non vale per<br />
valori di P vicini a 0 o a 1, o quando la<br />
numerosità campionaria n è piccola.<br />
Di regola è accettabile quando np e<br />
n(1-p) sono entambi maggiori di 5.<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Confronto <strong>fra</strong> una proporzione<br />
ed un valore atteso<br />
P = parametro della popolazione<br />
O/n = p = proporzione osservata<br />
Ipotesi nulla (H0):<br />
n è un campione casuale estratto da<br />
una popolazione con parametro P<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Confronto <strong>fra</strong> una proporzione<br />
ed un valore atteso<br />
Test z:<br />
misura in unità di D.S. (=E.S.) la<br />
distanza <strong>fra</strong> la P della popolazione e<br />
la p osservata<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
8
Confronto <strong>fra</strong> una proporzione<br />
ed un valore atteso<br />
Esempio: su 60 giocate alla roulette<br />
mi aspetto 30 rossi (50%) e ne osservo<br />
15<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Intervallo di confidenza di una<br />
proporzione<br />
Sappiamo che<br />
segue approssimativamente la distribuzione<br />
normale<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Intervallo di confidenza di una<br />
proporzione<br />
Ne deriva che<br />
Nel nostro esempio:<br />
0.25 - 1.96 x 0.064
Confronto <strong>fra</strong> due <strong>proporzioni</strong><br />
p 1 = O 1/n 1<br />
p 2 = O 2/n 2<br />
Ipotesi nulla (H0):<br />
n 1 e n 2 sono due campioni casuali<br />
estratti dalla stessa popolazione<br />
p 1 = p 2 = P e p 1 - p 2 = 0<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Confronto <strong>fra</strong> due <strong>proporzioni</strong><br />
La migliore stima disponibile di P è la media<br />
pesata tra p 1 e p 2, cioè:<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Confronto <strong>fra</strong> due <strong>proporzioni</strong><br />
Test z:<br />
misura in unità di D.S. della differenza<br />
(=E.S. d) la distanza tra la differenza<br />
osservata (p 1-p 2) e quella attesa in base<br />
all’ipotesi nulla (=0)<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
10
Un esempio<br />
p(Trombo|Placebo) = 18/25 = 0.72<br />
p(Trombo|Aspirina) = 6/19 = 0.32<br />
verifichiamo:<br />
25 x 0.72 = 18 e 25 x (1 - 0.72) = 7<br />
19 x 0.32 = 6 e 19 x (1 - 0.32) = 13<br />
Poiché tutti i valori sono più grandi di 5<br />
possiamo applicare il metodo sviluppato<br />
Un esempio<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
Intervallo di confidenza di una<br />
differenza <strong>fra</strong> <strong>proporzioni</strong><br />
Sappiamo che:<br />
segue approssimativamente la distribuzione<br />
normale, da cui ne deriva che:<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
11
Intervallo di confidenza di una<br />
differenza <strong>fra</strong> <strong>proporzioni</strong><br />
Nel nostro esempio:<br />
0.40 - 1.96 x 0.15
<strong>Il</strong> test statistico chi quadrato<br />
<strong>Il</strong> test statistico deve indicare la misura<br />
con cui le frequenze osservate in ogni<br />
cella della tabella differiscono dalle<br />
frequenze che ci aspetteremmo, se non<br />
ci fosse associazione <strong>fra</strong> i trattamenti e<br />
gli esiti<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> test statistico chi quadrato<br />
<strong>Il</strong> test statistico deve inoltre tenere conto del<br />
fatto che, nel caso in cui ci aspettiamo<br />
parecchie osservazioni in una cella, la<br />
differenza di una unità <strong>fra</strong> le frequenze attesa<br />
ed osservata è meno importante che nel caso<br />
in cui ci aspettiamo solo poche osservazioni<br />
Distribuzione chi quadrato<br />
Nel nostro esempio:<br />
FIGURA 5.7 GLANTZ<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
13
Distribuzione chi quadrato<br />
L’utilizzo della distribuzione 2 presuppone<br />
che, affinché la distribuzione teorica sia<br />
un’approssimazione sufficientemente buona<br />
di quella vera, il numero atteso di individui in<br />
ogni cella sia uguale o maggiore di 5<br />
E’ possibile dimostrare che 2 = z 2 quando ci<br />
sono solo due campioni e due esiti possibili<br />
<strong>Il</strong> <strong>confronto</strong> <strong>fra</strong> <strong>proporzioni</strong><br />
22/03/2011<br />
14