Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_boxcoxlin.wasp
Title produced by softwareBox-Cox Linearity Plot
Date of computationTue, 10 Nov 2009 14:28:53 -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/2009/Nov/10/t12578886076bv20yzbx0t9qvz.htm/, Retrieved Mon, 06 May 2024 06:29:21 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=55415, Retrieved Mon, 06 May 2024 06:29:21 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact131
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-     [Box-Cox Linearity Plot] [3/11/2009] [2009-11-02 21:47:57] [b98453cac15ba1066b407e146608df68]
- R  D    [Box-Cox Linearity Plot] [WS6-Box-Cox Linea...] [2009-11-10 21:28:53] [0cc924834281808eda7297686c82928f] [Current]
Feedback Forum

Post a new message
Dataseries X:
423.4
404.1
500
472.6
496.1
562
434.8
538.2
577.6
518.1
625.2
561.2
523.3
536.1
607.3
637.3
606.9
652.9
617.2
670.4
729.9
677.2
710
844.3
748.2
653.9
742.6
854.2
808.4
1819
1936.5
1966.1
2083.1
1620.1
1527.6
1795
1685.1
1851.8
2164.4
1981.8
1726.5
2144.6
1758.2
1672.9
1837.3
1596.1
1446
1898.4
1964.1
1755.9
2255.3
1881.2
2117.9
1656.5
1544.1
2098.9
2133.3
1963.5
1801.2
2365.4
1936.5
1667.6
1983.5
2058.6
2448.3
1858.1
1625.4
2130.6
2515.7
2230.2
2086.9
2235
2100.2
2288.6
2490
2573.7
2543.8
2004.7
2390
2338.4
2724.5
2292.5
2386
2477.9
2337
2605.1
2560.8
2839.3
2407.2
2085.2
2735.6
2798.7
3053.2
2405
2471.9
2727.3
2790.7
2385.4
3206.6
2705.6
3518.4
1954.9
2584.3
2535.8
2685.9
2866
2236.6
2934.9
2668.6
2371.2
3165.9
2887.2
3112.2
2671.2
2432.6
2812.3
3095.7
2862.9
2607.3
2862.5
Dataseries Y:
286.1
307
358.1
341.8
378.8
375.2
295.6
362.7
409.6
336.8
389.1
389.3
355.9
542
648.4
452
582.4
506.5
555.5
530.4
609.4
543.9
616.2
634.6
541.7
549.8
627.6
797.4
689.8
1576.6
1572.1
1626.4
1972.4
1509.6
1584.9
1880
1324
1777.7
2172.4
1780.3
2134.9
1838.4
1557
1755.2
1702
1577.5
1485.9
2179.1
1740.9
1724.5
2328.1
1774.1
2224.2
1536.3
1521.2
2051.8
2483.1
1929.8
1808.6
2584.9
1997.9
1639.9
2379.1
1715
2750.9
1865.4
1647.4
2180.4
2593
2057.2
2635.8
2315.4
1863.6
2038
2235.8
2222.1
2636.9
2076.8
1935.5
2086.3
2470.9
1854.6
2041.3
2170.8
1905.5
2130.2
2791.2
2539.7
2661.3
1764.9
2176.9
2458.5
2179
2242.5
2089.6
2661.6
2112
2367.3
2543
2603.9
3146.7
1789.2
2114.8
2236.3
2288.1
2173.2
1877.7
2807.4
2357.4
2107.7
2856.8
2510.8
2875
2229.7
2055.1
2545.4
2775.1
2252.2
2091.7
2433




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 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 & 3 seconds \tabularnewline
R Server & 'Sir Ronald Aylmer Fisher' @ 193.190.124.24 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=55415&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]3 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=55415&T=0

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







Box-Cox Linearity Plot
# observations x120
maximum correlation0.96632221156802
optimal lambda(x)0.47
Residual SD (orginial)222.359666309417
Residual SD (transformed)201.565890378098

\begin{tabular}{lllllllll}
\hline
Box-Cox Linearity Plot \tabularnewline
# observations x & 120 \tabularnewline
maximum correlation & 0.96632221156802 \tabularnewline
optimal lambda(x) & 0.47 \tabularnewline
Residual SD (orginial) & 222.359666309417 \tabularnewline
Residual SD (transformed) & 201.565890378098 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=55415&T=1

[TABLE]
[ROW][C]Box-Cox Linearity Plot[/C][/ROW]
[ROW][C]# observations x[/C][C]120[/C][/ROW]
[ROW][C]maximum correlation[/C][C]0.96632221156802[/C][/ROW]
[ROW][C]optimal lambda(x)[/C][C]0.47[/C][/ROW]
[ROW][C]Residual SD (orginial)[/C][C]222.359666309417[/C][/ROW]
[ROW][C]Residual SD (transformed)[/C][C]201.565890378098[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=55415&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=55415&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 Linearity Plot
# observations x120
maximum correlation0.96632221156802
optimal lambda(x)0.47
Residual SD (orginial)222.359666309417
Residual SD (transformed)201.565890378098



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(x1,y)
if (mx < abs(c[i]))
{
mx <- abs(c[i])
mxli <- l[i]
}
}
c
mx
mxli
if (mxli != 0)
{
x1 <- (x^mxli - 1) / mxli
} else {
x1 <- log(x)
}
r<-lm(y~x)
se <- sqrt(var(r$residuals))
r1 <- lm(y~x1)
se1 <- sqrt(var(r1$residuals))
bitmap(file='test1.png')
plot(l,c,main='Box-Cox Linearity Plot',xlab='Lambda',ylab='correlation')
grid()
dev.off()
bitmap(file='test2.png')
plot(x,y,main='Linear Fit of Original Data',xlab='x',ylab='y')
abline(r)
grid()
mtext(paste('Residual Standard Deviation = ',se))
dev.off()
bitmap(file='test3.png')
plot(x1,y,main='Linear Fit of Transformed Data',xlab='x',ylab='y')
abline(r1)
grid()
mtext(paste('Residual Standard Deviation = ',se1))
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Box-Cox Linearity 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(x)',header=TRUE)
a<-table.element(a,mxli)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Residual SD (orginial)',header=TRUE)
a<-table.element(a,se)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Residual SD (transformed)',header=TRUE)
a<-table.element(a,se1)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')