Created
May 15, 2018 01:40
-
-
Save mbk0asis/43038163a3a45b007e3331e324612b1e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#source("https://bioconductor.org/biocLite.R") | |
#biocLite("TCGAbiolinks") | |
library(TCGAbiolinks) | |
library(data.table) | |
library(dplyr) | |
library(DT) | |
############################################################ | |
# Clinical data | |
# | |
# available clinical info; admin,aliquot,analyte,bio_patient,drug, | |
# follow_up,msi,new_tumor_event,patient, | |
# portion,protocol,radiation,sample,slide,stage_event | |
# | |
query <- GDCquery(project = "TCGA-HNSC", | |
data.category = "Clinical") | |
GDCdownload(query, method = "api", files.per.chunk = 5) | |
clinical <- GDCprepare_clinic(query, | |
clinical.info = "patient") | |
write.csv(clinical,"~/Desktop/TCGA-HNSC.clinical.csv") | |
########################################################### | |
# Gene expression data for Lung cancer (LUAD, LUSC) | |
# | |
query.LUSC <- GDCquery(project = c("TCGA-LUSC"), | |
data.category="Transcriptome Profiling", | |
data.type="Gene Expression Quantification", | |
workflow.type="HTSeq - Counts", | |
sample.type=c("Primary solid Tumor","Solid Tissue Normal")) | |
GDCdownload(query.LUSC, method = "api", files.per.chunk = 5) | |
dta.exp.LUSC <- GDCprepare(query.LUSC, save=TRUE, | |
save.filename="LUSC_geneExp_dataframe.rda", | |
summarizedExperiment=TRUE) | |
geneExp <- SummarizedExperiment::assay(dta.exp.LUSC) | |
write.csv(geneExp,"/home/bio0/00-NGS/SETDB1_TCGA/exp.LUSC.counts.csv") | |
########################################################### | |
# CNV data for Lung cancer (LUAD, LUSC) | |
# | |
query.lung.cnv <- GDCquery(project = c("TCGA-LUAD","TCGA-LUSC"), | |
data.category="Copy Number Variation", | |
data.type="Masked Copy Number Segment", | |
sample.type=c("Primary solid Tumor","Solid Tissue Normal")) | |
GDCdownload(query.lung.cnv, method = "api", files.per.chunk = 5) | |
dta.CNV.LUNG <- GDCprepare(query.lung.cnv, save=TRUE, | |
save.filename="Lung_CNV_dataframe.rda") | |
write.csv(dta.CNV.LUNG,"/home/bio0/00-NGS/COSMIC_SETDB1/CNV.LUNG.csv") | |
########################################################### | |
# DNA met for Lung cancer (LUAD, LUSC) | |
# | |
query.LUAD.met <- GDCquery(project = c("TCGA-LUAD"), legacy = F, | |
data.category="DNA Methylation", | |
platform="Illumina Human Methylation 450", | |
sample.type=c("Primary solid Tumor","Solid Tissue Normal")) | |
GDCdownload(query.LUAD.met, method = "api", files.per.chunk = 5) | |
dta.LUAD.met <- GDCprepare(query.LUAD.met, save=TRUE, | |
save.filename="Lung_Met_dataframe.rda") | |
write.csv(dta.LUAD.met,"/home/bio0/00-NGS/COSMIC_SETDB1/LUAD.DNAmet.csv") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment