{"id":558,"date":"2023-04-01T14:49:50","date_gmt":"2023-04-01T05:49:50","guid":{"rendered":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/?p=558"},"modified":"2023-04-01T14:50:42","modified_gmt":"2023-04-01T05:50:42","slug":"post-558","status":"publish","type":"post","link":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/archives\/558","title":{"rendered":"R\u3067\u30c7\u30fc\u30bf\u9023\u7d50"},"content":{"rendered":"<p>\u6b21\u306e\u3088\u3046\u306a\u30c7\u30fc\u30bf\u304c\u3042\u3063\u3066\u3001\u540c\u3058\u907a\u4f1d\u5b50(1\u5217\u76ee)\u306e\u30c7\u30fc\u30bf\u3092\u9023\u7d50\u3057\u305f\u3044(\u6a2a\u306b\u4e26\u3079\u305f\u3044)\u3068\u3057\u307e\u3059\u3002<\/p>\n<h4>1\u3064\u76ee\u306e\u30c7\u30fc\u30bf<\/h4>\n<pre class=\"code\">logCPM\tlogFC\tPValue\tFDR\t\nAT5G07990.1\t6.502\t-0.955\t2.55E-13\t9.32E-09\nAT5G48880.1\t7.027\t-0.567\t1.18E-11\t2.15E-07\nAT5G48880.3\t6.990\t-0.545\t7.42E-11\t9.03E-07\nAT5G48880.2\t7.020\t-0.537\t1.26E-10\t1.15E-06\n(\u4ee5\u4e0b\u6570\u4e07\u884c)\n<\/pre>\n<h4>2\u3064\u76ee\u306e\u30c7\u30fc\u30bf<\/h4>\n<pre class=\"code\">logCPM\tlogFC\tPValue\tFDR\t\nAT5G58240.1\t4.668\t-1.552\t3.34E-30\t1.22E-25\nAT5G58240.2\t4.415\t-1.406\t2.56E-20\t4.68E-16\nAT5G22650.1\t7.769\t-0.926\t1.66E-15\t1.83E-11\nAT5G22650.2\t7.705\t-0.925\t2.00E-15\t1.83E-11\n(\u4ee5\u4e0b\u6570\u4e07\u884c)\n<\/pre>\n<h3>1\u5217\u76ee\u306e\u4e26\u3073\u9806\u304c\u7570\u306a\u308b\u3060\u3051\u306e\u5834\u5408<\/h3>\n<p>\u30c7\u30fc\u30bf\u306e\u5217\u540d\u3092rownames\u3067\u53d6\u308a\u51fa\u3057\u3066\u3001\u305d\u308c\u306e\u4e26\u3073\u9806\u3092order\u3067\u3064\u304f\u308a\u307e\u3059\u3002d1[order(rownames(d1)),]\u3068\u3059\u308b\u3053\u3068\u3067\u30011\u5217\u76ee\u306e\u9806\u306b\u4e26\u3079\u307e\u3059\u30022\u3064\u76ee\u306e\u30c7\u30fc\u30bf\u3082\u540c\u3058\u3088\u3046\u306b\u4e26\u3079\u66ff\u3048\u3066\u3001cbind\u3067\u9023\u7d50\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"code\">&gt; d1 &lt;- read.table(\"data1.txt\")\n&gt; d2 &lt;- read.table(\"data2.txt\")\n&gt; cbind(d1[order(rownames(d1)),], d2[order(rownames(d2)),])\n\tlogCPM\tlogFC\tPValue\tFDR\tlogCPM\tlogFC\tPValue\tFDR\nAT1G01010.1\t4.849\t-0.290\t0.077\t0.499\t4.849\t-0.109\t0.509\t1.000\nAT1G01020.1\t4.446\t-0.098\t0.553\t0.751\t4.446\t0.118\t0.459\t1.000\nAT1G01020.2\t4.154\t-0.109\t0.559\t0.755\t4.154\t0.094\t0.619\t1.000\nAT1G01030.1\t4.926\t-0.264\t0.104\t0.514\t4.926\t-0.040\t0.809\t1.000\n(\u4ee5\u4e0b\u6570\u4e07\u884c)\n<\/pre>\n<h3>\u884c\u6570\u304c\u7570\u306a\u308b\u5834\u5408<\/h3>\n<p>\u4e0a\u306e\u4f8b\u306e\u3088\u3046\u306b\u884c\u6570\u304c\u540c\u3058\u5834\u5408\u3067\u3082merge\u95a2\u6570\u3092\u4f7f\u3048\u3070\u3001\u30b3\u30fc\u30c9\u3082\u3088\u308a\u7c21\u5358\u306b\u306a\u308a\u307e\u3059\u3002\u3069\u306e\u5217\u306e\u5024\u3067\u9023\u7d50\u3059\u308b\u304b\u3092by\u306b\u4e0e\u3048\u307e\u3059\u3002\u4eca\u56de\u306f\u5217\u540d\u306a\u306e\u30670\u3067\u3059\u3002\u3069\u3061\u3089\u304b\u306b\u6b20\u640d\u5024\u304c\u3042\u308b\u5834\u5408\u306f\u3001all\u3092\u3064\u3051\u3066\u304a\u304f\u3068\u884c\u6570\u304c\u6e1b\u308a\u307e\u305b\u3093\u3002<\/p>\n<pre class=\"code\">&gt; merge(d1, d2, by = 0)\n\tRow.names\tlogCPM.x\tlogFC.x\tPValue.x\tFDR.x\tlogCPM.y\tlogFC.y\tPValue.y\tFDR.y\n1\tAT1G01010.1\t4.849\t-0.290\t0.077\t0.499\t4.849\t-0.109\t0.509\t1\n2\tAT1G01020.1\t4.446\t-0.098\t0.553\t0.751\t4.446\t0.118\t0.459\t1\n3\tAT1G01020.2\t4.154\t-0.109\t0.559\t0.755\t4.154\t0.094\t0.619\t1\n4\tAT1G01030.1\t4.926\t-0.264\t0.104\t0.514\t4.926\t-0.040\t0.809\t1\n(\u4ee5\u4e0b\u6570\u4e07\u884c)\n<\/pre>\n<p>2\u3064\u306e\u30d5\u30a1\u30a4\u30eb\u306a\u3089\u4e0a\u8a18\u3067\u6e08\u307f\u307e\u3059\u304c\u30013\u30644\u3064\u3068\u5897\u3048\u3066\u3044\u304f\u3068\u30b3\u30fc\u30c9\u3092\u66f8\u3044\u3066\u3044\u304f\u306e\u304c\u5927\u5909\u3067\u3059\u3002\u305d\u3053\u3067\u3001\u7e70\u308a\u8fd4\u3057\u306a\u3069\u3092\u4f7f\u3063\u3066\u697d\u3092\u3057\u3088\u3046\u3068\u601d\u3046\u306e\u3067\u3059\u304c\u3001\u6700\u521d\u306e\u51e6\u7406\u3060\u3051\u5225\u306b\u306a\u3063\u3066\u9762\u5012\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h4>\u4e00\u3064\u76ee\u3060\u3051\u5225\u306e\u51e6\u7406\u3092\u3057\u3066\u3044\u308b\u3042\u307e\u308a\u9762\u767d\u304f\u306a\u3044\u30b3\u30fc\u30c9<\/h4>\n<pre class=\"code\">files &lt;- list.files(path = \".\", pattern = \"*.txt\", full.names = TRUE)\nfor(file in files){\n\tbuf &lt;- read.table(file)\n\tif(file == files[1]){\n\t\td &lt;- buf\n\t}else{\n\t\td &lt;- merge(d, buf, by = 0)\n\t\t# merge\u3059\u308b\u3068\u884c\u306b\u3064\u3044\u305f\u540d\u524d\u304c1\u5217\u76ee\u306b\u306a\u3063\u3066\u3057\u307e\u3046\u306e\u3067\u3001\u3053\u308c\u3092\u884c\u540d\u306b\u623b\u3059\n\t\trownames(d) &lt;- d[,1]\n\t\td &lt;- d[, -1]\n\t}\n}\n<\/pre>\n<p>if(file == files[1]) \u3068\u3057\u3066\u30011\u3064\u76ee\u306e\u30c7\u30fc\u30bf\u3060\u3051\u5225\u306e\u51e6\u7406\u3092\u3057\u3066\u3044\u307e\u3059\u3002\u3044\u307e\u3044\u3061\u683c\u597d\u3088\u304f\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<h4>\u30a4\u30b1\u3066\u308b\u3068\u601d\u3046\u30b3\u30fc\u30c9<\/h4>\n<pre class=\"code\">data &lt;- lapply(files, read.table)\nd &lt;- Reduce(function (d1, d2){\n\td &lt;- merge(d1, d2, by = 0)\n\trownames(d) &lt;- d[,1]\n\td[, -1]\n}, data)\n<\/pre>\n<p>Reduce\u95a2\u6570\u3092\u4f7f\u3046\u3068\u540c\u3058\u578b\u306e\u30c7\u30fc\u30bf\u3092\u96c6\u7d04\u3057\u3066\u3044\u304f\u3053\u3068\u304c\u7c21\u5358\u306b\u3067\u304d\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6b21\u306e\u3088\u3046\u306a\u30c7\u30fc\u30bf\u304c\u3042\u3063\u3066\u3001\u540c\u3058\u907a\u4f1d\u5b50(1\u5217\u76ee)\u306e\u30c7\u30fc\u30bf\u3092\u9023\u7d50\u3057\u305f\u3044(\u6a2a\u306b\u4e26\u3079\u305f\u3044)\u3068\u3057\u307e\u3059\u3002 1\u3064\u76ee\u306e\u30c7\u30fc\u30bf logCPM logFC PValue FDR AT5G07990.1 6.502 -0.955 2.55E- [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,13,7],"tags":[],"_links":{"self":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts\/558"}],"collection":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/comments?post=558"}],"version-history":[{"count":12,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts\/558\/revisions"}],"predecessor-version":[{"id":1513,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/posts\/558\/revisions\/1513"}],"wp:attachment":[{"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/media?parent=558"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/categories?post=558"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/biochemistry.isc.chubu.ac.jp\/labo\/suzuki\/wp-json\/wp\/v2\/tags?post=558"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}