For Distribution Functions Commonly Used In Inferential .

2y ago
27 Views
3 Downloads
922.23 KB
21 Pages
Last View : 14d ago
Last Download : 3m ago
Upload by : Harley Spears
Transcription

For distribution functions commonly used in inferential statistics (confidenceintervals, tests) : Normal, Student, Chi-Squared, Fisher-Snedecor.Ricco RakotomalalaRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/1

Calculation of CDF and PPF in inferential statisticsCalculations of the quantiles and cumulative distribution functions values arerequired in inferential statistics, when constructing confidence intervals or for theimplementation of hypothesis tests, especially for the calculation of the p-value.Functions available in different tools allow us to obtain these values. We do notlonger need to use statistical tables.Via Excel statistical functions (new functions are available from Excel 2010)Via R’s statistical functions provided by the “stats” package (directly accessible)Via Python’s statistical functions provided by the “scipy” packageimport scipy.stats as statsRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/2

NORMAL DISTRIBUTIONRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/3

CDF of the standard normal distribution (μ 0 and σ 1).Probability of less than x 1.65 is equal to 0.9505285TRUE for the CDF. If FALSE, we have the value ofProbability density function𝑓 𝑥 1𝜎 2𝜋𝑒 the density function. Required.EXCELNORM.DIST(1.65, 0 , 1 , TRUE)1 𝑥 𝜇 22 𝜎(μ 0) and (σ 1). Required settings.NORM.S.DIST(1.65,TRUE)0.9505285For the standard normal distribution.Rpnorm(1.65, mean 0, sd 1, lower.tail TRUE)(μ 0) and (σ 1). Default.TRUE: probabilities are ] ; 𝑞 ].Default.Pythonstats.norm.cdf(1.65, loc 0, scale 1)x 1.65(μ 0) and (σ 1). Default.Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/4

