{"id":30357,"date":"2024-02-29T15:28:58","date_gmt":"2024-02-29T07:28:58","guid":{"rendered":"http:\/\/www.biocloudservice.com\/wordpress\/?p=30357"},"modified":"2024-02-29T15:28:59","modified_gmt":"2024-02-29T07:28:59","slug":"%e7%83%ad%e7%82%b9%e7%bb%88%e7%bb%93%e8%80%85%ef%bc%9f%e6%b3%9b%e7%99%8c-%e7%9b%ae%e6%a0%87%e5%9f%ba%e5%9b%a0%e9%9b%86%e5%9c%a8%e8%82%bf%e7%98%a4%e7%bb%84%e7%bb%87%e4%b8%8e%e6%ad%a3%e5%b8%b8%e7%bb%84","status":"publish","type":"post","link":"http:\/\/www.biocloudservice.com\/wordpress\/?p=30357","title":{"rendered":"\u70ed\u70b9\u7ec8\u7ed3\u8005\uff1f\u6cdb\u764c-\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u80bf\u7624\u7ec4\u7ec7\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u7684\u5dee\u5f02\u5206\u6790"},"content":{"rendered":"<p>\u70ed\u70b9\u7ec8\u7ed3\u8005\uff1f\u6cdb\u764c-\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u80bf\u7624\u7ec4\u7ec7\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u7684\u5dee\u5f02\u5206\u6790<\/p>\n<p>\u8fd1\u5e74\u6765\uff0c\u591a\u7ef4\u7ec4\u5b66\u8054\u5408\u5206\u6790\u6210\u4e3a\u5927\u8d8b\u52bf\uff0c\u7ecf\u5e38\u51fa\u73b0\u5728\u9ad8\u5206\u6587\u7ae0\u4e2d\uff0c\u6cdb\u764c\u5206\u6790\u5728\u73b0\u5728\u8fd8\u662f\u975e\u5e38\u706b\u7684\uff0c\u800c\u201c\u6cdb\u764c\u201dpancancer\u7814\u7a76\u5c24\u5176\u706b\u70ed\uff0c\u5728pubmed\u4e2d\u641c\u7d22\u4e00\u4e2a\u201dpancer\u201d,\u5c31\u53ef\u4ee5\u53d1\u73b0\u4eca\u5e74\u6765\u76f8\u5173\u6587\u732e\u53d1\u8868\u91cf\u5728\u9010\u5e74\u589e\u52a0\uff0c\u4e3a\u4e86\u8ddf\u4e0a\u65f6\u4ee3\u6f6e\u6d41\uff0c\u5c0f\u679c\u4eca\u5929\u4e3a\u5927\u5bb6\u5206\u4eab\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u6cdb\u764c\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u7684\u5dee\u5f02\u5206\u6790\u5965\uff0c\u90a3\u5c31\u548c\u5c0f\u679c\u5f00\u59cb\u4eca\u5929\u7684\u5b66\u4e60\u4e4b\u65c5\u5427\uff01<\/p>\n<ol>\n<li>\u5982\u4f55\u505a\u6cdb\u764c\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u5dee\u5f02\u5206\u6790\uff1f<\/li>\n<\/ol>\n<p>\u5728\u8fdb\u884c\u6cdb\u764c\u5dee\u5f02\u5206\u6790\u4e4b\u524d\uff0c\u5c0f\u679c\u60f3\u5e26\u7740\u5927\u5bb6\u8fdb\u884c\u4e86\u89e3\u4e00\u4e0b\u4f55\u4e3a\u6cdb\u764c\uff1f\u6cdb\u764c\u5c31\u662f\u5728\u7814\u7a76\u5f53\u4e0b\u7684\u764c\u79cd\u540e\uff0c\u5728\u6269\u5927\u5230\u5176\u4ed6\u764c\u79cd\uff0c\u53ef\u4ee5\u662f\u6240\u6709\u80bf\u7624\u7684\u5927\u6cdb\u764c\uff0c\u4e5f\u53ef\u4ee5\u662f\u547c\u5438\u7cfb\u7edf\uff0c\u6d88\u5316\u7cfb\u7edf\u7684\u5c0f\u6cdb\u764c\u5965\uff01\u5c0f\u679c\u7684\u89e3\u91ca\u8fd8\u7b97\u7b80\u5355\u6613\u61c2\u5427\uff01<\/p>\n<p>\u63a5\u4e0b\u6765\u5c0f\u679c\u4e3a\u5c0f\u4f19\u4f34\u8bb2\u8bb2\u5982\u4f55\u505a\u6cdb\u764c\u5dee\u5f02\u5206\u6790\uff0c\u4e3b\u8981\u5305\u62ec\u6cdb\u764c\u8868\u8fbe\u77e9\u9635\u548c\u6837\u672c\u4fe1\u606f\u6587\u4ef6\u4e0b\u8f7d\uff0c\u6570\u636e\u5904\u7406\u83b7\u5f97\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e2d\u8868\u8fbe\u77e9\u9635\uff0c\u6700\u540e\u5229\u7528limma\u5305\u8fdb\u884c\u5dee\u5f02\u5206\u6790\uff0c\u83b7\u5f97\u5dee\u5f02\u5206\u6790\u7ed3\u679c\u6587\u4ef6\uff0c\u8fd9\u5c31\u662f\u57fa\u672c\u7684\u5206\u6790\u6d41\u7a0b\u5566\u3002<\/p>\n<ol>\n<li>\u9700\u8981\u7684R\u5305<\/li>\n<\/ol>\n<p>\u672c\u6b21\u5206\u6790\u9700\u8981\u7684R\u5305\u6700\u4e3b\u8981\u7684\u662flimma\u5305\u8fdb\u884c\u5dee\u5f02\u5206\u6790\uff0c\u6e29\u99a8\u63d0\u793a\uff0c\u9700\u8981\u6ce8\u610f\u7684\u662f\u5728\u52a0\u8f7dR\u5305\u65f6\uff0c\u5343\u4e07\u4e0d\u8981\u5fd8\u8bb0\u52a0\u8f7dtwoclasslimma.R\u811a\u672c\uff0c\u5426\u5219\u4f1a\u9047\u5230\u62a5\u9519\u5965\uff01\uff0c\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u8fdb\u884c\u5b89\u88c5\uff0c\u5c0f\u679c\u5df2\u7ecf\u5c1d\u8bd5\u8fc7\u7684\u5965\uff01<\/p>\n<p>#\u5b89\u88c5\u9700\u8981\u7684R\u5305<\/p>\n<p>install.packages(\u201cggplot2\u201d)<\/p>\n<p>install.packages(\u201cdata.table\u201d)<\/p>\n<p>BiocManager::install(\u201cimpute\u201d)<\/p>\n<p>BiocManager::install(\u201climma\u201d)<\/p>\n<p>install.packages(\u201ctidyverse\u201d)<\/p>\n<p>install.packages(\u201cggpubr\u201d)<\/p>\n<p>#\u5bfc\u5165\u9700\u8981\u7684R\u5305<\/p>\n<p>library(ggplot2)<\/p>\n<p>library(tidyverse)<\/p>\n<p>library(impute)<\/p>\n<p>library(limma)<\/p>\n<p>library(ggpubr)<\/p>\n<p>source(\u201ctwoclasslimma.R\u201d)<\/p>\n<ol>\n<li>\u6570\u636e\u4e0b\u8f7d<\/li>\n<\/ol>\n<p>\u5728\u505a\u6cdb\u764c\u5206\u6790\u4e4b\u524d\uff0c\u6700\u91cd\u8981\u7684\u95ee\u9898\u662f\u6cdb\u764c\u57fa\u56e0\u8868\u8fbe\u77e9\u9635\u548c\u6837\u672c\u4fe1\u606f\u4e0b\u8f7d\uff0c\u5c0f\u679c\u6240\u7528\u7684\u6cdb\u764c\u6570\u636e\u662f\u6765\u81ea\u8be5\u7f51\u7ad9<a href=\"https:\/\/gdc.cancer.gov\/about-data\/publications\/pancanatlas\">https:\/\/gdc.cancer.gov\/about-data\/publications\/pancanatlas<\/a>\uff0c\u53ea\u9700\u8981\u767b\u5f55\u8be5\u7f51\u7ad9\u5c31\u53ef\u4ee5\u5f88\u65b9\u4fbf\u7684\u4e0b\u8f7d\u5230\u81ea\u5df1\u60f3\u8981\u7684\u6587\u4ef6\u5965\uff0c\u7531\u4e8e\u6cdb\u764c\u57fa\u56e0\u8868\u8fbe\u77e9\u9635\u6587\u4ef6\u8f83\u5927\uff0c\u4e0b\u8f7d\u4f1a\u6709\u70b9\u6162\uff0c\u6709\u9700\u8981\u7684\u53ef\u4ee5call \u5c0f\u679c\u54c8\u3002\u3002\u3002\u3002<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"640\" height=\"222\" class=\"wp-image-30358\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409113009.jpeg?resize=640%2C222\" alt=\"Dingtalk_20230409113009\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409113009.jpeg?w=1268 1268w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409113009.jpeg?resize=300%2C104 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409113009.jpeg?resize=1024%2C355 1024w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409113009.jpeg?resize=768%2C266 768w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409113009.jpeg?resize=600%2C208 600w\" sizes=\"(max-width: 640px) 100vw, 640px\" data-recalc-dims=\"1\" \/><\/p>\n<p>#\u6cdb\u764c\u6837\u672c\u4fe1\u606f\u6587\u4ef6,\u4e3b\u8981\u5305\u62ec\u6837\u672c\u540d\u548c\u80bf\u7624\u7ec4\u7ec7\u7c7b\u578b\uff0c\u5176\u4ed6\u5217\u53ef\u4ee5\u5ffd\u7565\u5965\uff01<\/p>\n<p>merged_sample_quality_annotations.tsv<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"640\" height=\"183\" class=\"wp-image-30359\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101043.jpeg?resize=640%2C183\" alt=\"Dingtalk_20230409101043\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101043.jpeg?w=1267 1267w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101043.jpeg?resize=300%2C86 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101043.jpeg?resize=1024%2C293 1024w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101043.jpeg?resize=768%2C219 768w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101043.jpeg?resize=600%2C171 600w\" sizes=\"(max-width: 640px) 100vw, 640px\" data-recalc-dims=\"1\" \/><\/p>\n<p>#\u6cdb\u764c\u57fa\u56e0\u8868\u8fbe\u77e9\u9635\u6587\u4ef6\uff0c\u884c\u540d\u4e3a\u57fa\u56e0\u540d\uff0c\u5217\u540d\u4e3a\u6837\u672c\u540d\uff0c\u8ba4\u771f\u7684\u5c0f\u4f19\u4f34\u4f1a\u53d1\u73b0\u57fa\u56e0\u540d\u4e0d\u662f\u6211\u4eec\u9700\u8981\u7684\u5965\uff0c\u4e0b\u9762\u7684\u5206\u6790\u4e2d\u4f1a\u8fdb\u884c\u8f6c\u5316\u64cd\u4f5c\u5965\uff0c\u53ef\u4ee5\u91cd\u70b9\u5173\u6ce8\u5965\uff01<\/p>\n<p>EBPlusPlusAdjustPANCAN_IlluminaHiSeq_RNASeqV2.geneExp.tsv<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"640\" height=\"117\" class=\"wp-image-30360\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101458.jpeg?resize=640%2C117\" alt=\"Dingtalk_20230409101458\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101458.jpeg?w=1268 1268w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101458.jpeg?resize=300%2C55 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101458.jpeg?resize=1024%2C187 1024w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101458.jpeg?resize=768%2C140 768w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409101458.jpeg?resize=600%2C109 600w\" sizes=\"(max-width: 640px) 100vw, 640px\" data-recalc-dims=\"1\" \/><\/p>\n<ol>\n<li>\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e2d\u5dee\u5f02\u5206\u6790<\/li>\n<\/ol>\n<p>\u5728\u6210\u529f\u7684\u4e0b\u8f7d\u5230\u6570\u636e\u540e\uff0c\u5c31\u8981\u8fdb\u5165\u5230\u6700\u4e3b\u8981\u7684\u73af\u8282\u4e86\uff0c\u8fdb\u884c\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e2d\u5dee\u5f02\u5206\u6790\u7684\u5de5\u4f5c\u4e86\uff0c\u9996\u5148\u51c6\u5907\u611f\u5174\u8da3\u7684\u80bf\u7624\u540d\u79f0\u548c\u611f\u5174\u8da3\u7684\u57fa\u56e0\u540d\u79f0\uff0c\u7136\u540e\u63d0\u53d6\u611f\u5174\u8da3\u57fa\u56e0\u96c6\u5728\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e2d\u7684\u8868\u8fbe\u77e9\u9635\u6587\u4ef6\uff0c\u7136\u540e\u5229\u7528limma\u8f6f\u4ef6\u8fdb\u884c\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u5dee\u5f02\u5206\u6790\uff0c\u83b7\u5f97\u5dee\u5f02\u5206\u6790\u7ed3\u679c\u6587\u4ef6\uff0c\u8be5\u5206\u6790\u4e2d\u5305\u542b\u5927\u91cf\u7684\u6570\u636e\u5904\u7406\u6280\u5de7\uff0c\u5c0f\u679c\u5f3a\u70c8\u63a8\u4ecb\u8ba4\u771f\u5728\u8ba4\u771f\u9605\u8bfb\u5965\u3002<\/p>\n<p># \u611f\u5174\u8da3\u7684\u80bf\u7624\u540d\u79f0<\/p>\n<p>tumors &lt;- c(&#8220;BLCA&#8221;,&#8221;BRCA&#8221;,&#8221;CESC&#8221;,&#8221;CHOL&#8221;,&#8221;COAD&#8221;,<\/p>\n<p>&#8220;ESCA&#8221;,&#8221;GBM&#8221;,&#8221;HNSC&#8221;,&#8221;KICH&#8221;,&#8221;KIRC&#8221;,<\/p>\n<p>&#8220;KIRP&#8221;,&#8221;LIHC&#8221;,&#8221;LUAD&#8221;,&#8221;LUSC&#8221;,&#8221;PAAD&#8221;,<\/p>\n<p>&#8220;PRAD&#8221;,&#8221;READ&#8221;,&#8221;STAD&#8221;,&#8221;THCA&#8221;,&#8221;UCEC&#8221;)<\/p>\n<p>#\u611f\u5174\u8da3\u7684\u57fa\u56e0\u540d\u79f0<\/p>\n<p>Gene&lt;- c(&#8220;CDKN1A&#8221;,&#8221;HSPA5&#8243;,&#8221;TTC35&#8243;,&#8221;SLC7A11&#8243;,&#8221;NFE2L2&#8243;,&#8221;MT1G&#8221;,&#8221;HSPB1&#8243;,&#8221;GPX4&#8243;,&#8221;FANCD2&#8243;,&#8221;CISD1&#8243;,&#8221;FDFT1&#8243;,&#8221;SLC1A5&#8243;,&#8221;SAT1&#8243;,&#8221;TFRC&#8221;,&#8221;RPL8&#8243;,&#8221;NCOA4&#8243;,&#8221;LPCAT3&#8243;,&#8221;GLS2&#8243;,&#8221;DPP4&#8243;,&#8221;CS&#8221;,&#8221;CARS&#8221;,&#8221;ATP5G3&#8243;,&#8221;ALOX15&#8243;,&#8221;ACSL4&#8243;,&#8221;EMC2&#8243;)<\/p>\n<p>#\u5904\u7406\u548c\u7b80\u5316\u6837\u672c\u4fe1\u606f\u6587\u4ef6(\u6b64\u5904\u5f00\u59cb\u6536\u8d39)<\/p>\n<p>anno&lt;-read.delim(&#8220;merged_sample_quality_annotations.tsv&#8221;,sep=&#8221;\\t&#8221;,row.names=NULL,check.names = F,stringsAsFactors = F,header = T)<\/p>\n<p>#\u63d0\u53d6aliquot_barcode\u76841-15\u4e2a\u5b57\u7b26\u4e32<\/p>\n<p>anno$simple_barcode &lt;- substr(anno$aliquot_barcode,1,15)<\/p>\n<p>#\u63d0\u53d6cancer_type\u548csimple_barcode\u4e24\u5217<\/p>\n<p>samAnno &lt;- anno[!duplicated(anno$simple_barcode),c(&#8220;cancer type&#8221;, &#8220;simple_barcode&#8221;)]<\/p>\n<p>#\u4fdd\u7559\u6709cancer type\u4e0d\u4e3a\u7a7a\u7684\u6837\u672c<\/p>\n<p>samAnno &lt;- samAnno[which(samAnno$`cancer type` != &#8220;&#8221;),]<\/p>\n<p>#\u4fdd\u5b58\u7b80\u5316\u540e\u7684\u6837\u672c\u4fe1\u606f\u6587\u4ef6<\/p>\n<p>write.table(samAnno,&#8221;simple_sample_annotation.txt&#8221;,sep = &#8220;\\t&#8221;,row.names = F,col.names = T,quote = F)<\/p>\n<p>#\u8868\u8fbe\u77e9\u9635\u6587\u4ef6\u5904\u7406<\/p>\n<p>expr&lt;-fread(&#8220;EBPlusPlusAdjustPANCAN_IlluminaHiSeq_RNASeqV2.geneExp.tsv&#8221;,sep= &#8220;\\t&#8221;,stringsAsFactors = F,check.names = F,header = T)<\/p>\n<p>#\u5c06\u6570\u636e\u8f6c\u5316\u4e3a\u6570\u636e\u6846\u683c\u5f0f<\/p>\n<p>expr &lt;- as.data.frame(expr)<\/p>\n<p>#\u7b2c\u4e00\u5217\u4f5c\u4e3a\u884c\u540d<\/p>\n<p>rownames(expr) &lt;- expr[,1]<\/p>\n<p>#\u5220\u9664\u7b2c\u4e00\u5217<\/p>\n<p>expr &lt;- expr[,-1]<\/p>\n<p>#\u5bf9\u884c\u540d\u901a\u8fc7\u201c|\u201d\u6765\u5206\u5272\u5e76\u4fdd\u5b58\u7b2c\u4e00\u4e2a\u5206\u5272\u53d8\u91cf<\/p>\n<p>gene &lt;- sapply(strsplit(rownames(expr),&#8221;|&#8221;,fixed = T), &#8220;[&#8220;,1)<\/p>\n<p>expr$gene &lt;- gene<\/p>\n<p># \u79fb\u9664\u91cd\u590d\u6837\u672c<\/p>\n<p>expr &lt;- expr[!duplicated(expr$gene),] # \u79fb\u9664\u91cd\u590d\u6837\u672c<\/p>\n<p>rownames(expr) &lt;- expr$gene;<\/p>\n<p>#\u5220\u9664\u6700\u540e\u4e00\u5217<\/p>\n<p>expr &lt;- expr[,-ncol(expr)]<\/p>\n<p>#\u63d0\u53d6\u611f\u5174\u8da3\u57fa\u56e0\u96c6\u7684\u8868\u8fbe\u77e9\u9635\u6587\u4ef6<\/p>\n<p>comgene &lt;- intersect(rownames(expr),Gene)<\/p>\n<p>expr_sub &lt;- expr[comgene,]<\/p>\n<p>colnames(expr_sub) &lt;- substr(colnames(expr_sub),1,15)<\/p>\n<p>expr_sub &lt;- expr_sub[,!duplicated(colnames(expr_sub))]<\/p>\n<p>#\u901a\u8fc7\u5faa\u73af\u7684\u65b9\u5f0f\u8fdb\u884c\u6bcf\u79cd\u80bf\u7624\u7684\u5dee\u5f02\u5206\u6790<\/p>\n<p>exprTab &lt;- ndegs &lt;- NULL<\/p>\n<p># \u8bbe\u7f6e\u5dee\u5f02\u8868\u8fbe\u7684\u9608\u503c<\/p>\n<p>log2fc.cutoff &lt;- log2(1.5)<\/p>\n<p>fdr.cutoff &lt;- 0.05<\/p>\n<p>for (i in tumors) {<\/p>\n<p>message(&#8220;&#8211;&#8220;,i,&#8221;&#8230;&#8221;)<\/p>\n<p>#\u83b7\u53d6\u76f8\u5e94\u80bf\u7624\u7684\u6837\u672c\u4fe1\u606f\u6587\u4ef6<\/p>\n<p>sam &lt;- samAnno[which(samAnno$`cancer type` == i),&#8221;simple_barcode&#8221;]<\/p>\n<p>comsam &lt;- intersect(colnames(expr_sub), sam)<\/p>\n<p># \u83b7\u5f97\u80bf\u7624\u6837\u672c<\/p>\n<p>tumsam &lt;- comsam[substr(comsam,14,14) == &#8220;0&#8221;]<\/p>\n<p>#\u83b7\u5f97\u6b63\u5e38\u6837\u672c<\/p>\n<p>norsam &lt;- comsam[substr(comsam,14,14) == &#8220;1&#8221;]<\/p>\n<p>#\u83b7\u5f97\u5bf9\u5e94\u7684\u80bf\u7624\u548c\u6b63\u5e38\u7ec4\u7ec7\u8868\u8fbe\u77e9\u9635\u6587\u4ef6<\/p>\n<p>expr_subset &lt;- expr_sub[,c(tumsam,norsam)]<\/p>\n<p>expr_subset[expr_subset &lt; 0] &lt;- 0<\/p>\n<p>expr_subset &lt;- as.data.frame(impute.knn(as.matrix(expr_subset))$data)<\/p>\n<p>write.table(expr_subset, paste0(&#8220;TCGA_&#8221;,i,&#8221;_expr_subset.txt&#8221;),sep = &#8220;\\t&#8221;,row.names = T,col.names = NA,quote = F)<\/p>\n<p>subt &lt;- data.frame(condition = rep(c(&#8220;tumor&#8221;,&#8221;normal&#8221;),c(length(tumsam),length(norsam))),<\/p>\n<p>row.names = colnames(expr_subset),<\/p>\n<p>stringsAsFactors = F)<\/p>\n<p>twoclasslimma(subtype = subt, # \u4e9a\u578b\u5206\u7ec4\u4fe1\u606f<\/p>\n<p>featmat = expr_subset, # \u8868\u8fbe\u77e9\u9635\u6587\u4ef6<\/p>\n<p>treatVar = &#8220;tumor&#8221;, # \u201c\u6cbb\u7597\u7ec4\u201d\u7684\u540d\uff08\u6bd4\u8f83\u7684\u7ec4\uff09<\/p>\n<p>ctrlVar = &#8220;normal&#8221;, # \u201c\u5bf9\u7167\u7ec4\u201d\u7684\u540d\uff08\u88ab\u6bd4\u8f83\u7684\u7ec4\uff09<\/p>\n<p>prefix = paste0(&#8220;TCGA_&#8221;,i), # \u5dee\u5f02\u8868\u8fbe\u7684\u6587\u4ef6\u7684\u524d\u7f00<\/p>\n<p>overwt = T, # \u662f\u5426\u8986\u76d6\u5df2\u7ecf\u5b58\u5728\u7684\u5dee\u5f02\u8868\u8fbe\u6587\u4ef6<\/p>\n<p>sort.p = F, # \u662f\u5426\u6392\u5e8fp\u503c<\/p>\n<p>verbose = TRUE, # \u662f\u5426\u7b80\u5316\u8f93\u51fa<\/p>\n<p>res.path = &#8220;.&#8221;) # \u8f93\u51fa\u7ed3\u679c\u8def\u5f84<\/p>\n<p># \u52a0\u8f7d\u5dee\u5f02\u8868\u8fbe\u6587\u4ef6<\/p>\n<p>res&lt;-read.table(paste0(&#8220;TCGA_&#8221;,i,&#8221;_limma_test_result.tumor_vs_normal.txt&#8221;),sep = &#8220;\\t&#8221;,row.names = 1,check.names = F,stringsAsFactors = F,header = T)<\/p>\n<p>#\u5224\u65ad\u4e0a\u8c03\u548c\u4e0b\u8c03\u57fa\u56e0<\/p>\n<p>upgene &lt;- res[which(res$log2fc &gt; log2fc.cutoff &amp; res$padj &lt; fdr.cutoff),]<\/p>\n<p>dngene &lt;- res[which(res$log2fc &lt; -log2fc.cutoff &amp; res$padj &lt; fdr.cutoff),]<\/p>\n<p># \u57fa\u56e0\u5dee\u5f02\u8868\u8fbe\u7684\u6570\u76ee<\/p>\n<p>if(nrow(upgene) &gt; 0) {<\/p>\n<p>nup &lt;- nrow(upgene)<\/p>\n<p>} else {nup &lt;- 0}<\/p>\n<p>if(nrow(dngene) &gt; 0) {<\/p>\n<p>ndn &lt;- nrow(dngene)<\/p>\n<p>} else {ndn &lt;- 0}<\/p>\n<p>#\u5408\u5e76\u6bcf\u79cd\u80bf\u7624\u7684\u5dee\u5f02\u5206\u6790\u7ed3\u679c\uff0c\u5e76\u8f6c\u5316\u4e3a\u6570\u636e\u6846<\/p>\n<p>exprTab &lt;- rbind.data.frame(exprTab,<\/p>\n<p>data.frame(gene = rownames(res),<\/p>\n<p>log2fc = res$log2fc,<\/p>\n<p>FDR = res$padj,<\/p>\n<p>tumor = i,<\/p>\n<p>stringsAsFactors = F),<\/p>\n<p>stringsAsFactors = F)<\/p>\n<p>#\u5408\u5e76\u6bcf\u79cd\u80bf\u7624\u7684\u5dee\u5f02\u57fa\u56e0\u4e0a\u4e0b\u8c03\u6570\u76ee\u7ed3\u679c\uff0c\u5e76\u8f6c\u5316\u4e3a\u6570\u636e\u6846<\/p>\n<p>ndegs &lt;- rbind.data.frame(ndegs,<\/p>\n<p>data.frame(tumor = i,<\/p>\n<p>Group = c(&#8220;UP&#8221;,&#8221;DOWN&#8221;),<\/p>\n<p>Number = c(nup,ndn),<\/p>\n<p>stringsAsFactors = F),<\/p>\n<p>stringsAsFactors = F)<\/p>\n<p>}<\/p>\n<ol>\n<li>\u7ed8\u5236\u5dee\u5f02\u57fa\u56e0\u5806\u53e0\u67f1\u72b6\u56fe\u548c\u57fa\u56e0\u8868\u8fbe\u91cf\u6c14\u6ce1\u56fe<\/li>\n<\/ol>\n<p>#\u7ed8\u5236\u5dee\u5f02\u57fa\u56e0\u6570\u76ee\u5806\u53e0\u67f1\u72b6\u56fe<\/p>\n<p>top &lt;- ggplot(data = ndegs) +<\/p>\n<p>geom_bar(mapping = aes(x = tumor, y = Number, fill = Group),<\/p>\n<p>stat = &#8216;identity&#8217;,position = &#8216;stack&#8217;) +<\/p>\n<p>scale_fill_manual(values = c(orange,green)) +<\/p>\n<p>theme_classic() +<\/p>\n<p>theme(axis.text.x = element_blank(),<\/p>\n<p>axis.title.x = element_blank(),<\/p>\n<p>plot.margin = unit(c(1,0,0,1), &#8220;lines&#8221;))<\/p>\n<p># \u7ed8\u5236\u6ce1\u6ce1\u56fe<\/p>\n<p>#\u786e\u5b9a\u7ed8\u56fe\u57fa\u56e0\u7684\u56e0\u5b50\u987a\u5e8f<\/p>\n<p>exprTab$gene&lt;-factor(exprTab$gene, levels=rev(c(&#8220;CDKN1A&#8221;,&#8221;HSPA5&#8243;,&#8221;TTC35&#8243;,&#8221;SLC7A11&#8243;,&#8221;NFE2L2&#8243;,&#8221;MT1G&#8221;,&#8221;HSPB1&#8243;,&#8221;GPX4&#8243;,&#8221;FANCD2&#8243;,&#8221;CISD1&#8243;, &#8220;FDFT1&#8243;,&#8221;SLC1A5&#8243;,&#8221;SAT1&#8243;,&#8221;TFRC&#8221;,&#8221;RPL8&#8243;,&#8221;NCOA4&#8243;,&#8221;LPCAT3&#8243;,&#8221;GLS2&#8243;,&#8221;DPP4&#8243;,&#8221;CS&#8221;,&#8221;CARS&#8221;,&#8221;ATP5G3&#8243;,&#8221;ALOX15&#8243;,&#8221;ACSL4&#8243;)))<\/p>\n<p>#\u8bbe\u7f6e\u6e10\u53d8\u8272<\/p>\n<p>my_palette &lt;- colorRampPalette(c(green,&#8221;white&#8221;,orange), alpha=TRUE)(n=128)<\/p>\n<p>center &lt;- ggplot(exprTab, aes(x=tumor,y=gene)) +<\/p>\n<p>geom_point(aes(size=-log10(FDR),color=log2fc)) +<\/p>\n<p>scale_color_gradientn(&#8216;log2(FC)&#8217;,<\/p>\n<p>colors=my_palette) +<\/p>\n<p>theme_bw() +<\/p>\n<p>#\u4fee\u6539\u4e3b\u9898<\/p>\n<p>theme(axis.text.x = element_text(angle = 45, size = 12, hjust = 0.3, vjust = 0.5, color = &#8220;black&#8221;),<\/p>\n<p>axis.text.y = element_text(size = 12, color = rep(c(red,blue),c(14,10))),<\/p>\n<p>axis.title = element_blank(),<\/p>\n<p>panel.border = element_rect(size = 0.7, linetype = &#8220;solid&#8221;, colour = &#8220;black&#8221;),<\/p>\n<p>plot.margin = unit(c(0,0,1,1), &#8220;lines&#8221;))<\/p>\n<p>#\u5229\u7528ggpubr\u4e2d\u7684ggrange\u51fd\u6570\u8fdb\u884c\u62fc\u56fe<\/p>\n<p>ggarrange(top,<\/p>\n<p>center,<\/p>\n<p>nrow = 2, ncol = 1,#\u6392\u5217\u65b9\u5f0f\u4e24\u884c\u4e09\u5217<\/p>\n<p>align = &#8220;v&#8221;, #\u6392\u5217\u65b9\u5411<\/p>\n<p>heights = c(2,6),#\u4e24\u5f20\u56fe\u7247\u7684\u5927\u5c0f\u6bd4\u4f8b<\/p>\n<p>common.legend = F)#\u5bf9\u56fe\u4f8b\u4e0d\u8fdb\u884c\u5408\u5e76<\/p>\n<p>#\u4fdd\u5b58\u56fe\u7247<\/p>\n<p>ggsave(\u201cdifferention_expression_pancancer.pdf\u201d,heigth=8,weight=8)<\/p>\n<ol>\n<li>\u7ed3\u679c\u6587\u4ef6\u89e3\u8bfb<\/li>\n<li>differential_expression_of_interested_genes_in_pancancer.pdf<\/li>\n<\/ol>\n<p>\u8be5\u56fe\u4e3a\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e2d\u5dee\u5f02\u57fa\u56e0\u5806\u53e0\u67f1\u72b6\u56fe\u548c\u4e0d\u540c\u80bf\u7624\u7ec4\u7ec7\u4e2d\u76ee\u6807\u57fa\u56e0\u8868\u8fbe\u91cf\u6c14\u6ce1\u56fe\u7ec4\u5408\u56fe<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"608\" height=\"596\" class=\"wp-image-30361\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409102205.jpeg?resize=608%2C596\" alt=\"Dingtalk_20230409102205\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409102205.jpeg?w=608 608w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409102205.jpeg?resize=300%2C294 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409102205.jpeg?resize=600%2C588 600w\" sizes=\"(max-width: 608px) 100vw, 608px\" data-recalc-dims=\"1\" \/><\/p>\n<ol>\n<li>TCGA_BLCA_limma_test_result.tumor_vs_normal.txt<\/li>\n<\/ol>\n<p>\u8be5\u6587\u4ef6\u4e3a\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u76f8\u5e94\u7684\u80bf\u7624\u7ec4\u7ec7\u4e2d\u7684limma\u5dee\u5f02\u5206\u6790\u7ed3\u679c<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"640\" height=\"170\" class=\"wp-image-30362\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120207.jpeg?resize=640%2C170\" alt=\"Dingtalk_20230409120207\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120207.jpeg?w=1267 1267w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120207.jpeg?resize=300%2C80 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120207.jpeg?resize=1024%2C272 1024w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120207.jpeg?resize=768%2C204 768w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120207.jpeg?resize=600%2C159 600w\" sizes=\"(max-width: 640px) 100vw, 640px\" data-recalc-dims=\"1\" \/><\/p>\n<ol>\n<li>TCGA_BLCA_expr_subset.txt<\/li>\n<\/ol>\n<p>\u8be5\u6587\u4ef6\u4e3a\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u80bf\u7624\u7ec4\u7ec7\u4e2d\u7684\u8868\u8fbe\u77e9\u9635\u6587\u4ef6<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"640\" height=\"159\" class=\"wp-image-30363\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120631.jpeg?resize=640%2C159\" alt=\"Dingtalk_20230409120631\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120631.jpeg?w=1267 1267w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120631.jpeg?resize=300%2C74 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120631.jpeg?resize=1024%2C254 1024w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120631.jpeg?resize=768%2C190 768w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120631.jpeg?resize=600%2C149 600w\" sizes=\"(max-width: 640px) 100vw, 640px\" data-recalc-dims=\"1\" \/><\/p>\n<ol>\n<li>simple_sample_annotation.txt<\/li>\n<\/ol>\n<p>\u8be5\u6587\u4ef6\u4e3a\u7b80\u5316\u7684\u6837\u672c\u4fe1\u606f\u6587\u4ef6\uff0c\u7b2c\u4e00\u5217\u4e3a\u80bf\u7624\u7c7b\u578b\uff0c\u7b2c\u4e8c\u5217\u4e3a\u5bf9\u5e94\u7684\u6837\u672c\u540d<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" width=\"640\" height=\"162\" class=\"wp-image-30364\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120903.jpeg?resize=640%2C162\" alt=\"Dingtalk_20230409120903\" srcset=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120903.jpeg?w=1265 1265w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120903.jpeg?resize=300%2C76 300w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120903.jpeg?resize=1024%2C259 1024w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120903.jpeg?resize=768%2C194 768w, https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2024\/02\/dingtalk_20230409120903.jpeg?resize=600%2C152 600w\" sizes=\"(max-width: 640px) 100vw, 640px\" data-recalc-dims=\"1\" \/><\/p>\n<p>\u6700\u7ec8\u5c0f\u679c\u4ece\u6570\u636e\u4e0b\u8f7d\uff0c\u5dee\u5f02\u5206\u6790\u548c\u7ed8\u56fe\uff0c\u5b8c\u6210\u4e86\u94c1\u6b7b\u4ea1\u76f8\u5173\u57fa\u56e0\u5728\u6cdb\u764c\u548c\u6b63\u5e38\u7ec4\u7ec7\u7684\u5dee\u5f02\u5206\u6790\uff1b\u6cdb\u764c\u76f8\u5173\u7684\u5206\u6790\u90fd\u53ef\u4ee5\u7528\u672c\u516c\u53f8\u65b0\u5f00\u53d1\u7684\u4e91\u5e73\u53f0\u751f\u7269\u4fe1\u606f\u5206\u6790\u5c0f\u5de5\u5177\u5b9e\u73b0\u5965\uff0c\u96f6\u4ee3\u7801\u5b8c\u6210\u5206\u6790\uff0c\u6b22\u8fce\u5c0f\u4f19\u4f34\u6765\u5c1d\u8bd5\u5965\uff0c\u4e91\u5e73\u53f0\u7f51\u5740\uff1ahttp:\/\/www.biocloudservice.com\/home.html\uff0c\u4f8b\u5982\u57fa\u56e0\u5728\u80bf\u7624\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u4e2d\u7684\u7532\u57fa\u5316\u5206\u6790(http:\/\/www.biocloudservice.com\/771\/771.php)\uff0c\u6cdb\u764c\u4e2d\u7279\u5b9a\u901a\u8def\u57fa\u56e0\u7684\u7a81\u53d8\u5206\u6790(http:\/\/www.biocloudservice.com\/740\/740.php)\uff0c\u6cdb\u764c\u4e2d\u62f7\u8d1d\u6570\u53d8\u5f02\u5206\u6790(http:\/\/www.biocloudservice.com\/700\/700.php)\u7b49\u5c0f\u5de5\u5177\uff1b\u6b22\u8fce\u5927\u5bb6\u548c\u5c0f\u679c\u4e00\u8d77\u8ba8\u8bba\u5b66\u4e60\u5965\uff0c\u4e0b\u671f\u518d\u89c1\u5965\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u70ed\u70b9\u7ec8\u7ed3\u8005\uff1f\u6cdb\u764c-\u76ee\u6807\u57fa\u56e0\u96c6\u5728\u80bf\u7624\u7ec4\u7ec7\u4e0e\u6b63\u5e38\u7ec4\u7ec7\u7684\u5dee\u5f02\u5206\u6790 \u8fd1\u5e74\u6765\uff0c\u591a\u7ef4\u7ec4\u5b66\u8054\u5408\u5206\u6790\u6210\u4e3a\u5927\u8d8b\u52bf\uff0c\u7ecf\u5e38\u51fa\u73b0\u5728\u9ad8\u5206 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":""},"categories":[1],"tags":[],"jetpack_featured_media_url":"","_links":{"self":[{"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/30357"}],"collection":[{"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=30357"}],"version-history":[{"count":1,"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/30357\/revisions"}],"predecessor-version":[{"id":30365,"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/30357\/revisions\/30365"}],"wp:attachment":[{"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=30357"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=30357"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.biocloudservice.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=30357"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}