if (FALSE) {
a <- GWAS_quantitative(plink_path, DummyData, Qphe_discovery, Qcov_discovery)
trd <- a[c("ID", "A1", "BETA")]
b <- GWEIS_quantitative(plink_path, DummyData, Qphe_discovery, Qcov_discovery)
add <- b[c("ID", "A1", "ADD_BETA")]
gxe <- b[c("ID", "A1", "INTERACTION_BETA")]
x <- PRS_quantitative(plink_path, DummyData, summary_input = trd)
sink("Q_trd.sscore") #to create a file in the working directory
write.table(x, sep = " ", row.names = FALSE, quote = FALSE) #to write the output
sink() #to save the output
head(x) #to read the head of all columns in the output
x$FID #to extract the family ID's of full dataset
x$IID #to extract the individual ID's of full dataset
x$PRS #to extract the polygenic risk scores of full dataset
y <- PRS_quantitative(plink_path, DummyData, summary_input = add)
sink("Q_add.sscore") #to create a file in the working directory
write.table(y, sep = " ", row.names = FALSE, quote = FALSE) #to write the output
sink() #to save the output
z <- PRS_quantitative(plink_path, DummyData, summary_input = gxe)
sink("Q_gxe.sscore") #to create a file in the working directory
write.table(z, sep = " ", row.names = FALSE, quote = FALSE) #to write the output
sink() #to save the output
}
Run the code above in your browser using DataLab