verso
## 5 3 -1.4417
## 6 1100 0.0153grab
高中英语动词词组## 读取metadata⾥⾯的注释信息
metadata <- jsonlite::fromJSON("metadata.cart.2021-02-15.json")
library(dplyr)
metadata_id <- metadata %>%
dplyr::lect(c(file_name,associated_entities))
meta_df <- do.call(rbind,metadata$associated_entities)
head(metadata_id,2)
## file_name
## 1 TRIAL_p_TCGA_191_193_SNP_N_GenomeWideSNP_6_v2.txt
## 2 COAPT_p_TCGASNP_197_201_204_N_GenomeWideSNP_6_v2.txt
## associated_entities
## 1 TCGA-EL-A3D5-10A-01D-A201-01, aliquot, e9ccf355-e68a-489c-a914-31b766bd0aef, a1e0d8be-7916-4bb2-9c3f-1e74b51c6ed3 ## 2 TCGA-E3-A3DY-10A-01D-A20A-01, aliquot, dffef9e8-5b69-43d9-a95b-0744daa38d1d, b75decce-46f0-4689-be1b-08a9943775eb ## 匹配样本
cnv_df$Sample <- meta_df$entity_submitter_id[match(cnv_df$GDC_Aliquot,meta_df$entity_id)]
length(unique(cnv_df$GDC_Aliquot))
## [1] 1025
length(unique(cnv_df$Sample))
## [1] 1025
head(cnv_df)
## GDC_Aliquot Chromosome Start End
## 1 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 1 3301765 247650984
## 2 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 480597 236626512
## 3 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 236626820 236627088
## 4 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 236631315 237489539ocom
## 5 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 237489625 237489879植树节英语
## 6 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 237492059 239533237
## Num_Probes Segment_Mean Sample
## 1 129636 0.0174 TCGA-BJ-A0Z9-01A-11D-A10T-01
## 2 129172 0.0159 TCGA-BJ-A0Z9-01A-11D-A10T-01
## 3 2 -1.5617 TCGA-BJ-A0Z9-01A-11D-A10T-01
全国研究生网上报名系统
## 4 639 0.0003 TCGA-BJ-A0Z9-01A-11D-A10T-01
## 5 3 -1.4417 TCGA-BJ-A0Z9-01A-11D-A10T-01
## 6 1100 0.0153 TCGA-BJ-A0Z9-01A-11D-A10T-01
## 改名
cnv_df$Sample <- substring(cnv_df$Sample,1,16)
head(cnv_df)
## GDC_Aliquot Chromosome Start End
## 1 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 1 3301765 247650984
## 2 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 480597 236626512
## 3 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 236626820 236627088
## 4 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 236631315 237489539
## 5 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 237489625 237489879
topspeed
## 6 3c7ea150-a119-4cd1-a7ef-1543ef87eebf 2 237492059 239533237
## Num_Probes Segment_Mean Sample
## 1 129636 0.0174 TCGA-BJ-A0Z9-01A
## 2 129172 0.0159 TCGA-BJ-A0Z9-01A
## 3 2 -1.5617 TCGA-BJ-A0Z9-01A
## 4 639 0.0003 TCGA-BJ-A0Z9-01A
## 5 3 -1.4417 TCGA-BJ-A0Z9-01A
## 6 1100 0.0153 TCGA-BJ-A0Z9-01A
## Gistic只需要maskedCNS的六列
cnv_df <- cnv_df[,c('Sample','Chromosome','Start','End','Num_Probes','Segment_Mean')]
head(cnv_df)
## Sample Chromosome Start End Num_Probes Segment_Mean
## 1 TCGA-BJ-A0Z9-01A 1 3301765 247650984 129636 0.0174
溏心风暴主题曲## 2 TCGA-BJ-A0Z9-01A 2 480597 236626512 129172 0.0159
## 3 TCGA-BJ-A0Z9-01A 2 236626820 236627088 2 -1.5617
## 4 TCGA-BJ-A0Z9-01A 2 236631315 237489539 639 0.0003
## 5 TCGA-BJ-A0Z9-01A 2 237489625 237489879 3 -1.4417
pid什么意思
## 6 TCGA-BJ-A0Z9-01A 2 237492059 239533237 1100 0.0153
新航道官网# 只挑选肿瘤样本
dim(cnv_df)
## [1] 61626 6
cnv_df <- cnv_df[grep("01A$",cnv_df$Sample),]
dim(cnv_df)
## [1] 28628 6
head(cnv_df)
## Sample Chromosome Start End Num_Probes Segment_Mean
## 1 TCGA-BJ-A0Z9-01A 1 3301765 247650984 129636 0.0174
## 2 TCGA-BJ-A0Z9-01A 2 480597 236626512 129172 0.0159