Skip to content

Commit

Permalink
Add functions for data set calling
Browse files Browse the repository at this point in the history
  • Loading branch information
qzhang503 committed Jun 13, 2019
1 parent 214d35d commit 2448373
Show file tree
Hide file tree
Showing 15 changed files with 581,360 additions and 19 deletions.
3 changes: 2 additions & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ export(copy_frac)
export(cptac_csv_1)
export(cptac_csv_2)
export(cptac_expt_1)
export(cptac_expt_2)
export(cptac_expt_ref_w2)
export(cptac_frac_1)
export(cptac_frac_2)
export(expt_smry_ref_w2_w16)
28 changes: 18 additions & 10 deletions R/globalCPTAC.R
Original file line number Diff line number Diff line change
Expand Up @@ -34,33 +34,41 @@ cptac_csv_2 <- function(dat_dir) {



#' Copy \code{expt_smry.xlsx}
#' Copy an \code{expt_smry...} file to \code{dat_dir}
#'
#' \code{copy_expt} copies the \code{expt_smry.xlsx} to a target directory.
#' \code{copy_expt} copies a system file of \code{expt_smry...} to the target
#' directory specified by \code{dat_dir}.
#' @export
copy_expt <- function(dat_dir, filename = "expt_smry.xlsx") {
copy_expt <- function(dat_dir, from = "expt_smry.xlsx", to = "expt_smry.xlsx") {
dir.create(file.path(dat_dir), recursive = TRUE, showWarnings = FALSE)

filepath <- system.file("extdata", filename, package = "proteoQDA")
# if (nchar(filepath) == 0) stop("Load `library(proteoQ)` first.")
filepath <- system.file("extdata", from, package = "proteoQDA")
filepath <- gsub("/", "\\\\", filepath)
file.copy(from = filepath, to = file.path(dat_dir, "expt_smry.xlsx"))
file.copy(from = filepath, to = file.path(dat_dir, to))
}


#' Copy \code{expt_smry.xlsx}
#' Copy an \code{expt_smry...} file to \code{dat_dir}
#'
#' @export
cptac_expt_1 <- function(dat_dir) {
copy_expt(dat_dir, "expt_smry_cptac_gl.xlsx")
copy_expt(dat_dir, "expt_smry_cptac_gl.xlsx", "expt_smry.xlsx")
}


#' Copy an \code{expt_smry...} file to \code{dat_dir}
#'
#' @export
cptac_expt_ref_w2 <- function(dat_dir) {
copy_expt(dat_dir, "expt_smry_ref_w2.xlsx", "expt_smry_ref_w2.xlsx")
}


#' Copy \code{expt_smry.xlsx}
#'
#' @export
cptac_expt_2 <- function(dat_dir) {
copy_expt(dat_dir, "expt_smry_cptac_cmbn.xlsx")
expt_smry_ref_w2_w16 <- function(dat_dir) {
copy_expt(dat_dir, "expt_smry_ref_w2_w16.xlsx", "expt_smry_ref_w2_w16.xlsx")
}


Expand Down
274,046 changes: 274,046 additions & 0 deletions data/Refseq_Hs_2013_07.fasta

Large diffs are not rendered by default.

211,240 changes: 211,240 additions & 0 deletions data/Refseq_Mm_2013_07.fasta

Large diffs are not rendered by default.

6,462 changes: 6,462 additions & 0 deletions data/SwissProt_Dm_2014_07.fasta

Large diffs are not rendered by default.

40,418 changes: 40,418 additions & 0 deletions data/SwissProt_Hs_2014_07.fasta

Large diffs are not rendered by default.

33,342 changes: 33,342 additions & 0 deletions data/SwissProt_Mm_2014_07.fasta

Large diffs are not rendered by default.

15,812 changes: 15,812 additions & 0 deletions data/SwissProt_Rn_2014_07.fasta

Large diffs are not rendered by default.

Binary file modified inst/extdata/expt_smry_cptac_cmbn.xlsx
Binary file not shown.
Binary file added inst/extdata/expt_smry_ref_w2.xlsx
Binary file not shown.
Binary file added inst/extdata/expt_smry_ref_w2_w16.xlsx
Binary file not shown.
7 changes: 4 additions & 3 deletions man/copy_expt.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions man/cptac_expt_1.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions man/cptac_expt_ref_w2.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions man/cptac_expt_2.Rd → man/expt_smry_ref_w2_w16.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 2448373

Please sign in to comment.