Read the Data and calculate correlation
FSM_COR_Data <- read.table("C:/Users/skb67/Desktop/FSM-CodeBased/FSM_COR.txt"
,header=TRUE)
FSM_ALL_Data <- read.table("C:/Users/skb67/Desktop/FSM-CodeBased/FSM_ALL.txt"
,header=TRUE)
FSM_ROR_Data <- read.table("C:/Users/skb67/Desktop/FSM-CodeBased/FSM_ROR.txt"
,header=TRUE)
res_FSM_COR <- cor.test(FSM_COR_Data$FSM, FSM_COR_Data$COR,
method = "pearson")
res_FSM_ALL <- cor.test(FSM_ALL_Data$FSM, FSM_ALL_Data$ALL,
method = "pearson")
res_FSM_ROR <- cor.test(FSM_ROR_Data$FSM, FSM_ROR_Data$ROR,
method = "pearson")
#http://www.sthda.com/english/wiki/correlation-test-between-two-variables-in-r
Print FSM_COR correlation
print(res_FSM_COR)
##
## Pearson's product-moment correlation
##
## data: FSM_COR_Data$FSM and FSM_COR_Data$COR
## t = -0.94488, df = 9, p-value = 0.3694
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## -0.7628198 0.3652917
## sample estimates:
## cor
## -0.3004125
Print FSM_ALL correlation
print(res_FSM_ALL)
##
## Pearson's product-moment correlation
##
## data: FSM_ALL_Data$FSM and FSM_ALL_Data$ALL
## t = 0.72624, df = 9, p-value = 0.4861
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## -0.4245060 0.7318633
## sample estimates:
## cor
## 0.2352843
Print FSM_ROR correlation
print(res_FSM_ROR)
##
## Pearson's product-moment correlation
##
## data: FSM_ROR_Data$FSM and FSM_ROR_Data$ROR
## t = 1.6101, df = 9, p-value = 0.1418
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## -0.1772651 0.8357008
## sample estimates:
## cor
## 0.4728962