inst/doc/MelanomaTCGA.R

## ---- echo=TRUE, message=FALSE-------------------------------------------
library(CollateralVulnerability2016)
library(dplyr)

## ----eval=FALSE----------------------------------------------------------
#  work_dir <- '~/BigData/CollateralVulnerability2016/skcm/'
#  download_dir <- '~/BigData/RTCGA_downloads/'
#  mydb <- 'skcm_output.db'
#  mydb_path <- paste0(work_dir, mydb)
#  my_con <- setupSQLite ( mydb_path )
#  

## ----eval=FALSE----------------------------------------------------------
#  all_genes <- getAllHumanGenes(my_con)
#  head(all_genes)
#  

## ----eval=FALSE----------------------------------------------------------
#  src_sqlite(my_con@dbname) %>% tbl('human_genes')

## ----eval=FALSE----------------------------------------------------------
#  
#  rnaseq_dat <- getTCGARNAseqData(my_con, cancerTypes='SKCM', releaseDate = '2015-11-01', sampletag=c('01A', '06A'))
#  dim(rnaseq_dat)
#  
#  mutation_dat <- getTCGAMutationData(my_con, cancerTypes='SKCM', releaseDate = '2015-11-01', sampletag=c('01A', '06A'))
#  dim(mutation_dat)
#  
#  DBI::dbListTables(my_con)
#  

## ----eval=FALSE----------------------------------------------------------
#  
#  bisep_output <- doBISEPAnalysis(my_con, genes_n=100000)
#  

## ----eval=FALSE----------------------------------------------------------
#  
#  bisep_results <- src_sqlite(my_con@dbname) %>%
#      dplyr::tbl('bisep_results') %>%
#      dplyr::filter(bisep_pval < 0.1 & pi_value <0.2) %>%
#      dplyr::collect() %>%
#      inner_join(all_genes, by=c('gene_name'='gene_id')) %>%
#      dplyr::select(gene_name, gene_name.y, everything()) %>%
#      dplyr::arrange(gene_name.y)
#  bisep_results
#  

## ----eval=FALSE----------------------------------------------------------
#  doRNAseqPlot(my_con, 'ENSG00000176024')
#  

## ----eval = FALSE--------------------------------------------------------
#  
#  human_paralog_res <- countHumanParalogs(my_con, bisep_results$gene_name)
#  

## ----eval = FALSE--------------------------------------------------------
#  flymine_res <- doFlyMineAnalysis(my_con, bisep_results$gene_name)
#  

## ----eval = FALSE--------------------------------------------------------
#  wormmine_res <- doWormMineAnalysis(my_con, bisep_results$gene_name)
#  

## ----eval = FALSE--------------------------------------------------------
#  mut_res <- doMutationAnalysis(my_con, bisep_results$gene_name)
#  

## ----eval=FALSE----------------------------------------------------------
#  combo_res <- combineResults(my_con, bisep_results$gene_name)

## ----eval=FALSE----------------------------------------------------------
#      filtered_results <- src_sqlite(my_con@dbname) %>%
#      dplyr::tbl('combined_results') %>%
#      dplyr::filter(count_paralogs > 0 & count_paralogs <= 5 & (lethal_pct_fly >= 20 | lethal_pct_worm >= 20) ) %>%
#      dplyr::collect()

## ----eval=FALSE----------------------------------------------------------
#      shinyVisApp(my_con)
chapmandu2/CollateralVulnerability2016 documentation built on May 13, 2019, 3:27 p.m.