Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_hypothesisvariance2.wasp
Title produced by softwareTesting Variance - p-value (probability)
Date of computationThu, 13 Nov 2008 09:12:50 -0700
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2008/Nov/13/t1226592825amwy01w71179gqf.htm/, Retrieved Sun, 19 May 2024 09:37:54 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=24668, Retrieved Sun, 19 May 2024 09:37:54 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact171
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
F       [Testing Variance - p-value (probability)] [question 1 pork] [2008-11-13 16:12:50] [f7fbcd402030df685d3fe4ce577d7846] [Current]
Feedback Forum
2008-11-16 14:05:52 [Julie Govaerts] [reply
We nemen als nulhypothese dat het varkensvlees 15% vet zal bevatten. We nemen hierbij een zelf gekozen alfa fout van 5%. De kans dat we ons zullen vergissen bij het verwerpen van de nulhypothese zal dus beperkt blijven tot 5%. Want we mogen de leverancier uiteraard niet ten onrechte beschuldigen.

We moeten nu gaan testen of ons bekomen gemiddelde van 15.46% op de 27 varkensvlees-samples nu al dan niet toeval is?

Gebruikte techniek: Testing Mean with known Variance - Critical Value

In dit geval is de critical value (0.184676559191704) groter dan de sample mean (0.1546 = het steekproefgemiddelde). Hieruit kunnen we afleiden dat er sprake is van een toevallige afwijking ten opzichte van het contractueel bepaalde vetgehalte (15%). We verwerpen de nulhypothese niet. (We verwerpen dus niet dat het varkensvlees 15% vet bevat). Indien de sample value groter zou zijn dan de critical value, dan kunnen we besluiten dat er minderwaardig vlees is geleverd.

we gebruiken de 2 sided test omdat dit een tweezijdig probleem is = het vlees kan teveel = slechte kwaliteit of te weinig vet bevatten = weinig smaak
het percentage aan vet moet dus tussen 2 grenzen liggen = in een interval

we gaan dus geen klacht indienen!

OF we gebruiken de one-sided test (one-tailed test) omdat de leverancier enkel daar een economisch voordeel kan halen. Hij zal misschien vlees leveren met te veel vet. Maar hij zal nooit te goed vlees leveren (met weinig vet). Het is dus minder waarschijnlijk dat de leverancier vlees met minder vet zal leveren, aangezien dat duurder is. De one-sided test meet de afwijking naar boven (dus bij te veel vet).
2008-11-17 13:59:49 [Hundra Smet] [reply
Je dient geen klacht in te dienen aangezien de nulhypothese niet mag verworpen worden (we gebruiken de two-sided test).-> we zien geen overschrijdende waarden
De nulhypothese stelt dat er niet teveel vet aanwezig is. We maken gebruik van de two-tailed test omdat het vlees slechts 15% vet mag bevatten. Wanneer het werkelijke percentage hier teveel van afwijkt (teveel vet of te weinig, dus beide staarten van de normaalverdeling) kunnen we een klacht indienen.
2008-11-17 14:00:38 [Hundra Smet] [reply
de student gebruikte hier een foute werkwijze. er werd 'Testing Variance - p-value (probability)' gebruikt, dit moet echter (Testing Mean with known Variance( zijn.
de conclusie bestaat uit slechts 1 zin en is fout
2008-11-21 18:40:34 [Gregory De Meulenaer] [reply
De student gebruikt ook een verkeerde sample size 320 ipv 27.

Post a new message




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 1 seconds \tabularnewline
R Server & 'Gwilym Jenkins' @ 72.249.127.135 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=24668&T=0

[TABLE]
[ROW][C]Summary of computational transaction[/C][/ROW]
[ROW][C]Raw Input[/C][C]view raw input (R code) [/C][/ROW]
[ROW][C]Raw Output[/C][C]view raw output of R engine [/C][/ROW]
[ROW][C]Computing time[/C][C]1 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Gwilym Jenkins' @ 72.249.127.135[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=24668&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=24668&T=0

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135







Testing Variance - p-value (probability)
Sample size320
Sample variance4.2
Null hypothesis (H0)4.8
Type I error (alpha)0.05
p-value (probability)0.0522928169394425
ConclusionThere is no reason to reject the null hypothesis

\begin{tabular}{lllllllll}
\hline
Testing Variance - p-value (probability) \tabularnewline
Sample size & 320 \tabularnewline
Sample variance & 4.2 \tabularnewline
Null hypothesis (H0) & 4.8 \tabularnewline
Type I error (alpha) & 0.05 \tabularnewline
p-value (probability) & 0.0522928169394425 \tabularnewline
Conclusion & There is no reason to reject the null hypothesis \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=24668&T=1

[TABLE]
[ROW][C]Testing Variance - p-value (probability)[/C][/ROW]
[ROW][C]Sample size[/C][C]320[/C][/ROW]
[ROW][C]Sample variance[/C][C]4.2[/C][/ROW]
[ROW][C]Null hypothesis (H0)[/C][C]4.8[/C][/ROW]
[ROW][C]Type I error (alpha)[/C][C]0.05[/C][/ROW]
[ROW][C]p-value (probability)[/C][C]0.0522928169394425[/C][/ROW]
[ROW][C]Conclusion[/C][C]There is no reason to reject the null hypothesis[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=24668&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=24668&T=1

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Testing Variance - p-value (probability)
Sample size320
Sample variance4.2
Null hypothesis (H0)4.8
Type I error (alpha)0.05
p-value (probability)0.0522928169394425
ConclusionThere is no reason to reject the null hypothesis



Parameters (Session):
par1 = 320 ; par2 = 4.2 ; par3 = 4.8 ; par4 = 0.05 ;
Parameters (R input):
par1 = 320 ; par2 = 4.2 ; par3 = 4.8 ; par4 = 0.05 ;
R code (references can be found in the software module):
par1<-as.numeric(par1)
par2<-as.numeric(par2)
par3<-as.numeric(par3)
par4<-as.numeric(par4)
df <- par1 - 1
myc <- df * par2 / par3
myc
if (par2 > par3)
{
myp <- 1 - pchisq(myc,df)
} else {
myp <- pchisq(myc,df)
}
myp
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,hyperlink('ht_variance.htm','Testing Variance - p-value (probability)','learn more about Statistical Hypothesis Testing about the Variance'),2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Sample size',header=TRUE)
a<-table.element(a,par1)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Sample variance',header=TRUE)
a<-table.element(a,par2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Null hypothesis (H0)',header=TRUE)
a<-table.element(a,par3)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Type I error (alpha)',header=TRUE)
a<-table.element(a,par4)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value (probability)',header=TRUE)
a<-table.element(a,myp)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Conclusion',header=TRUE)
if (myp > par4) a<-table.element(a,'There is no reason to reject the null hypothesis') else a<-table.element(a,'Reject the null hypothesis')
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')