Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_correlation.wasp
Title produced by softwarePearson Correlation
Date of computationWed, 16 Dec 2015 12:24:24 +0000
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2015/Dec/16/t1450268698gs2q79unp88hwpy.htm/, Retrieved Thu, 16 May 2024 16:56:43 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=286692, Retrieved Thu, 16 May 2024 16:56:43 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact70
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Pearson Correlation] [] [2015-12-16 12:24:24] [a05da232bd4bc389022edd498fae0565] [Current]
Feedback Forum

Post a new message
Dataseries X:
1530
1297
1335
1282
1590
1300
1400
1255
1355
1375
1340
1380
1355
1522
1208
1405
1358
1292
1340
1400
1357
1287
1275
1270
1635
1505
1490
1485
1310
1420
1318
1432
1364
1405
1432
1207
1375
1350
1236
1250
1350
1320
1525
1570
1340
1422
1506
1215
1311
1300
1224
1350
1335
1390
1400
1225
1310
1560
1330
1222
1415
1175
1330
1485
1470
1135
1310
1154
1510
1415
1468
1390
1380
1432
1240
1195
1225
1188
1252
1315
1245
1430
1279
1245
1309
1412
1120
1220
1280
1440
1370
1192
1230
1346
1290
1165
1240
1132
1242
1270
1218
1430
1588
1320
1290
1260
1425
1226
1360
1620
1310
1250
1295
1290
1290
1275
1250
1270
1362
1300
1173
1256
1440
1180
1306
1350
1125
1165
1312
1300
1270
1335
1450
1310
1027
1235
1260
1165
1080
1127
1270
1252
1200
1290
1334
1380
1140
1243
1340
1168
1322
1249
1321
1192
1373
1170
1265
1235
1302
1241
1078
1520
1460
1075
1280
1180
1250
1190
1374
1306
1202
1240
1316
1280
1350
1180
1210
1127
1324
1210
1290
1100
1280
1175
1160
1205
1163
1022
1243
1350
1237
1204
1090
1355
1250
1076
1120
1220
1240
1220
1095
1235
1105
1405
1150
1305
1220
1296
1175
955
1070
1320
1060
1130
1250
1225
1180
1178
1142
1130
1185
1012
1280
1103
1408
1300
1246
1380
1350
1060
1350
1220
1110
1215
1104
1170
1120
Dataseries Y:
4512
3738
4261
3777
4177
3585
3785
3559
3613
3982
3443
3993
3640
4208
3832
3876
3497
3466
3095
4424
3878
4046
3804
3710
4747
4423
4036
4022
3454
4175
3787
3796
4103
4161
4158
3814
3527
3748
3334
3492
3962
3505
4315
3804
3863
4034
4308
3165
3641
3644
3891
3793
4270
4063
4012
3458
3890
4166
3935
3669
3866
3393
4442
4253
3727
3329
3415
3372
4430
4381
4008
3858
4121
4057
3824
3394
3558
3362
3930
3835
3830
3856
3249
3577
3933
3850
3309
3406
3506
3907
4160
3318
3662
3899
3700
3779
3473
3490
3654
3478
3495
3834
3876
3661
3618
3648
4032
3399
3916
4430
3695
3524
3571
3594
3383
3499
3589
3900
4114
3937
3399
4200
4488
3614
4051
3782
3391
3124
4053
3582
3666
3532
4046
3667
2857
3436
3791
3302
3104
3171
3572
3530
3175
3438
3903
3899
3401
3267
3451
3090
3413
3323
3680
3439
3853
3156
3279
3707
4006
3269
3071
3779
3548
3292
3497
3082
3248
3358
3803
3566
3145
3503
3571
3724
3615
3203
3609
3561
3979
3533
3689
3158
4005
3181
3479
3642
3632
3069
3394
3703
3165
3354
3000
3687
3556
2773
3058
3344
3493
3297
3360
3228
3277
3851
3067
3692
3402
3995
3318
2720
2937
3580
2939
2989
3586
3156
3246
3170
3268
3389
3381
2864
3740
3479
3647
3716
3284
4204
3735
3218
3685
3704
3214
3394
3233
3352
3391




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 seconds
R Server'Gwilym Jenkins' @ jenkins.wessa.net