Calculation of the p-value for the standard normal distribution in a righttailed test. The probability of more than z 2.1 is equal to 0.01786442EXCELp-value 0.017864421- NORM.S.DIST(2.1, TRUE)R1 - pnorm(2.1)pnorm(2.1, lower.tail FALSE)Probabilities are [𝑧 ; [z 2.1Python1 - stats.norm.cdf(2.1)stats.norm.sf(2.1)sf 1 - cdfRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/5

Calculation of the p-value for the standard normal distribution in a twotailed test. The probability of more than z 2.1 in absolute value is equalto 0.03572884p-value 2 * 0.01786442 0.03572884EXCEL2*(1- NORM.S.DIST(2.1, TRUE))R2 * pnorm(2.1, lower.tail FALSE)- z z Python2 * (1 - stats.norm.cdf(2.1))Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/6

PPF (q) of the standard normal distribution forthe probability (1 – α) 0.95EXCELNORM.INV(0.95, 0, 1)NORM.S.INV(0.95)α 0.051-αRqnorm(0.95,mean 0,sd 1,lower.tail TRUE)qnorm(0.05,mean 0,sd 1,lower.tail FALSE)q 1.644854Pythonstats.norm.ppf(0.95, loc 0, scale 1)Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/7

Generating random numbers from standard normal distributionN(μ 0,σ 1)RAND() returns an evenly distributed random realnumber greater than or equal to 0 and less than 1.EXCELNORM.S.INV(RAND())Rrnorm(n 1,mean 0,sd 1)Number of values to return. If (n 1), we obtain a vector of values.Required.Initialization of the generator. If random state integer, the valuesPythonobtained are reproductible. Optional.stats.norm.rvs(loc 0,scale 1, size 1, random state none)Number of values to return. If (size 1), we obtain a vector ofvalues. Optional.Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/8

Approximations of the standard normal cumulative distributionfunction. Some “basic” formulas for (x 0)Φ1 𝑥 1 𝑥² 𝑒 20.4361836 0.1201676 1 0.33267𝑥2𝜋 1 0.33267𝑥 20.97729801 0.33267𝑥3(https://fr.wikipedia.org/wiki/Loi normale)Φ2 𝑥 0.5 111 230𝑥2 27𝑒 16𝑒 𝑥22 212 7 𝜋𝑥2 𝑒 utionFunction.html)Φ1 1.65 0.9494966Φ2 1.65 0.9505364Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/(Excel, R and Python 0.9505285)9

STUDENT’S T-DISTRIBUTIONRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/10

CDF of Student’s t-distribution with k (k 0) degrees of freedom.Probability of less than t 1.5 with k 10.TRUE, cumulative distribution function. If FALSE, returnsProbability density function𝑓𝑘 𝑡 1 Γ𝑘𝜋𝑘 12𝑘Γ21 𝑡²𝑘 𝑘 12EXCELthe probability density function. RequiredT.DIST(1.5,10,TRUE)1 - T.DIST.RT(1.5,10)We can use also the probabilityof more than t 1.5R0.9177463pt(1.5,df 10,lower.tail TRUE)1 - pt(1.5,df 10,lower.tail FALSE)Pythonstats.t.cdf(1.5,df 10)t 1.5Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/11

PPF (q) of the Student’s t-distribution with k 10 degreesof freedom for the probability (1 – α) 0.95EXCELT.INV(0.95,10)R1-α 0.95qt(0.95,df 10,lower.tail TRUE)qt(0.05,df 10,lower.tail FALSE)q 1.812461Pythonstats.t.ppf(0.95,df 10)Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/12

CDF and PPF for two-tailed Student’s t-distribution.EXCEL provides two specific functions.p-value 2 * 0.08225366 0.16450733ABS() “absolute value” function. Essential if the teststatistic takes a negative value.T.DIST.2T(ABS(1.5),10)- 1.5 𝛼 0.052 1.5 𝛼 0.052T.INV.2T(0.1,10)𝛼 0.1q 1.812461Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/13

CHI-SQUARED DISTRIBUTIONRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/14

CDF of the CHI-SQUARED distribution with k (k 0) degrees of freedom.Probability of less than t 12.0 with k 5.TRUE, cumulative distribution function. If FALSE, returnsProbability density function of χ²𝑓𝑘 𝑡 1𝑘22Γ𝑘𝑘2𝑡𝑡 2 1 𝑒 2the probability density function. RequiredEXCELCHISQ.DIST(12.0,5,TRUE)1 – CHISQ.DIST.RT(12.0,5)We can use also the probabilityof more than t 12.00.9652122Rpchisq(12.0,df 5)1 - pchisq(12.0,df 5,lower.tail FALSE)Pythonstats.chi2.cdf(12.0,df 5)t 12.0Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/15

PPF (q) of the chi-squared distribution with k 7 degrees offreedom for the probability (1 – α) 0.95EXCELCHISQ.INV (0.95,7)CHISQ.INV.RT (0.05,7)R1-α 0.95q 14.06714qchsiq(0.95,df 7)qchisq(0.05,df 7,lower.tail FALSE)Pythonstats.chi2.ppf(0.95, df 7)Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/16

FISHER-SNEDECOR DISTRIBUTIONRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/17

CDF of F-distribution with d1 (d1 0) and d2 (d2 0) degrees of freedom.Probability of less than x 3.5 with (d1 4, d2 26).Probability density functionTRUE, cumulative distribution function. If FALSE, returnsthe probability density function. Required𝑓 𝑥 𝑑12𝑑1 𝑥𝑑1 𝑥 𝑑2𝑥B1 𝑑1 𝑥𝑑1 𝑥 𝑑2𝑑22𝑑1 𝑑2,2 2EXCELF.DIST(3.5,4,26,TRUE)1 - F.DIST.RT(3.5,4,26)We can use also the probabilityof more than x 3.5B() is the beta function0.97948051Rpf(3.5,df1 4,df2 26)1 - pf(3.5,df1 4,df2 26,lower.tail FALSE)Pythonstats.f.cdf(3.5,dfn 4,dfd 26)x 3.5Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/18

PPF (q) of the F-Distribution with (d1 4, d2 26) degreesof freedom for the probability (1 – α) 95,df1 4,df2 26)1-α 0.95q 2.742594Ricco RakotomalalaTutoriels Tanagra - f1 4,df2 26,lower.tail FALSE)Pythonstats.f.ppf(0.95,dfn 4,dfd 26)19

Ricco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/20

ReferencesScipy.org – Statistical functions rence/stats.htmlMicrosoft – Excel Statistical -BC25-76D659719FFDR Tutorial – Basic Probability obability.htmlRicco RakotomalalaTutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/21

Ricco Rakotomalala Tutoriels Tanagra - http://tutoriels-data-mining.blogspot.fr/ 1 For distribution func

Related Documents:

Bruksanvisning för bilstereo . Bruksanvisning for bilstereo . Instrukcja obsługi samochodowego odtwarzacza stereo . Operating Instructions for Car Stereo . 610-104 . SV . Bruksanvisning i original

10 tips och tricks för att lyckas med ert sap-projekt 20 SAPSANYTT 2/2015 De flesta projektledare känner säkert till Cobb’s paradox. Martin Cobb verkade som CIO för sekretariatet för Treasury Board of Canada 1995 då han ställde frågan

service i Norge och Finland drivs inom ramen för ett enskilt företag (NRK. 1 och Yleisradio), fin ns det i Sverige tre: Ett för tv (Sveriges Television , SVT ), ett för radio (Sveriges Radio , SR ) och ett för utbildnings program (Sveriges Utbildningsradio, UR, vilket till följd av sin begränsade storlek inte återfinns bland de 25 största

Hotell För hotell anges de tre klasserna A/B, C och D. Det betyder att den "normala" standarden C är acceptabel men att motiven för en högre standard är starka. Ljudklass C motsvarar de tidigare normkraven för hotell, ljudklass A/B motsvarar kraven för moderna hotell med hög standard och ljudklass D kan användas vid

LÄS NOGGRANT FÖLJANDE VILLKOR FÖR APPLE DEVELOPER PROGRAM LICENCE . Apple Developer Program License Agreement Syfte Du vill använda Apple-mjukvara (enligt definitionen nedan) för att utveckla en eller flera Applikationer (enligt definitionen nedan) för Apple-märkta produkter. . Applikationer som utvecklas för iOS-produkter, Apple .

och krav. Maskinerna skriver ut upp till fyra tum breda etiketter med direkt termoteknik och termotransferteknik och är lämpliga för en lång rad användningsområden på vertikala marknader. TD-seriens professionella etikettskrivare för . skrivbordet. Brothers nya avancerade 4-tums etikettskrivare för skrivbordet är effektiva och enkla att

Den kanadensiska språkvetaren Jim Cummins har visat i sin forskning från år 1979 att det kan ta 1 till 3 år för att lära sig ett vardagsspråk och mellan 5 till 7 år för att behärska ett akademiskt språk.4 Han införde två begrepp för att beskriva elevernas språkliga kompetens: BI

**Godkänd av MAN för upp till 120 000 km och Mercedes Benz, Volvo och Renault för upp till 100 000 km i enlighet med deras specifikationer. Faktiskt oljebyte beror på motortyp, körförhållanden, servicehistorik, OBD och bränslekvalitet. Se alltid tillverkarens instruktionsbok. Art.Nr. 159CAC Art.Nr. 159CAA Art.Nr. 159CAB Art.Nr. 217B1B