## Not run:
# # 1) prepare genes to be predicted
# input.file <-
# "http://dcgor.r-forge.r-project.org/data/Algo/HP_anno.txt"
# #input.file <- "http://dcgor.r-forge.r-project.org/data/Algo/SCOP_architecture.txt"
# input <- utils::read.delim(input.file, header=TRUE, sep="\t",
# colClasses="character")
# data <- unique(input[,1])
#
# # 2) do naive prediction
# GSP.file <- "http://dcgor.r-forge.r-project.org/data/Algo/HP_anno.txt"
# res <- dcNaivePredict(data=data, GSP.file=GSP.file, ontology="HPPA")
# res[1:10,]
#
# # 3) calculate Precision and Recall
# res_PR <- dcAlgoPredictPR(GSP.file=GSP.file, prediction.file=res,
# ontology="HPPA")
# res_PR
#
# # 4) plot PR-curve
# plot(res_PR[,2], res_PR[,1], xlim=c(0,1), ylim=c(0,1), type="b",
# xlab="Recall", ylab="Precision")
# ## End(Not run)
Run the code above in your browser using DataLab