\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 & 'Gwilym Jenkins' @ jenkins.wessa.net \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=286692&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]'Gwilym Jenkins' @ jenkins.wessa.net[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=286692&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=286692&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'Gwilym Jenkins' @ jenkins.wessa.net







Pearson Product Moment Correlation - Ungrouped Data
StatisticVariable XVariable Y
Mean1282.873417721523633.99156118143
Biased Variance14420.718154142132852.970392921
Biased Standard Deviation120.08629461409364.490014119621
Covariance35145.6641815061
Correlation0.799569709254296
Determination0.639311719957
T-Test20.4091185668974
p-value (2 sided)0
p-value (1 sided)0
95% CI of Correlation[0.748392699754971, 0.841282257025721]
Degrees of Freedom235
Number of Observations237

\begin{tabular}{lllllllll}
\hline
Pearson Product Moment Correlation - Ungrouped Data \tabularnewline
Statistic & Variable X & Variable Y \tabularnewline
Mean & 1282.87341772152 & 3633.99156118143 \tabularnewline
Biased Variance & 14420.718154142 & 132852.970392921 \tabularnewline
Biased Standard Deviation & 120.08629461409 & 364.490014119621 \tabularnewline
Covariance & 35145.6641815061 \tabularnewline
Correlation & 0.799569709254296 \tabularnewline
Determination & 0.639311719957 \tabularnewline
T-Test & 20.4091185668974 \tabularnewline
p-value (2 sided) & 0 \tabularnewline
p-value (1 sided) & 0 \tabularnewline
95% CI of Correlation & [0.748392699754971, 0.841282257025721] \tabularnewline
Degrees of Freedom & 235 \tabularnewline
Number of Observations & 237 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=286692&T=1

[TABLE]
[ROW][C]Pearson Product Moment Correlation - Ungrouped Data[/C][/ROW]
[ROW][C]Statistic[/C][C]Variable X[/C][C]Variable Y[/C][/ROW]
[ROW][C]Mean[/C][C]1282.87341772152[/C][C]3633.99156118143[/C][/ROW]
[ROW][C]Biased Variance[/C][C]14420.718154142[/C][C]132852.970392921[/C][/ROW]
[ROW][C]Biased Standard Deviation[/C][C]120.08629461409[/C][C]364.490014119621[/C][/ROW]
[ROW][C]Covariance[/C][C]35145.6641815061[/C][/ROW]
[ROW][C]Correlation[/C][C]0.799569709254296[/C][/ROW]
[ROW][C]Determination[/C][C]0.639311719957[/C][/ROW]
[ROW][C]T-Test[/C][C]20.4091185668974[/C][/ROW]
[ROW][C]p-value (2 sided)[/C][C]0[/C][/ROW]
[ROW][C]p-value (1 sided)[/C][C]0[/C][/ROW]
[ROW][C]95% CI of Correlation[/C][C][0.748392699754971, 0.841282257025721][/C][/ROW]
[ROW][C]Degrees of Freedom[/C][C]235[/C][/ROW]
[ROW][C]Number of Observations[/C][C]237[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=286692&T=1

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

As an alternative you can also use a QR Code:  

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

Pearson Product Moment Correlation - Ungrouped Data
StatisticVariable XVariable Y
Mean1282.873417721523633.99156118143
Biased Variance14420.718154142132852.970392921
Biased Standard Deviation120.08629461409364.490014119621
Covariance35145.6641815061
Correlation0.799569709254296
Determination0.639311719957
T-Test20.4091185668974
p-value (2 sided)0
p-value (1 sided)0
95% CI of Correlation[0.748392699754971, 0.841282257025721]
Degrees of Freedom235
Number of Observations237







Normality Tests
> jarque.x
	Jarque-Bera Normality Test
data:  x
JB = 3.0501, p-value = 0.2176
alternative hypothesis: greater
> jarque.y
	Jarque-Bera Normality Test
data:  y
JB = 2.4076, p-value = 0.3001
alternative hypothesis: greater
> ad.x
	Anderson-Darling normality test
data:  x
A = 0.432, p-value = 0.3024
> ad.y
	Anderson-Darling normality test
data:  y
A = 0.35242, p-value = 0.4641

\begin{tabular}{lllllllll}
\hline
Normality Tests \tabularnewline
> jarque.x
	Jarque-Bera Normality Test
data:  x
JB = 3.0501, p-value = 0.2176
alternative hypothesis: greater
\tabularnewline
> jarque.y
	Jarque-Bera Normality Test
data:  y
JB = 2.4076, p-value = 0.3001
alternative hypothesis: greater
\tabularnewline
> ad.x
	Anderson-Darling normality test
data:  x
A = 0.432, p-value = 0.3024
\tabularnewline
> ad.y
	Anderson-Darling normality test
data:  y
A = 0.35242, p-value = 0.4641
\tabularnewline \hline \end{tabular} %Source: https://freestatistics.org/blog/index.php?pk=286692&T=2

[TABLE]
[ROW][C]Normality Tests[/C][/ROW]
[ROW][C]
> jarque.x
	Jarque-Bera Normality Test
data:  x
JB = 3.0501, p-value = 0.2176
alternative hypothesis: greater
[/C][/ROW] [ROW][C]
> jarque.y
	Jarque-Bera Normality Test
data:  y
JB = 2.4076, p-value = 0.3001
alternative hypothesis: greater
[/C][/ROW] [ROW][C]
> ad.x
	Anderson-Darling normality test
data:  x
A = 0.432, p-value = 0.3024
[/C][/ROW] [ROW][C]
> ad.y
	Anderson-Darling normality test
data:  y
A = 0.35242, p-value = 0.4641
[/C][/ROW] [/TABLE] Source: https://freestatistics.org/blog/index.php?pk=286692&T=2

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

As an alternative you can also use a QR Code:  

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

Normality Tests
> jarque.x
	Jarque-Bera Normality Test
data:  x
JB = 3.0501, p-value = 0.2176
alternative hypothesis: greater
> jarque.y
	Jarque-Bera Normality Test
data:  y
JB = 2.4076, p-value = 0.3001
alternative hypothesis: greater
> ad.x
	Anderson-Darling normality test
data:  x
A = 0.432, p-value = 0.3024
> ad.y
	Anderson-Darling normality test
data:  y
A = 0.35242, p-value = 0.4641



Parameters (Session):
Parameters (R input):
R code (references can be found in the software module):
library(psychometric)
x <- x[!is.na(y)]
y <- y[!is.na(y)]
y <- y[!is.na(x)]
x <- x[!is.na(x)]
bitmap(file='test1.png')
histx <- hist(x, plot=FALSE)
histy <- hist(y, plot=FALSE)
maxcounts <- max(c(histx$counts, histx$counts))
xrange <- c(min(x),max(x))
yrange <- c(min(y),max(y))
nf <- layout(matrix(c(2,0,1,3),2,2,byrow=TRUE), c(3,1), c(1,3), TRUE)
par(mar=c(4,4,1,1))
plot(x, y, xlim=xrange, ylim=yrange, xlab=xlab, ylab=ylab, sub=main)
par(mar=c(0,4,1,1))
barplot(histx$counts, axes=FALSE, ylim=c(0, maxcounts), space=0)
par(mar=c(4,0,1,1))
barplot(histy$counts, axes=FALSE, xlim=c(0, maxcounts), space=0, horiz=TRUE)
dev.off()
lx = length(x)
makebiased = (lx-1)/lx
varx = var(x)*makebiased
vary = var(y)*makebiased
corxy <- cor.test(x,y,method='pearson', na.rm = T)
cxy <- as.matrix(corxy$estimate)[1,1]
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Pearson Product Moment Correlation - Ungrouped Data',3,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Statistic',1,TRUE)
a<-table.element(a,'Variable X',1,TRUE)
a<-table.element(a,'Variable Y',1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('arithmetic_mean.htm','Mean',''),header=TRUE)
a<-table.element(a,mean(x))
a<-table.element(a,mean(y))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('biased.htm','Biased Variance',''),header=TRUE)
a<-table.element(a,varx)
a<-table.element(a,vary)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('biased1.htm','Biased Standard Deviation',''),header=TRUE)
a<-table.element(a,sqrt(varx))
a<-table.element(a,sqrt(vary))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('covariance.htm','Covariance',''),header=TRUE)
a<-table.element(a,cov(x,y),2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('pearson_correlation.htm','Correlation',''),header=TRUE)
a<-table.element(a,cxy,2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('coeff_of_determination.htm','Determination',''),header=TRUE)
a<-table.element(a,cxy*cxy,2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink('ttest_statistic.htm','T-Test',''),header=TRUE)
a<-table.element(a,as.matrix(corxy$statistic)[1,1],2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value (2 sided)',header=TRUE)
a<-table.element(a,(p2 <- as.matrix(corxy$p.value)[1,1]),2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value (1 sided)',header=TRUE)
a<-table.element(a,p2/2,2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'95% CI of Correlation',header=TRUE)
a<-table.element(a,paste('[',CIr(r=cxy, n = lx, level = .95)[1],', ', CIr(r=cxy, n = lx, level = .95)[2],']',sep=''),2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Degrees of Freedom',header=TRUE)
a<-table.element(a,lx-2,2)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Number of Observations',header=TRUE)
a<-table.element(a,lx,2)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')
library(moments)
library(nortest)
jarque.x <- jarque.test(x)
jarque.y <- jarque.test(y)
if(lx>7) {
ad.x <- ad.test(x)
ad.y <- ad.test(y)
}
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Normality Tests',1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,paste('
',RC.texteval('jarque.x'),'
',sep=''))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,paste('
',RC.texteval('jarque.y'),'
',sep=''))
a<-table.row.end(a)
if(lx>7) {
a<-table.row.start(a)
a<-table.element(a,paste('
',RC.texteval('ad.x'),'
',sep=''))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,paste('
',RC.texteval('ad.y'),'
',sep=''))
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable1.tab')
library(car)
bitmap(file='test2.png')
qq.plot(x,main='QQplot of variable x')
dev.off()
bitmap(file='test3.png')
qq.plot(y,main='QQplot of variable y')
dev.off()