Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_boxcoxnorm.wasp
Title produced by softwareBox-Cox Normality Plot
Date of computationSun, 09 Nov 2008 05:35:32 -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/09/t1226234197hponog5sedwvtby.htm/, Retrieved Sun, 19 May 2024 12:03:29 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=22725, Retrieved Sun, 19 May 2024 12:03:29 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact201
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
F     [Partial Correlation] [Partial correlation] [2008-11-08 12:17:14] [82d201ca7b4e7cd2c6f885d29b5b6937]
F RM D    [Box-Cox Normality Plot] [Box Cox Normality] [2008-11-09 12:35:32] [00a0a665d7a07edd2e460056b0c0c354] [Current]
F           [Box-Cox Normality Plot] [Box cox normality] [2008-11-10 22:32:57] [8d78428855b119373cac369316c08983]
Feedback Forum
2008-11-21 21:55:27 [Kim Wester] [reply
Ook hier transformeert het lambda getal de y reeks zodat er een lineair verband = rechte ontstaat.

In dit geval is er visueel wel een duidelijk verschil waar te nemen tussen de reeksen voor en na de transformatie in de Normal Q-Q Plots.
De Box-Cox Normality Plot weergeeft geen maximum.
Een oplossing zou het vergroten van de lambda waarden zijn (dit kan door een aanpassing te doen in de R-code).
2008-11-23 11:03:07 [Inge Meelberghs] [reply
In tegenstelling tot de box cox linearity plot zien we hier wel een duidelijk verschil nadat de data getransformeert is. Dit kunnen we waarnemen in zowel de histogram als de Q-Q plot. De optimale lambda waarde bedraagt -2. Ook dit kunnen we weer niet goed zien op de box cox normality plot doordat er geen maximum aanwezig is. Dit kunnen we oplossen door de lambda waarde te vergroten door aanpassing van de R-code. Als dit gebeurd is kunnen we waarschijnlijk wél een besluit trekken.
2008-11-23 17:13:38 [Michaël De Kuyer] [reply
Via deze methode wil men een meer normaalverdeling verkrijgen door de data te transformeren. Aan de hand van de grafieken kunnen we vaststellen dat de lambda waarde geen maximum bereikt (vergroten is mogelijk in de R-code). Op de QQ-plot kan men zien dat er een transformatie is geweest en dat sommige punten dichter bij de rechte liggen.
2008-11-24 12:15:08 [Bonifer Spillemaeckers] [reply
De bovenstaande conclusies zijn naar mijn mening volledig correct.

Post a new message
Dataseries X:
118,9
108,8
115,6
95,0
92,8
108,9
109,8
106,1
102,8
98,4
85,7
114,6
129,4
117,7
126,6
103,8
101,5
118,7
119,6
114,8
109,9
106,3
95,0
124,5
140,4
128,8
137,5
113,3
110,3
129,1
128,4
120,3
113,6
96,9
124,7
126,4
131,9
122,5
113,1
99,8
116,0
115,0
114,0
111,0
91,7
90,6
103,3
106,7
111,2
102,9
126,5
115,1
110,2
110,1
103,3
107,7
103,9
114,0
117,2
117,0
116,5




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time4 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24

\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 & 4 seconds \tabularnewline
R Server & 'Sir Ronald Aylmer Fisher' @ 193.190.124.24 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=22725&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]4 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Sir Ronald Aylmer Fisher' @ 193.190.124.24[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=22725&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=22725&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 time4 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24







Box-Cox Normality Plot
# observations x61
maximum correlation0.0950513663079315
optimal lambda-2

\begin{tabular}{lllllllll}
\hline
Box-Cox Normality Plot \tabularnewline
# observations x & 61 \tabularnewline
maximum correlation & 0.0950513663079315 \tabularnewline
optimal lambda & -2 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=22725&T=1

[TABLE]
[ROW][C]Box-Cox Normality Plot[/C][/ROW]
[ROW][C]# observations x[/C][C]61[/C][/ROW]
[ROW][C]maximum correlation[/C][C]0.0950513663079315[/C][/ROW]
[ROW][C]optimal lambda[/C][C]-2[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=22725&T=1

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

As an alternative you can also use a QR Code:  

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

Box-Cox Normality Plot
# observations x61
maximum correlation0.0950513663079315
optimal lambda-2



Parameters (Session):
Parameters (R input):
R code (references can be found in the software module):
n <- length(x)
c <- array(NA,dim=c(401))
l <- array(NA,dim=c(401))
mx <- 0
mxli <- -999
for (i in 1:401)
{
l[i] <- (i-201)/100
if (l[i] != 0)
{
x1 <- (x^l[i] - 1) / l[i]
} else {
x1 <- log(x)
}
c[i] <- cor(qnorm(ppoints(x), mean=0, sd=1),x1)
if (mx < c[i])
{
mx <- c[i]
mxli <- l[i]
}
}
c
mx
mxli
if (mxli != 0)
{
x1 <- (x^mxli - 1) / mxli
} else {
x1 <- log(x)
}
bitmap(file='test1.png')
plot(l,c,main='Box-Cox Normality Plot',xlab='Lambda',ylab='correlation')
mtext(paste('Optimal Lambda =',mxli))
grid()
dev.off()
bitmap(file='test2.png')
hist(x,main='Histogram of Original Data',xlab='X',ylab='frequency')
grid()
dev.off()
bitmap(file='test3.png')
hist(x1,main='Histogram of Transformed Data',xlab='X',ylab='frequency')
grid()
dev.off()
bitmap(file='test4.png')
qqnorm(x)
qqline(x)
grid()
mtext('Original Data')
dev.off()
bitmap(file='test5.png')
qqnorm(x1)
qqline(x1)
grid()
mtext('Transformed Data')
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Box-Cox Normality Plot',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'# observations x',header=TRUE)
a<-table.element(a,n)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'maximum correlation',header=TRUE)
a<-table.element(a,mx)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'optimal lambda',header=TRUE)
a<-table.element(a,mxli)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')