library(cisPath)
input <- system.file("extdata", "9606.mitab.100.txt", package="cisPath")
output <- file.path(tempdir(), "iRefIndex.txt")
formatiRefIndex(input, output)
outputDir <- file.path(getwd(), "cisPath_test")
dir.create(outputDir, showWarnings=FALSE, recursive=TRUE)
# Download iRefIndex PPI for humans only (compressed:~105M, decompressed:~757M)
destfile <- file.path(outputDir, "9606.mitab.08122013.txt.zip")
cat("Downloading...\n")
httpURL <- "http://irefindex.org/download"
filePath <- "irefindex/data/archive/release_13.0/psi_mitab/MITAB2.6"
fileName <- "9606.mitab.08122013.txt.zip"
URL <- paste(httpURL, filePath, fileName, sep="/")
download.file(URL, destfile)
unzip(destfile, overwrite=TRUE, exdir=outputDir)
# Format iRefIndex PPI
fileFromiRef <- file.path(outputDir, "9606.mitab.08122013.txt")
iRefIndex <- file.path(outputDir, "iRefIndex.txt")
formatiRefIndex(fileFromiRef, output=iRefIndex)Run the code above in your browser using DataLab