Repository 'w4mcorcov'
hg clone https://toolshed.g2.bx.psu.edu/repos/eschen42/w4mcorcov

Changeset 1:0c2ad44b6c9c (2017-10-22)
Previous changeset 0:23f9fad4edfc (2017-10-16) Next changeset 2:e03582f26617 (2017-11-12)
Commit message:
planemo upload for repository https://github.com/HegemanLab/w4mcorcov_galaxy_wrapper/tree/master commit 01d4a951cf09e7b88fcec96b8043bc7568cc5c92
modified:
w4mcorcov.xml
w4mcorcov_calc.R
w4mcorcov_wrapper.R
removed:
test-data/expected_contrast_corcov.tsv
test-data/expected_contrast_corcov_all.tsv
test-data/expected_contrast_corcov_global.tsv
test-data/expected_contrast_salience.tsv
test-data/input_dataMatrix.tsv
test-data/input_sampleMetadata.tsv
test-data/input_variableMetadata.tsv
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/expected_contrast_corcov.tsv
--- a/test-data/expected_contrast_corcov.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,643 +0,0 @@\n-featureID\tfactorLevel1\tfactorLevel2\tcorrelation\tcovariance\tvip4p\tvip4o\tlevel1Level2Sig\n-M200.005T296\tk1\tother\t-0.205568289258149\t-17.7677077386947\t0.607800774858881\t0.76895407082906\t0\n-M200.1286T209\tk1\tother\t-0.00170937109642714\t-0.0773130525978799\t0.00505407269126545\t0.611367438686349\t0\n-M200.1286T214\tk1\tother\t-0.182819068559282\t-6.2134875422604\t0.540538484463285\t0.421434534377586\t0\n-M200.8062T276\tk1\tother\t0.23979010255191\t15.4952138148085\t0.708983913134179\t0.485389578917022\t0\n-M201.7354T319\tk1\tother\t-0.481792701325989\t-325.295925848215\t1.42450948171074\t0.433545223368707\t1\n-M201.8009T418\tk1\tother\t0.106575042922809\t35.0560223480028\t0.315108881349675\t0.426724552480981\t0\n-M201.8011T348\tk1\tother\t0.143426230924376\t49.1654403193539\t0.424066253630452\t0.228931998243512\t0\n-M201.8013T369\tk1\tother\t0.254989702750156\t63.6248135583442\t0.753924350257912\t0.194937312445436\t0\n-M201.8014T535\tk1\tother\t0.0944741309478455\t45.4778981404852\t0.279330290685598\t0.582856629326936\t0\n-M201.8017T217\tk1\tother\t0.101717530673506\t34.4582873983144\t0.300746745440156\t1.07311456897249\t0\n-M201.8017T476\tk1\tother\t0.199969672076937\t114.883702224861\t0.591247424762137\t1.01692081090481\t0\n-M201.8022T437\tk1\tother\t0.0842976280350202\t37.1744799493247\t0.249241572342461\t0.410797455818058\t0\n-M202.95T726\tk1\tother\t0.210702017148315\t6.81745073534487\t0.622979593541557\t0.777986168109099\t0\n-M203.0345T357\tk1\tother\t-0.0487773685984231\t-0.260917897542442\t0.144219337217272\t0.239938898694363\t0\n-M203.7984T363\tk1\tother\t0.0697219696356168\t6.17022923991264\t0.206145934872274\t0.127434589842075\t0\n-M203.7989T238\tk1\tother\t0.134124235618366\t11.4295080245344\t0.396563179225689\t0.170076712079631\t0\n-M205.8387T251\tk1\tother\t0.228657014037888\t57.2088201018695\t0.676066872038906\t1.58747576053444\t0\n-M205.8387T276\tk1\tother\t0.0605703455198227\t13.5629527902119\t0.1790874607814\t1.39947140540822\t0\n-M205.8394T201\tk1\tother\t0.181446005672092\t44.3013867271896\t0.536478769369212\t1.55214077307789\t0\n-M205.8394T207\tk1\tother\t0.120171269694766\t45.9353074945554\t0.355308647553766\t1.38235363181598\t0\n-M205.8394T217\tk1\tother\t0.206958310885333\t87.5568462553266\t0.611910631613158\t1.47871140282086\t0\n-M205.8394T231\tk1\tother\t0.219847579856986\t77.0556962657189\t0.650020145958034\t1.48021330715316\t0\n-M205.8394T245\tk1\tother\t0.189436892632946\t91.0370377759351\t0.560105308774412\t1.52969317856787\t0\n-M205.8398T239\tk1\tother\t0.218200999587392\t65.8940487548431\t0.645151725992394\t1.01244902349355\t0\n-M205.8398T264\tk1\tother\t0.361875459606204\t115.320413237692\t1.0699519149807\t1.50376494338286\t0\n-M205.839T273\tk1\tother\t0.189783047252342\t67.1243847868486\t0.561128779109496\t1.45143192065427\t0\n-M205.8401T322\tk1\tother\t0.172463850511401\t63.3751627867724\t0.509921361676263\t1.05188886676183\t0\n-M206.8403T273\tk1\tother\t0.205152881234278\t11.9822134300559\t0.606572543988727\t1.50801968858745\t0\n-M207.0654T373\tk1\tother\t0.384869953141161\t663.104542272874\t1.13793940000804\t0.109766772892289\t1\n-M207.0661T267\tk1\tother\t0.348203365038172\t50.0913278193799\t1.02952783156598\t0.0792927417369285\t0\n-M207.066T243\tk1\tother\t0.400068427783187\t94.5702550214998\t1.18287650921605\t0.105071717614767\t1\n-M207.1386T512\tk1\tother\t0.230480061072539\t9.30232249295143\t0.681457048725515\t0.395070954149977\t1\n-M207.8358T251\tk1\tother\t0.254719287292824\t71.9307905007691\t0.753124816803148\t1.58920714209002\t0\n-M207.8364T207\tk1\tother\t0.117750045061351\t46.7033501101528\t0.348149847849746\t1.42201120547266\t0\n-M207.8364T217\tk1\tother\t0.174209185184267\t68.7316956045612\t0.515081767351597\t1.57490113794723\t0\n-M207.8364T245\tk1\tother\t0.182841250356576\t87.2963634796853\t0.540604069061143\t1.52619977648929\t0\n-M207.8365T363\tk1\tother\t0.154366234442276\t79.0690740225428\t0.456412403122352\t1.54539736459774\t0\n-M207.8366T347\tk1\tother\t0.206042031078707\t64.8364266906763\t0.609201480418366\t1.15958062567833\t0\n-M207.8368T238\tk1\tother\t0.137301689961093\t46.7913503211824\t0.405957912326586\t1.51731859590296\t0\n-M207.9308T206\tk1\tother\t0.119160334235501\t10.2386988391127\t0.352319629365741\t1.65509434499656\t0\n-M207.9308T302\tk1\tother\t0.36'..b'81213417\t1.31881922509655\t0.238702610193902\t1\n-M235.8222T811\tk2\tk4\t-0.419862472936769\t-213.286780859918\t0.841977797533003\t1.84355266672379\t1\n-M238.8458T327\tk2\tk4\t-0.388766561970513\t-98.8015309106935\t0.689975703879627\t2.33746218853341\t1\n-M239.0703T450\tk2\tk4\t-0.444329426272229\t-65.458162382295\t0.668849649407896\t0.228862337654552\t1\n-M239.201T299\tk2\tk4\t-0.269518543459184\t-92.5716819407354\t0.375409807663749\t0.582410470957545\t1\n-M241.0506T270\tk2\tk4\t-0.598205152445181\t-100.179361769108\t0.816613128780136\t0.5748412203162\t1\n-M246.9633T231\tk2\tk4\t0.472609652352313\t9.64434689545551\t0.971140196676872\t0.578266522123375\t1\n-M247.1344T557\tk2\tk4\t0.804179191598383\t317.607000873725\t1.12445763217619\t0.459904775204819\t1\n-M247.1344T570\tk2\tk4\t0.767981266498117\t364.620679512916\t1.06700273527911\t0.522940582146822\t1\n-M249.1135T417\tk2\tk4\t0.938630509387962\t2275.23578789038\t1.33155749336162\t0.246625223696433\t1\n-M249.1136T427\tk2\tk4\t0.602446660635499\t929.347093817965\t0.835396423933286\t0.60577302531685\t1\n-M249.1864T510\tk2\tk4\t-0.459908757700795\t-34.6574712856916\t0.669124659678931\t0.433232424914089\t1\n-M201.7354T319\tk3\tk4\t-0.590955339879674\t-398.077396560824\t0.883746539345165\t1.73212060677684\t1\n-M207.0654T373\tk3\tk4\t0.766729694912719\t1591.40204118615\t1.15980219810598\t0.0904081040256091\t1\n-M207.066T243\tk3\tk4\t0.876904526303748\t248.586721479467\t1.33191763888308\t0.202543754337869\t1\n-M207.1386T512\tk3\tk4\t0.780607822295535\t35.331918145187\t1.16791589522192\t0.0800724656792324\t1\n-M211.0388T319\tk3\tk4\t-0.649820608416486\t-403.11772387645\t0.974581289364068\t1.59671018121308\t1\n-M211.0395T228\tk3\tk4\t-0.693327019913806\t-172.562549792254\t1.038184463714\t0.427826152199363\t1\n-M211.0607T263\tk3\tk4\t0.474514542060655\t25.1107839851998\t0.736351724861224\t0.711751533830425\t1\n-M211.0755T367\tk3\tk4\t-0.739740723644087\t-412.280324332263\t1.13059720800918\t0.282221616971953\t1\n-M217.0506T407\tk3\tk4\t0.636543310232196\t126.968270493159\t0.957096221239158\t0.194191711154358\t1\n-M217.8836T288\tk3\tk4\t0.615821738055009\t57.3114514230521\t0.956589618774437\t1.41603034975564\t1\n-M221.0817T230\tk3\tk4\t0.650234352252087\t27.8800077057227\t0.981271881048941\t1.19759262267132\t1\n-M221.0819T313\tk3\tk4\t0.892053947489387\t205.520350368562\t1.34889125773252\t0.198872388726033\t1\n-M221.1545T359\tk3\tk4\t0.868578674161131\t293.467356422976\t1.31076811634934\t0.240190468529701\t1\n-M223.0972T392\tk3\tk4\t-0.695781085203341\t-1064.95070398255\t1.04058090909052\t0.943549574574631\t1\n-M223.1701T415\tk3\tk4\t-0.568276646782733\t-85.434175064887\t0.85928803090091\t1.42596946617689\t1\n-M224.0475T263\tk3\tk4\t-0.621109988621108\t-192.01301265757\t0.957662620210591\t1.80047610316209\t1\n-M225.1492T219\tk3\tk4\t-0.430982304599708\t-73.1282403929517\t0.644543090833391\t0.290003020295303\t1\n-M226.063T307\tk3\tk4\t-0.23749709975767\t-75.4459083322916\t0.362755974902242\t1.5572042420778\t1\n-M227.0337T239\tk3\tk4\t-0.489582072303357\t-144.861904675796\t0.732148442681977\t1.63907769072547\t1\n-M227.0337T297\tk3\tk4\t-0.670823847656132\t-298.872181649918\t1.02760164005476\t0.0352136697026928\t1\n-M235.0975T362\tk3\tk4\t0.957044548731721\t1050.17726108956\t1.45155352478841\t0.0761849553987679\t1\n-M236.1009T363\tk3\tk4\t0.947520850007318\t400.902345393545\t1.43387496050741\t0.0956882520821938\t1\n-M239.0705T263\tk3\tk4\t-0.645462488098628\t-332.653882174526\t1.03923450197221\t1.64848670528404\t1\n-M239.0713T322\tk3\tk4\t-0.840228074155556\t-335.647696249954\t1.30944419846187\t0.385460186438462\t1\n-M239.092T226\tk3\tk4\t-0.267974262081915\t-73.9391331023486\t0.403977115339737\t0.147404158041776\t1\n-M241.0508T258\tk3\tk4\t-0.214383525057063\t-36.7486689582988\t0.32201883141828\t1.53003427936492\t1\n-M241.0881T263\tk3\tk4\t-0.575336488585071\t-112.169324841286\t0.919535574827604\t1.79939365719556\t1\n-M242.0543T326\tk3\tk4\t-0.294924102919575\t-39.0303343265066\t0.44169823453763\t0.804803565778812\t1\n-M243.0659T229\tk3\tk4\t-0.676025311087273\t-158.308876660442\t1.02437797042599\t0.337164523295214\t1\n-M243.1968T424\tk3\tk4\t-0.458144815716855\t-413.00417807513\t0.694962157586264\t0.636612023084867\t1\n-M249.1136T427\tk3\tk4\t0.623472778264311\t815.866796309355\t0.938751280858899\t0.201532158580715\t1\n'
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/expected_contrast_corcov_all.tsv
--- a/test-data/expected_contrast_corcov_all.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,1151 +0,0 @@\n-featureID\tfactorLevel1\tfactorLevel2\tcorrelation\tcovariance\tvip4p\tvip4o\tlevel1Level2Sig\n-M200.005T296\tk1\tother\t-0.205568289258149\t-17.7677077386947\t0.607800774858881\t0.76895407082906\t0\n-M200.1286T209\tk1\tother\t-0.00170937109642714\t-0.0773130525978799\t0.00505407269126545\t0.611367438686349\t0\n-M200.1286T214\tk1\tother\t-0.182819068559282\t-6.2134875422604\t0.540538484463285\t0.421434534377586\t0\n-M200.8062T276\tk1\tother\t0.23979010255191\t15.4952138148085\t0.708983913134179\t0.485389578917022\t0\n-M201.7354T319\tk1\tother\t-0.481792701325989\t-325.295925848215\t1.42450948171074\t0.433545223368707\t1\n-M201.8009T418\tk1\tother\t0.106575042922809\t35.0560223480028\t0.315108881349675\t0.426724552480981\t0\n-M201.8011T348\tk1\tother\t0.143426230924376\t49.1654403193539\t0.424066253630452\t0.228931998243512\t0\n-M201.8013T369\tk1\tother\t0.254989702750156\t63.6248135583442\t0.753924350257912\t0.194937312445436\t0\n-M201.8014T535\tk1\tother\t0.0944741309478455\t45.4778981404852\t0.279330290685598\t0.582856629326936\t0\n-M201.8017T217\tk1\tother\t0.101717530673506\t34.4582873983144\t0.300746745440156\t1.07311456897249\t0\n-M201.8017T476\tk1\tother\t0.199969672076937\t114.883702224861\t0.591247424762137\t1.01692081090481\t0\n-M201.8022T437\tk1\tother\t0.0842976280350202\t37.1744799493247\t0.249241572342461\t0.410797455818058\t0\n-M202.95T726\tk1\tother\t0.210702017148315\t6.81745073534487\t0.622979593541557\t0.777986168109099\t0\n-M203.0345T357\tk1\tother\t-0.0487773685984231\t-0.260917897542442\t0.144219337217272\t0.239938898694363\t0\n-M203.7984T363\tk1\tother\t0.0697219696356168\t6.17022923991264\t0.206145934872274\t0.127434589842075\t0\n-M203.7989T238\tk1\tother\t0.134124235618366\t11.4295080245344\t0.396563179225689\t0.170076712079631\t0\n-M205.8387T251\tk1\tother\t0.228657014037888\t57.2088201018695\t0.676066872038906\t1.58747576053444\t0\n-M205.8387T276\tk1\tother\t0.0605703455198227\t13.5629527902119\t0.1790874607814\t1.39947140540822\t0\n-M205.8394T201\tk1\tother\t0.181446005672092\t44.3013867271896\t0.536478769369212\t1.55214077307789\t0\n-M205.8394T207\tk1\tother\t0.120171269694766\t45.9353074945554\t0.355308647553766\t1.38235363181598\t0\n-M205.8394T217\tk1\tother\t0.206958310885333\t87.5568462553266\t0.611910631613158\t1.47871140282086\t0\n-M205.8394T231\tk1\tother\t0.219847579856986\t77.0556962657189\t0.650020145958034\t1.48021330715316\t0\n-M205.8394T245\tk1\tother\t0.189436892632946\t91.0370377759351\t0.560105308774412\t1.52969317856787\t0\n-M205.8398T239\tk1\tother\t0.218200999587392\t65.8940487548431\t0.645151725992394\t1.01244902349355\t0\n-M205.8398T264\tk1\tother\t0.361875459606204\t115.320413237692\t1.0699519149807\t1.50376494338286\t0\n-M205.839T273\tk1\tother\t0.189783047252342\t67.1243847868486\t0.561128779109496\t1.45143192065427\t0\n-M205.8401T322\tk1\tother\t0.172463850511401\t63.3751627867724\t0.509921361676263\t1.05188886676183\t0\n-M206.8403T273\tk1\tother\t0.205152881234278\t11.9822134300559\t0.606572543988727\t1.50801968858745\t0\n-M207.0654T373\tk1\tother\t0.384869953141161\t663.104542272874\t1.13793940000804\t0.109766772892289\t1\n-M207.0661T267\tk1\tother\t0.348203365038172\t50.0913278193799\t1.02952783156598\t0.0792927417369285\t0\n-M207.066T243\tk1\tother\t0.400068427783187\t94.5702550214998\t1.18287650921605\t0.105071717614767\t1\n-M207.1386T512\tk1\tother\t0.230480061072539\t9.30232249295143\t0.681457048725515\t0.395070954149977\t1\n-M207.8358T251\tk1\tother\t0.254719287292824\t71.9307905007691\t0.753124816803148\t1.58920714209002\t0\n-M207.8364T207\tk1\tother\t0.117750045061351\t46.7033501101528\t0.348149847849746\t1.42201120547266\t0\n-M207.8364T217\tk1\tother\t0.174209185184267\t68.7316956045612\t0.515081767351597\t1.57490113794723\t0\n-M207.8364T245\tk1\tother\t0.182841250356576\t87.2963634796853\t0.540604069061143\t1.52619977648929\t0\n-M207.8365T363\tk1\tother\t0.154366234442276\t79.0690740225428\t0.456412403122352\t1.54539736459774\t0\n-M207.8366T347\tk1\tother\t0.206042031078707\t64.8364266906763\t0.609201480418366\t1.15958062567833\t0\n-M207.8368T238\tk1\tother\t0.137301689961093\t46.7913503211824\t0.405957912326586\t1.51731859590296\t0\n-M207.9308T206\tk1\tother\t0.119160334235501\t10.2386988391127\t0.352319629365741\t1.65509434499656\t0\n-M207.9308T302\tk1\tother\t0.3'..b'\t1.87679331213553\t0\n-M222.958T307\tk3\tk4\t0.130125400011435\t14.4097068213614\t0.980031615238712\t1.84580351530068\t0\n-M223.0971T254\tk3\tk4\t-0.299598423001228\t-10.4167916472407\t0.55385924506541\t0.15404275386516\t0\n-M223.0972T392\tk3\tk4\t-0.709238857718768\t-693.637575715692\t1.30509430405307\t0.106088281708156\t1\n-M223.1701T415\tk3\tk4\t-0.607249656260953\t-58.3340731817923\t1.12977606042895\t0.197318512803509\t1\n-M223.2066T590\tk3\tk4\t-0.265819100343483\t-16.7839103662305\t0.704288414542848\t0.196681353798032\t0\n-M224.0475T263\tk3\tk4\t-0.651938419271287\t-128.781039574964\t1.23679219173755\t0.237782307188353\t1\n-M224.9538T465\tk3\tk4\t0.0653048953085554\t1.83374877278915\t0.941328915004684\t1.5547048494634\t0\n-M225.0555T347\tk3\tk4\t-0.172969211849726\t-6.25699669859165\t0.321452137968353\t0.0669831366686741\t0\n-M225.1492T219\tk3\tk4\t-0.403940954582791\t-43.7952263459768\t0.743287009454029\t0.133612743514937\t1\n-M226.063T307\tk3\tk4\t-0.276807136474883\t-56.1872616871642\t0.520211182345383\t0.140251697708288\t1\n-M227.0337T239\tk3\tk4\t-0.494868693408774\t-93.5625109086237\t0.910562485634211\t0.0633311113381116\t1\n-M227.0337T297\tk3\tk4\t-0.652210446944728\t-185.672658064226\t1.22927820970004\t0.200578754535156\t1\n-M230.9242T307\tk3\tk4\t0.204644658872227\t29.012634244734\t0.855216806782364\t1.35247345140133\t0\n-M231.1021T437\tk3\tk4\t0.880844216330968\t651.101807919262\t1.64515770337497\t0.114826202089002\t0\n-M231.9313T509\tk3\tk4\t-0.00415351646735901\t-0.1979721480489\t0.00933797372934315\t0.368951631654069\t0\n-M233.0821T333\tk3\tk4\t0.921579767708614\t768.598043934174\t1.72307677607054\t0.389522112743766\t0\n-M234.0851T333\tk3\tk4\t0.920095229872725\t289.943152748032\t1.72259657238752\t0.383885615321262\t0\n-M235.0975T362\tk3\tk4\t0.947062247272008\t664.036855976087\t1.76736220123623\t0.313681938548904\t1\n-M235.8222T811\tk3\tk4\t0.298912453830817\t52.9896131699367\t1.00944081548847\t1.77600365814067\t0\n-M236.1009T363\tk3\tk4\t0.93291259123503\t252.216781652633\t1.73703911111011\t0.525788927860275\t1\n-M238.8458T327\tk3\tk4\t0.25003273563463\t18.2480666906174\t0.974209800645383\t1.89786556696001\t0\n-M239.0703T450\tk3\tk4\t-0.300392068851162\t-41.5828931512654\t0.555455758121169\t0.0248863571667658\t0\n-M239.0705T263\tk3\tk4\t-0.671926723867498\t-221.272124644946\t1.33109974438325\t0.260508133179631\t1\n-M239.0713T322\tk3\tk4\t-0.842106639352595\t-214.949667254006\t1.61474160714348\t0.0770411912396949\t1\n-M239.092T226\tk3\tk4\t-0.248781451243365\t-43.8613981074719\t0.461453361402538\t0.311376241971435\t1\n-M239.2014T293\tk3\tk4\t-0.28540719574734\t-55.0408615594444\t0.534253047887467\t0.147424142375548\t0\n-M239.201T299\tk3\tk4\t-0.0780922485815577\t-9.06732638024395\t0.159104767874571\t0.258809578688652\t0\n-M241.0506T270\tk3\tk4\t-0.36877481687529\t-36.3996452799611\t0.742255097518181\t0.0464360297347164\t0\n-M241.0507T327\tk3\tk4\t-0.288148483167594\t-60.5744882082272\t0.533323799196686\t0.174448803754458\t0\n-M241.0508T258\tk3\tk4\t-0.252235249110553\t-27.6273472884382\t0.466167268616685\t0.109776283792296\t1\n-M241.0881T263\tk3\tk4\t-0.600536060118728\t-74.8125539857968\t1.18095090893116\t0.118819979353438\t1\n-M242.0543T326\tk3\tk4\t-0.298732541983177\t-25.2614189810431\t0.550483197769\t0.170918746646601\t1\n-M243.0659T229\tk3\tk4\t-0.660997307348233\t-98.9065843614332\t1.23237562783664\t0.0295347393461701\t1\n-M243.1968T424\tk3\tk4\t-0.467282558882582\t-269.162431828202\t0.872135749125959\t0.104862245877711\t1\n-M243.1969T605\tk3\tk4\t-0.355304078515019\t-42.8852627846188\t0.859296315700833\t0.288556531083536\t0\n-M246.9633T231\tk3\tk4\t-0.049435772770902\t-0.748958031691591\t0.0919982777539007\t0.439921100532443\t0\n-M247.1344T557\tk3\tk4\t0.782706650127213\t167.412141053868\t1.46162890475362\t0.840150211528623\t0\n-M247.1344T570\tk3\tk4\t0.74075004340755\t193.242735842444\t1.38567502811156\t0.898188672965975\t0\n-M249.1135T417\tk3\tk4\t0.942934834531785\t1241.25367711661\t1.76832928786058\t0.424410348816685\t0\n-M249.1136T427\tk3\tk4\t0.606702612210584\t507.29529067932\t1.12397085015611\t0.971799483972057\t1\n-M249.1864T510\tk3\tk4\t-0.393228148765393\t-18.0095678914864\t0.773348453126108\t0.158350437212514\t0\n-M349.2383T700\tk3\tk4\t-0.0500728896662634\t-5.84552363619299\t0.0961269451667468\t0.184830114693322\t0\n'
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/expected_contrast_corcov_global.tsv
--- a/test-data/expected_contrast_corcov_global.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,1241 +0,0 @@\n-featureID\tfactorLevel1\tfactorLevel2\tcorrelation\tcovariance\tvip4p\tvip4o\n-M200.1286T209\tk1\tother\t0.00610295722336186\t0.27035221146536\t0.018416423809366\t0.634575609576524\n-M200.005T296\tk1\tother\t-0.207079473087674\t-17.5301433333897\t0.624887771456801\t0.798849466524767\n-M200.1286T214\tk1\tother\t-0.16228451910792\t-5.40211927097541\t0.489713490068382\t0.422802996280485\n-M200.8062T276\tk1\tother\t0.26377831834804\t16.6946973651653\t0.795983508425011\t0.494927616354757\n-M201.1135T595\tk1\tother\t0.0465436319520825\t1.40286314428294\t0.140451132178265\t0.110801795255121\n-M201.7354T319\tk1\tother\t-0.473950488270113\t-313.418420834738\t1.43020387284152\t0.467687662909169\n-M201.801T459\tk1\tother\t-0.0300518543068486\t-14.1891210254408\t0.0906851653905858\t0.463075283942213\n-M201.8009T418\tk1\tother\t0.140004072609055\t45.1046093363618\t0.422479503270263\t0.419951551903295\n-M201.8022T437\tk1\tother\t0.116008296445667\t50.1062305115027\t0.350069298301434\t0.441966178111265\n-M201.8011T348\tk1\tother\t0.168212234231169\t56.4757571516748\t0.507601099293801\t0.250473870993404\n-M201.8014T535\tk1\tother\t0.135262980947713\t63.7733996207134\t0.408172676242197\t0.627242614108505\n-M201.8011T521\tk1\tother\t0.196830866455755\t92.1796678062135\t0.593961340829629\t0.258386787620497\n-M201.8015T228\tk1\tother\t0.209449852392484\t66.1643778345248\t0.632040682458572\t0.718395489414694\n-M201.8021T276\tk1\tother\t0.221094805465706\t36.1179537415538\t0.667180760159871\t0.0421589153052972\n-M201.8017T476\tk1\tother\t0.235051205862516\t132.260423014413\t0.709295914363634\t1.07318361520426\n-M201.8018T251\tk1\tother\t0.261258933885905\t60.3357674306479\t0.78838095604011\t0.346267161548145\n-M201.8013T369\tk1\tother\t0.2820991283224\t68.9411875152587\t0.851268805154127\t0.220437950262685\n-M201.8017T217\tk1\tother\t0.157582881572084\t52.2853541145593\t0.475525720715107\t1.14258101205421\n-M201.8016T454\tk1\tother\t0.304988535118594\t130.855627535623\t0.920340404524028\t0.299976123818105\n-M202.95T726\tk1\tother\t0.251327855331085\t7.96465696939498\t0.758412705427184\t0.816120242601892\n-M203.0345T357\tk1\tother\t-0.0502086901209672\t-0.263049529708332\t0.15151089583936\t0.242398884926287\n-M203.7984T363\tk1\tother\t0.0820254609491957\t7.10973587962661\t0.247521913838164\t0.128357199486652\n-M203.7988T212\tk1\tother\t0.262084319893854\t23.4274900087477\t0.790871659804266\t1.02178885592246\n-M203.7989T238\tk1\tother\t0.189426337554308\t15.8100693564693\t0.571617264447158\t0.151165214286282\n-M203.7987T252\tk1\tother\t0.611569432358497\t64.0614406787583\t1.84548595753767\t0.274474402984086\n-M205.8387T276\tk1\tother\t0.0668506700535291\t14.6613208916993\t0.201730116497144\t1.43154241246519\n-M205.839T273\tk1\tother\t0.193564082615284\t67.053401218304\t0.58410341892426\t1.48615538280004\n-M205.8394T245\tk1\tother\t0.197942425379343\t93.1677440357236\t0.597315606553058\t1.5666770117285\n-M205.8394T217\tk1\tother\t0.220076628280187\t91.1914871757524\t0.664108285312797\t1.51130334975221\n-M205.8398T239\tk1\tother\t0.207128316264835\t61.2635371066746\t0.625035161749386\t1.0587001352699\n-M205.8394T207\tk1\tother\t0.132325223475993\t49.5406556328285\t0.399307631859908\t1.40862918606119\n-M205.8387T251\tk1\tother\t0.231984539258231\t56.847404479658\t0.700041870823831\t1.63454938187322\n-M205.8394T231\tk1\tother\t0.231385398921811\t79.4313869405781\t0.698233891191506\t1.51460452029492\n-M205.8394T201\tk1\tother\t0.193465708540255\t46.2644115363768\t0.583806563057295\t1.58937678207177\n-M205.8401T322\tk1\tother\t0.181337053727014\t65.2650538409448\t0.547206855882042\t1.07290107917461\n-M205.8398T264\tk1\tother\t0.361720942112156\t112.899975126199\t1.09153741814873\t1.55214069724267\n-M206.8403T273\tk1\tother\t0.194613478300126\t11.1328275242468\t0.587270099431504\t1.55725730004519\n-M207.0661T267\tk1\tother\t0.334751014796073\t47.1655190509928\t1.01015234639049\t0.0572028625498761\n-M207.0654T373\tk1\tother\t0.375344177981736\t633.389435474822\t1.1326472074274\t0.0817812255676116\n-M207.066T243\tk1\tother\t0.389718472545717\t90.2286393037669\t1.1760234086627\t0.135968413991624\n-M207.1386T512\tk1\tother\t0.219308417808505\t8.66934863966924\t0.661790115759334\t0.432769994587694\n-M207.8364T207\tk1\tother\t0.13088'..b'800149238\t1.9214103398228\n-M222.9585T226\tk3\tk4\t0.289729662005301\t37.4441397519607\t0.988755832879857\t1.86540652577335\n-M223.0971T254\tk3\tk4\t-0.2905508794516\t-9.99471849746867\t0.551884764061382\t0.171029216800717\n-M222.9586T206\tk3\tk4\t0.261481046304327\t33.5439012033737\t1.02242068871943\t1.91329458715761\n-M223.0972T392\tk3\tk4\t-0.706975261562888\t-684.066346058617\t1.33665680507711\t0.112173903740236\n-M223.2066T590\tk3\tk4\t-0.260723442323778\t-16.2869951448297\t0.709758767477389\t0.194282279121181\n-M223.1701T415\tk3\tk4\t-0.603327066188808\t-57.3405363747324\t1.15330512818776\t0.208630022858105\n-M224.0475T263\tk3\tk4\t-0.647458084914889\t-126.53507520088\t1.26202553406884\t0.265738207098508\n-M224.9538T465\tk3\tk4\t0.06517695930772\t1.81068169813824\t0.965286163701467\t1.62048635323385\n-M225.1492T219\tk3\tk4\t-0.404331684985707\t-43.3711143886964\t0.764438857566635\t0.131582061330498\n-M225.0555T347\tk3\tk4\t-0.168429690039993\t-6.02795062658209\t0.321612178205962\t0.060743985342396\n-M226.063T307\tk3\tk4\t-0.265990436645884\t-53.41712680683\t0.513611509376977\t0.175122343627516\n-M227.0337T297\tk3\tk4\t-0.650625286809679\t-183.25045424018\t1.25996852038554\t0.197417336152516\n-M227.0337T239\tk3\tk4\t-0.495654530051867\t-92.7139076135493\t0.937055205013852\t0.0699771315604473\n-M230.9242T307\tk3\tk4\t0.203730295180637\t28.5756607240549\t0.874777796291635\t1.37098773035015\n-M231.1021T437\tk3\tk4\t0.881665153793919\t644.773809621214\t1.69191456330879\t0.125813801074589\n-M231.9313T509\tk3\tk4\t-0.01238970398483\t-0.584255765465074\t0.0286196267444683\t0.402582750967895\n-M233.0821T333\tk3\tk4\t0.922235437351619\t760.960417813671\t1.77165774603055\t0.406286902681267\n-M234.0851T333\tk3\tk4\t0.920811578167749\t287.081209287532\t1.77128275712594\t0.400603892434244\n-M235.0975T362\tk3\tk4\t0.947698706893327\t657.412361131388\t1.8171201728931\t0.320269041428948\n-M235.8222T811\tk3\tk4\t0.297802495938182\t52.2310781272254\t1.03331208439988\t1.82801675312329\n-M236.1009T363\tk3\tk4\t0.934088468548793\t249.847468499021\t1.78699351764026\t0.538343998457527\n-M238.8458T327\tk3\tk4\t0.248936279409871\t17.9747185528014\t0.996575348102538\t1.95883761480951\n-M239.0713T322\tk3\tk4\t-0.84225642441801\t-212.700218358026\t1.65938286317544\t0.0791705478538298\n-M239.092T226\tk3\tk4\t-0.248340273453942\t-43.317715713361\t0.47328560538474\t0.32856388476748\n-M239.0705T263\tk3\tk4\t-0.665052979995726\t-216.678067364495\t1.3536651668788\t0.290958992228221\n-M239.0703T450\tk3\tk4\t-0.301065788714065\t-41.2326802149512\t0.571990404061247\t0.0188832067930765\n-M239.2014T293\tk3\tk4\t-0.280650231745777\t-53.5475528062032\t0.539776308838968\t0.148792052883534\n-M239.201T299\tk3\tk4\t-0.0733447913255672\t-8.42547735146752\t0.153536228216873\t0.268384195797385\n-M241.0506T270\tk3\tk4\t-0.3600251005884\t-35.1578730401621\t0.744545146924024\t0.0438122214227916\n-M241.0881T263\tk3\tk4\t-0.593760253573462\t-73.1813523838847\t1.19969320978955\t0.144333147290802\n-M241.0508T258\tk3\tk4\t-0.246747998235283\t-26.7387416450207\t0.468550020286443\t0.110672703362676\n-M241.0507T327\tk3\tk4\t-0.286749623080728\t-59.6389775301387\t0.545310432128\t0.17876392306642\n-M242.0543T326\tk3\tk4\t-0.298187620821618\t-24.9470234477927\t0.564569571157494\t0.178903081140115\n-M243.0659T229\tk3\tk4\t-0.667047785146351\t-98.7498348716513\t1.27781117224567\t0.0306077480489034\n-M243.1969T605\tk3\tk4\t-0.349484509993075\t-41.7339731305398\t0.868434388491588\t0.2853778669022\n-M243.1968T424\tk3\tk4\t-0.462475896445928\t-263.559025172212\t0.886869958629035\t0.0984035941468826\n-M246.9633T231\tk3\tk4\t-0.043385476103516\t-0.650301027903623\t0.0829562404062796\t0.462150570342355\n-M247.1344T570\tk3\tk4\t0.742870889061392\t191.733830807306\t1.42780654598153\t0.920468125878429\n-M247.1344T557\tk3\tk4\t0.784693406282486\t166.051134807571\t1.50558204332566\t0.859689423756907\n-M249.1135T417\tk3\tk4\t0.943702685557068\t1229.04554440679\t1.81837300277549\t0.437639589850462\n-M249.1864T510\tk3\tk4\t-0.38625302104308\t-17.5018719090562\t0.780492682407414\t0.173598417010409\n-M249.1136T427\tk3\tk4\t0.608625007956315\t503.487481392502\t1.1584980321394\t0.999454734912034\n-M349.2383T700\tk3\tk4\t-0.0416027154311233\t-4.80503285892478\t0.0820598064412159\t0.179029497402632\n'
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/expected_contrast_salience.tsv
--- a/test-data/expected_contrast_salience.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,125 +0,0 @@
-featureID salientLevel salientRCV salience
-M225.0555T347 k2 0.654346323466894 101.569818873696
-M201.1135T595 k3 9999 53.3016214378785
-M226.063T307 k1 0.973191433727169 36.4723997217504
-M200.005T296 k3 1.4826 35.6169526598547
-M200.1286T209 k1 1.24540919814203 34.921648464144
-M239.201T299 k2 1.00929185280406 34.5596295503589
-M249.1136T427 k4 1.24790362297309 30.2686698097383
-M222.9586T827 k2 1.46258708652898 29.6893035129007
-M223.2066T590 k1 0.70015773090912 29.4880441883542
-M241.0508T258 k3 0.725572320969615 28.7436288184419
-M200.1286T214 k1 1.4826 27.3008482312872
-M222.9586T818 k2 1.35535839627361 25.2780055231458
-M246.9633T231 k1 1.23886534796064 23.5083897048845
-M239.092T226 k3 0.88216540918546 22.7952763785857
-M222.9585T465 k2 1.47900420371911 20.0127503460699
-M222.9579T348 k2 1.17625336310864 19.613267456487
-M217.0506T407 k4 1.12443284783984 19.47767841362
-M242.0543T326 k1 0.545008402948539 18.9800691741925
-M241.0507T327 k1 0.440801070417563 18.732112285079
-M223.0971T254 k1 1.00571421332888 18.4419395184882
-M224.9538T465 k2 1.43736674906532 17.7515812701101
-M222.9577T319 k2 0.978818262586115 15.1849158433211
-M207.0661T267 k4 0.78489184428155 14.509370673183
-M211.0607T263 k1 9999 12.8776609649919
-M207.0654T373 k4 0.822733190729335 12.5886344798622
-M239.2014T293 k1 1.34036324094924 11.4657567190007
-M249.1864T510 k1 0.445490430834101 11.2958572486159
-M222.9587T335 k2 1.33914871229884 10.8800374184037
-M210.9391T578 k2 1.09559645701531 10.3999357759346
-M222.9585T226 k2 0.761200229809381 9.92534332333926
-M247.1344T557 k4 1.1581855674583 9.63432611487073
-M225.1492T219 k3 0.782367451887942 9.49980270276039
-M222.9586T326 k2 1.1243323340834 9.34769324637502
-M210.9378T464 k2 1.09557149288211 9.23579495037884
-M227.0337T239 k1 0.296684427566194 9.00896098686374
-M210.9388T632 k2 1.02423197472563 9.00428828277096
-M221.0817T230 k1 0.649081536420565 9.00027244655361
-M349.2383T700 k1 0.659554473563074 8.81866595392962
-M221.1545T359 k4 0.739792166001195 8.75577472442079
-M222.958T307 k2 0.820632865757542 8.66831736766843
-M210.9385T503 k2 0.960348523808477 8.38530853639381
-M223.1701T415 k1 0.540766490124598 7.71593243590817
-M231.1021T437 k4 0.556190853013988 7.61313138332696
-M222.9586T206 k2 0.775626376854922 7.45804745609616
-M222.9585T217 k2 0.707741134296328 7.39857461973973
-M236.1009T363 k4 0.372885129742006 7.38507147285504
-M239.0703T450 k1 1.27674166336874 7.143404215896
-M230.9242T307 k2 0.108718849815744 6.98408047765851
-M247.1344T570 k4 0.828721225008329 6.86308696034601
-M221.1907T677 k1 0.437513526787183 6.8601498596543
-M222.9586T239 k2 0.705189570406482 6.75978570778928
-M238.8458T327 k2 0.660798616519311 6.75185562319907
-M235.0975T362 k4 0.209363850790929 6.700140842195
-M241.0506T270 k1 0.7058836442502 6.67232705417706
-M222.958T245 k2 0.679031641106876 6.59398476903159
-M221.0819T313 k4 0.771318677948916 6.5581740958163
-M208.0692T243 k4 0.656423724747553 6.06010964216585
-M249.1135T417 k4 0.251142828332635 6.00175839214762
-M207.066T243 k4 0.312894722325372 5.52288495175377
-M201.801T459 k1 0.27172402925213 5.44934519549878
-M243.1969T605 k1 0.455918436177419 5.37997619313495
-M234.0851T333 k4 0.389943714706541 5.23773681622715
-M205.8398T239 k2 0.0688485502247814 5.16418030707202
-M233.0821T333 k4 0.382888097117214 5.13725455680185
-M243.1968T424 k1 0.62287249639823 5.1320776531968
-M219.1389T250 k3 1.00946387135058 5.13011859020022
-M207.1386T512 k4 0.489070627711473 4.77628855483532
-M211.0388T319 k1 0.184150040780034 4.7219603190278
-M227.0337T297 k1 0.375797305614719 4.71053348801438
-M201.8011T521 k3 0.142664420562571 4.55033977287593
-M211.0395T228 k1 0.307713788957595 4.51438168133822
-M235.8222T811 k2 0.107655355266344 4.28022022731715
-M201.7354T319 k1 0.164019585662113 4.26343675250727
-M205.8401T322 k2 0.11990900472603 4.20396843586851
-M207.8366T347 k2 0.114489177550399 4.07035410449168
-M241.0881T263 k3 0.589805085919582 4.00656730312929
-M224.0475T263 k3 0.320658862025185 3.94745563162511
-M201.8018T251 k4 0.0869943285834709 3.85706049089488
-M211.039T418 k1 0.232388679132544 3.44979773850464
-M231.9313T509 k2 0.109910693790499 3.40211568758744
-M239.0713T322 k1 0.272848308873536 3.31874093254692
-M239.0705T263 k3 0.25187764144866 3.30477110597757
-M207.9308T302 k4 0.881105561611312 3.27666956438499
-M211.0755T367 k1 0.266189209026317 3.26458485808283
-M201.8014T535 k3 0.149045844413246 3.10467657412921
-M243.0659T229 k3 0.436857985378519 2.97640330150451
-M207.9308T311 k2 0.17178193705229 2.79318105916599
-M201.8022T437 k3 0.0867580301363785 2.73244817739804
-M223.0972T392 k1 0.143181310490976 2.73005953671396
-M206.8403T273 k2 0.118475186919469 2.61435230219863
-M201.8011T348 k2 0.0903182532730961 2.56371624348966
-M217.8836T288 k2 0.515127813018431 2.44487601121151
-M205.8394T217 k2 0.0854307022773787 2.37134032793759
-M203.7984T363 k3 0.683649933207837 2.29695955851911
-M207.9308T206 k2 0.0578578265693105 2.27527985280744
-M207.8365T363 k2 0.154390665839427 2.23140294415231
-M205.8394T207 k2 0.0837949401720195 2.10587622472665
-M205.8398T264 k2 0.107143300270328 2.08808904315894
-M201.8013T369 k2 0.13243118499921 2.08171154542141
-M207.8364T207 k2 0.100650141324415 2.04334141183284
-M205.8387T251 k2 0.047266744264268 2.01195602330825
-M205.8387T276 k2 0.15411637360463 1.99380186753428
-M207.8368T238 k2 0.082890831541599 1.96974806457244
-M202.95T726 k4 0.29515186179214 1.96626948527112
-M205.8394T201 k2 0.0971906645662093 1.92746114594293
-M205.839T273 k2 0.0826175960776624 1.90809888959574
-M207.8364T245 k2 0.0361743769102992 1.90520433100978
-M207.8358T251 k2 0.0489473358608422 1.88807218629405
-M205.8394T245 k2 0.0418760169815051 1.75882245948066
-M201.8009T418 k3 0.465537472368452 1.75800634733411
-M200.8062T276 k3 0.459202632147948 1.63975045494169
-M207.8364T217 k2 0.114231599397726 1.61239464498683
-M201.8016T454 k3 0.20369374357551 1.59639206879613
-M205.8394T231 k2 0.0673343659677769 1.58611981065081
-M201.8017T476 k3 0.136478791238534 1.58468769316308
-M212.0743T273 k2 0.0440001367105724 1.51072013176816
-M201.8015T228 k3 0.108088872145589 1.44115508852448
-M212.1367T256 k2 0.0573604535119109 1.42762019772229
-M203.7988T212 k3 0.0725583298731829 1.4042896691213
-M201.8017T217 k3 0.0833878699606626 1.38933214323566
-M203.7987T252 k4 0.112077763782837 1.35335519989038
-M201.8021T276 k3 0.201913061067989 1.32009880422372
-M203.7989T238 k3 0.215855239042376 1.25399819678269
-M203.0345T357 k4 9999 0
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/input_dataMatrix.tsv
--- a/test-data/input_dataMatrix.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
b'@@ -1,125 +0,0 @@\n-\tR12S96\tR12S97\tR12S81\tR12S117\tR12S156\tR12S43\tR12S198\tR12S34\tR12S60\tR12S47\tR12S182\tR12S138\tR12S12\tR12S39\tR12S40\tR12S219\tR12S180\tR12S100\tR12S75\tR12S114\tR12S79\tR12S115\tR12S145\tR12S48\tR12S108\tR12S110\tR12S109\tR12S7\tR12S10\tR12S14\tR12S36\tR12S56\tR12S209\tR12S210\tR12S211\tR12S212\tR12S227\tR12S228\tR12S139\tR12S121\tR12S160\tR12S161\tR12S162\tR12S224\tR12S32\tR12S92\tR12S72\tR12S83\tR12S86\tR12S87\tR12S133\tR12S135\tR12S46\tR12S2\tR12S74\tR12S17\tR12S167\tR12S1\tR12S31\tR12S125\tR12S33\tR12S78\tR12S84\tR12S154\tR12S6\tR12S204\tR12S205\tR12S189\tR12S190\tR12S3\tR12S5\tR12S73\tR12S158\tR12S221\tR12S104\tR12S24\tR12S85\tR12S53\tR12S215\tR12S217\tR12S218\tR12S94\tR12S107\tR12S16\tR12S55\tR12S222\tR12S332\tR12S29\tR12S184\tR12S76\tR12S183\tR12S28\tR12S38\n-M200.1286T209\t599.622643838653\t56022.091141864\t2078.83999952589\t9546.15141604607\t2479.44997027108\t15924.6796705705\t2980.39334787782\t48000.2243408757\t3548.35303905968\t0\t2634.2919103188\t6960.44755604711\t40799.8530574068\t38736.7695035272\t35369.6790450002\t579.736618878223\t3037.25009583423\t2289.04147031751\t4321.78417689814\t12295.4165946202\t994.509599027341\t4295.54722984572\t37887.1592140526\t6754.89401289343\t1586.52602624999\t10951.6626323503\t840.805354706402\t90449.2545858476\t78529.1194890688\t106179.556757701\t55763.2538011837\t4708.53095751121\t1598.81142786328\t853.911779752147\t28099.4505952829\t618.841026874513\t1443.64634150469\t501.907586663917\t491.276221258547\t5221.70309444766\t2259.10140293262\t1858.07371239014\t1051.12399109669\t4107.29092720654\t55836.0510410207\t841.345925337455\t4331.47575572949\t727.957846670897\t5445.4110231509\t14417.2213673088\t3703.29905969911\t8082.32273182127\t0\t58025.5140221892\t2252.33037052412\t49766.1872660734\t1853.11226576953\t26528.3209286938\t26213.686697477\t640.088242725782\t58436.9651783639\t388.058057296681\t1992.68535544897\t4581.92115319191\t53459.6715115635\t0\t612.483947322877\t3203.66061695304\t0\t38642.6140133922\t58139.1136905342\t3618.22620899181\t719.964780455661\t1310.75772727148\t707.94571220848\t42623.2521106332\t1633.97099980538\t3903.68625289336\t2651.69074074946\t0\t3192.34006961221\t472.795334744141\t1137.22624048374\t37815.1327084586\t3092.57132214465\t2170.98692014029\t738.240581584632\t36805.0495681966\t568.791936187407\t1709.51878330703\t2485.85348059009\t7478.4707092573\t39693.9919756214\n-M200.005T296\t8875.60684917604\t222870.321809447\t329310.505240632\t0\t0\t0\t0\t253227.717826374\t71964.4146035665\t0\t0\t0\t0\t44778.9116096516\t0\t0\t53092.5698192787\t507.772067572757\t25566.05020606\t0\t606.018828930468\t0\t0\t27729.3302844632\t20204.982069076\t0\t92282.7968046873\t39624.9064370559\t53981.0787002371\t249609.116894202\t218278.207492241\t173266.674534654\t0\t0\t0\t0\t0\t0\t0\t0\t0\t0\t0\t0\t0\t2956.58471183865\t0\t0\t211736.482239673\t75472.3429761252\t0\t0\t161752.465981721\t0\t31487.7366114763\t18132.066616559\t0\t0\t0\t35842.2222643485\t191062.28561586\t1909.71165138945\t199640.553527892\t0\t0\t0\t0\t0\t0\t0\t51116.3307624371\t0\t0\t0\t26430.6884603959\t113931.610980709\t232950.70106791\t209554.315204267\t0\t0\t0\t0\t4399.0868357501\t0\t153439.726985149\t0\t0\t740.081786118161\t212464.556415163\t309197.161673811\t0\t6592.57764352099\t156138.036989417\n-M200.1286T214\t0\t1038.54867958921\t0\t11146.3459734452\t3676.65137643094\t0\t7612.23613205063\t537.539152300049\t0\t2111.26913353822\t5526.22188813744\t9687.88473062987\t0\t0\t908.059424797955\t440.470661592666\t2784.21119202245\t0\t0\t17482.6490915817\t0\t10789.0891911928\t48962.5694434943\t0\t0\t10286.7447334036\t0\t2006.47481790736\t1021.30992108587\t3336.25211117013\t915.724030405264\t0\t2755.50090268778\t2804.51017227753\t36135.1584271993\t1640.06522595954\t4595.62863625927\t1538.7264914177\t2982.06689954589\t8598.87265281371\t4174.99366354965\t3367.65364818499\t1069.01644353118\t3545.26932848765\t34160.2486766354\t0\t0\t0\t0\t0\t9343.13332748516\t12500.9154254807\t0\t49875.805410529\t0\t0\t3358.1803215904\t66790.6949972937\t40382.91226816\t1439.50068785899\t497.420494382816\t0\t0\t9356.70737375596\t2642.45786354631\t0\t2087.24490733792\t5325.71509448965\t0\t61356.085336146\t0\t0\t5307.06566557934\t3963.08221647364\t0\t0\t0\t0\t5958.06959047805\t8194.06137306807\t6589.43605316202\t2010.44270987574\t0\t1343.64247192633\t0\t3975.52795976508\t5910'..b'3\t93949.0489100213\t337218.459518155\t46483.3313493308\t69461.991067025\t83947.2030780122\t240792.745135468\t286754.552744424\t43665.0174921916\t95993.4656717567\t76064.2733574763\t85024.7486135614\t0\t6382.64768172355\t638941.155198906\t230410.559308364\t294644.687559922\t230227.818560405\t68346.3819419163\t19048.8866928107\t263920.196898391\t197618.700490397\t171886.470909213\t227295.57837166\t152744.348626884\t353383.519059299\t170941.747814201\t147504.249085734\t197914.2858155\t113038.566079632\t70803.5224093739\t74966.0061392822\t39938.638569735\t380576.2416084\t263238.827281089\t10528.847640827\t17232.5288473964\t24039.3391689401\t122813.960518944\t79005.388692965\t111605.06001826\t44756.2611960228\t179428.710273487\t28217.3519823927\t32462.9417909756\t181583.71257493\t27685.2383387548\t286673.296277284\t203515.567390338\t140726.21058296\t71306.7484104464\t447925.259234674\t61178.72115978\t2376.09556105078\t160400.785515437\t81276.35742355\t1025647.90549129\t18713.0434803157\t207114.579663557\t244294.873417243\t125200.593298448\t17536.3277430097\t180738.270554307\t0\t175162.465162243\t53352.543973448\t198755.943894618\t246007.033278617\t129559.967079474\t148343.488101959\t5908.68744899742\t259032.884298432\t113693.819535935\t140926.013740506\t408642.84078953\t52358.6215828887\t129172.440146373\t81259.1880899418\t192475.519946854\t67255.4341284114\t44785.8946295567\t319809.924886343\t2112.53885406851\t93029.338234127\t116100.853267505\t1493245.65168128\t186803.576477278\t59896.6152903224\t167702.972515029\t105007.032843665\t171478.562473875\t147049.557513166\n-M249.1136T427\t0\t704210.663945086\t266821.637396172\t162713.452979761\t0\t0\t82420.3255376639\t481276.593999494\t0\t145877.006615255\t0\t146446.758221606\t957.820035786299\t0\t8805.3732166562\t580211.390550156\t0\t9005.26079072517\t0\t1452.15308058944\t0\t1115505.96878515\t50940.6723687412\t305902.430132776\t0\t22125.8996228935\t0\t208541.263954528\t0\t396458.091468952\t522058.516252832\t198865.35504059\t3720.24336873248\t0\t0\t544981.571999649\t8210219.19506647\t19704350.2790077\t3679724.01449737\t0\t153938.491835713\t8150.42249678451\t4303155.92952892\t0\t38539365.4416628\t739167.339766246\t0\t0\t1415.14371746057\t220587.994510329\t9200.60449701336\t3045.59689669356\t92326.8401783573\t210081.696296144\t0\t1082.77883122803\t2552.30124521204\t4337093.05371119\t55768470.2709427\t261022.317083578\t119667.96635625\t0\t97483.0929866658\t12017.4197217003\t140916.513711249\t1463.91899135966\t258361.472234214\t0\t0\t172423.000778411\t0\t0\t0\t30376.4653616091\t0\t341172.793419376\t123752.11148619\t125471.815207237\t104973.81281429\t3008.5222069453\t8334.2324487474\t106975088.974382\t0\t0\t312036.672929417\t12928.5773137429\t3574285.71688585\t289441.285966089\t31387.8367480033\t1116253.81087154\t0\t0\t14485.7293009826\n-M349.2383T700\t0\t96950.8438416494\t774886.647130349\t332674.35369519\t271751.158434702\t3351.49444727513\t291186.851086689\t129119.02515574\t5656.71487511088\t311707.58668354\t276405.750344745\t458478.763107115\t0\t0\t8323.43590316473\t418733.796340787\t2823250.11205656\t1007889.2402262\t0\t293938.9719939\t0\t373612.350811778\t279753.255696705\t5607.03904052335\t421298.445973218\t274245.565146836\t0\t654.529879818081\t1458.66850467529\t427481.298790431\t874.009005161957\t496127.875551971\t265448.397550545\t397200.23329594\t508197.184977192\t1996419.32143464\t267690.448147766\t326612.969700469\t259543.491368464\t355788.04571908\t317179.300292573\t274858.946743073\t282051.848896057\t289183.439152629\t288490.34077198\t0\t0\t3575.10820116886\t713559.860663124\t565360.679313733\t287924.600621003\t410744.495354003\t1536878.71989199\t283688.838393067\t878.164025755581\t0\t296524.438377735\t2174618.20501279\t306257.163848228\t1830041.28738341\t424377.071942549\t0\t696032.007525038\t287516.092525644\t4645.23772808526\t443714.370111792\t355034.741418753\t297938.096317151\t272901.252308573\t281752.652634904\t0\t0\t332332.085249119\t296009.378964613\t0\t110747.666266795\t418525.883489881\t256253.95104514\t284795.886608995\t1103475.1974735\t414645.894809623\t31236.7279005911\t611499.184604512\t3059.80957075193\t0\t287527.280455725\t1767354.38087557\t0\t2087276.63008552\t1481672.42818034\t329950.138593015\t1519083.87519876\t56263.0356485789\n'
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/input_sampleMetadata.tsv
--- a/test-data/input_sampleMetadata.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,94 +0,0 @@
-sampleMetadata k10
-R12S96 k3
-R12S97 k3
-R12S81 k3
-R12S117 k2
-R12S156 k2
-R12S43 k3
-R12S198 k2
-R12S34 k3
-R12S60 k3
-R12S47 k3
-R12S182 k2
-R12S138 k2
-R12S12 k3
-R12S39 k3
-R12S40 k3
-R12S219 k2
-R12S180 k1
-R12S100 k3
-R12S75 k3
-R12S114 k2
-R12S79 k3
-R12S115 k2
-R12S145 k2
-R12S48 k3
-R12S108 k3
-R12S110 k2
-R12S109 k3
-R12S7 k3
-R12S10 k3
-R12S14 k1
-R12S36 k3
-R12S56 k3
-R12S209 k2
-R12S210 k2
-R12S211 k1
-R12S212 k1
-R12S227 k4
-R12S228 k4
-R12S139 k4
-R12S121 k2
-R12S160 k2
-R12S161 k2
-R12S162 k4
-R12S224 k2
-R12S32 k4
-R12S92 k4
-R12S72 k3
-R12S83 k3
-R12S86 k1
-R12S87 k1
-R12S133 k2
-R12S135 k2
-R12S46 k3
-R12S2 k3
-R12S74 k3
-R12S17 k3
-R12S167 k2
-R12S1 k1
-R12S31 k4
-R12S125 k3
-R12S33 k3
-R12S78 k3
-R12S84 k1
-R12S154 k2
-R12S6 k3
-R12S204 k2
-R12S205 k1
-R12S189 k2
-R12S190 k2
-R12S3 k3
-R12S5 k3
-R12S73 k3
-R12S158 k2
-R12S221 k2
-R12S104 k3
-R12S24 k3
-R12S85 k3
-R12S53 k3
-R12S215 k2
-R12S217 k2
-R12S218 k2
-R12S94 k4
-R12S107 k1
-R12S16 k3
-R12S55 k3
-R12S222 k2
-R12S332 k1
-R12S29 k3
-R12S184 k3
-R12S76 k3
-R12S183 k2
-R12S28 k1
-R12S38 k3
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c test-data/input_variableMetadata.tsv
--- a/test-data/input_variableMetadata.tsv Mon Oct 16 14:56:52 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
b
@@ -1,125 +0,0 @@
-variableMetadata k10_kruskal_sig k10_kruskal_k2.k1_sig k10_kruskal_k3.k1_sig k10_kruskal_k4.k1_sig k10_kruskal_k3.k2_sig k10_kruskal_k4.k2_sig k10_kruskal_k4.k3_sig
-M200.005T296 1 0 0 0 1 0 0
-M200.1286T209 1 0 0 0 0 0 0
-M200.1286T214 1 0 0 0 1 0 0
-M200.8062T276 1 0 0 0 0 0 0
-M201.1135T595 0 0 0 0 0 0 0
-M201.7354T319 1 0 0 1 0 0 1
-M201.8009T418 1 0 0 0 0 0 0
-M201.8011T348 1 0 0 0 0 0 0
-M201.8011T521 0 0 0 0 0 0 0
-M201.8013T369 1 0 0 0 0 0 0
-M201.8014T535 1 0 0 0 0 0 0
-M201.8015T228 0 0 0 0 0 0 0
-M201.8016T454 0 0 0 0 0 0 0
-M201.8017T217 1 0 0 0 0 0 0
-M201.8017T476 1 0 0 0 0 0 0
-M201.8018T251 0 0 0 0 0 0 0
-M201.801T459 0 0 0 0 0 0 0
-M201.8021T276 0 0 0 0 0 0 0
-M201.8022T437 1 0 0 0 0 0 0
-M202.95T726 1 0 0 0 0 0 0
-M203.0345T357 1 0 0 0 0 0 0
-M203.7984T363 1 0 0 0 0 0 0
-M203.7987T252 0 0 0 0 0 0 0
-M203.7988T212 0 0 0 0 0 0 0
-M203.7989T238 1 0 0 0 0 0 0
-M205.8387T251 1 0 0 0 1 0 0
-M205.8387T276 1 0 0 0 1 0 0
-M205.8394T201 1 0 0 0 1 0 0
-M205.8394T207 1 0 0 0 1 0 0
-M205.8394T217 1 0 0 0 1 0 0
-M205.8394T231 1 0 0 0 1 0 0
-M205.8394T245 1 0 0 0 1 0 0
-M205.8398T239 1 0 0 0 1 0 0
-M205.8398T264 1 0 0 0 1 0 0
-M205.839T273 1 0 0 0 1 0 0
-M205.8401T322 1 0 0 0 1 0 0
-M206.8403T273 1 0 0 0 1 0 0
-M207.0654T373 1 0 0 1 1 0 1
-M207.0661T267 1 0 0 0 1 1 0
-M207.066T243 1 0 0 1 0 1 1
-M207.1386T512 1 0 0 0 1 0 1
-M207.8358T251 1 0 0 0 1 0 0
-M207.8364T207 1 0 0 0 1 0 0
-M207.8364T217 1 0 0 0 1 0 0
-M207.8364T245 1 0 0 0 1 0 0
-M207.8365T363 1 0 0 0 1 0 0
-M207.8366T347 1 0 0 0 1 0 0
-M207.8368T238 1 0 0 0 1 0 0
-M207.9308T206 1 1 0 0 1 0 0
-M207.9308T302 1 0 0 0 1 0 0
-M207.9308T311 1 1 0 0 1 0 0
-M208.0692T243 1 0 0 0 0 1 0
-M210.9378T464 1 1 0 0 1 1 0
-M210.9385T503 1 1 0 0 1 1 0
-M210.9388T632 1 1 0 0 1 0 0
-M210.9391T578 1 1 0 0 1 0 0
-M211.0388T319 1 0 0 1 0 1 1
-M211.0395T228 1 0 0 1 0 0 1
-M211.039T418 1 0 0 1 0 0 0
-M211.0607T263 1 0 0 0 1 0 1
-M211.0755T367 1 0 0 1 1 0 1
-M212.0743T273 1 1 0 0 1 0 0
-M212.1367T256 1 1 0 0 1 0 0
-M217.0506T407 1 0 0 0 0 0 1
-M217.8836T288 1 0 0 0 1 0 1
-M219.1389T250 1 1 0 0 1 0 0
-M221.0817T230 1 0 0 0 0 0 1
-M221.0819T313 1 0 0 1 0 1 1
-M221.1545T359 1 0 0 1 0 1 1
-M221.1907T677 1 1 0 1 0 0 0
-M222.9577T319 1 1 0 0 1 0 0
-M222.9579T348 1 1 0 0 1 0 0
-M222.9585T217 1 1 0 0 1 0 0
-M222.9585T226 1 1 0 0 1 0 0
-M222.9585T465 1 1 0 0 1 0 0
-M222.9586T206 1 1 0 0 1 0 0
-M222.9586T239 1 1 0 0 1 0 0
-M222.9586T326 1 1 0 0 1 0 0
-M222.9586T818 1 1 0 0 1 0 0
-M222.9586T827 1 1 0 0 1 0 0
-M222.9587T335 1 1 0 0 1 0 0
-M222.958T245 1 1 0 0 1 0 0
-M222.958T307 1 1 0 0 1 0 0
-M223.0971T254 1 1 0 0 1 0 0
-M223.0972T392 1 0 0 1 0 0 1
-M223.1701T415 1 0 0 0 1 0 1
-M223.2066T590 1 0 0 1 0 0 0
-M224.0475T263 1 0 0 0 1 0 1
-M224.9538T465 1 1 0 0 1 0 0
-M225.0555T347 1 0 0 0 0 1 0
-M225.1492T219 1 0 0 0 0 0 1
-M226.063T307 1 1 0 0 1 0 1
-M227.0337T239 1 0 0 1 0 0 1
-M227.0337T297 1 0 0 1 0 0 1
-M230.9242T307 1 1 0 0 1 1 0
-M231.1021T437 1 0 0 1 0 1 0
-M231.9313T509 1 1 0 0 1 1 0
-M233.0821T333 1 0 0 0 0 1 0
-M234.0851T333 1 0 0 0 0 1 0
-M235.0975T362 1 0 0 0 0 0 1
-M235.8222T811 1 1 0 0 1 1 0
-M236.1009T363 1 0 0 0 1 0 1
-M238.8458T327 1 1 0 0 1 1 0
-M239.0703T450 1 0 0 0 0 1 0
-M239.0705T263 1 1 0 0 1 0 1
-M239.0713T322 1 0 0 1 0 0 1
-M239.092T226 1 0 0 0 0 0 1
-M239.2014T293 1 0 0 1 0 0 0
-M239.201T299 1 0 0 0 1 1 0
-M241.0506T270 1 0 0 1 0 1 0
-M241.0507T327 1 0 0 1 0 0 0
-M241.0508T258 1 0 0 1 1 0 1
-M241.0881T263 1 0 0 1 1 0 1
-M242.0543T326 1 0 0 1 1 0 1
-M243.0659T229 1 0 0 1 0 0 1
-M243.1968T424 1 0 0 1 0 0 1
-M243.1969T605 1 0 0 1 0 0 0
-M246.9633T231 1 1 0 0 1 1 0
-M247.1344T557 1 0 0 0 0 1 0
-M247.1344T570 1 0 0 0 0 1 0
-M249.1135T417 1 0 0 0 0 1 0
-M249.1136T427 1 0 0 0 0 1 1
-M249.1864T510 1 0 0 1 0 1 0
-M349.2383T700 1 0 1 0 1 0 0
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c w4mcorcov.xml
--- a/w4mcorcov.xml Mon Oct 16 14:56:52 2017 -0400
+++ b/w4mcorcov.xml Sun Oct 22 18:47:57 2017 -0400
[
b'@@ -1,4 +1,4 @@\n-<tool id="w4mcorcov" name="OPLS-DA_Contrasts" version="0.98.2">\n+<tool id="w4mcorcov" name="OPLS-DA_Contrasts" version="0.98.3">\n \n   <description>OPLS-DA Contrasts of Univariate Results</description>\n   \n@@ -31,9 +31,9 @@\n   <inputs>\n     <param name="dataMatrix_in" label="Data matrix file" type="data" format="tabular" help="Features x samples (tabular data - decimal: \'.\'; missing: NA; mode: numerical; separator: tab character)" />\n     <param name="sampleMetadata_in" label="Sample metadata file" type="data" format="tabular" help="Samples x metadata (tabular data - decimal: \'.\'; missing: NA; mode: character or numerical; separator: tab character)" />\n-    <param name="variableMetadata_in" label="Variable metadata file (from Univariate)" type="data" format="tabular" help="Features x metadata (tabular data - decimal: \'.\'; missing: NA; mode: character or numerical; separator: tab character)" />\n-    <param name="facC" label="Factor of interest" type="text" help="The name of the column of sampleMetadata corresponding to the qualitative variable used to define the contrasts.  This also must be a portion of the column names in the variableMetadata file except when the \'Univariate Significance-test\' is set to \'none\'."/>\n-    <param name="tesC" label="Univariate Significance-Test" type="select" help="Either \'none\' or the name of the statistical test that was run by the \'Univariate\' tool to produce the variableMetadata file; that name must also be a portion of the column names in that file">\n+    <param name="variableMetadata_in" label="Variable metadata file (ideally from Univariate)" type="data" format="tabular" help="Features x metadata (tabular data - decimal: \'.\'; missing: NA; mode: character or numerical; separator: tab character)" />\n+    <param name="facC" label="Factor of interest" type="text" help="REQUIRED - The name of the column of sampleMetadata corresponding to the qualitative variable used to define the contrasts.  Except when the \'Univariate Significance-test\' is set to \'none\', this also must be a portion of the column names in the variableMetadata file."/>\n+    <param name="tesC" label="Univariate Significance-Test" type="select" help="Either \'none\' or the name of the statistical test that was run by the \'Univariate\' tool to produce the variableMetadata file; that name must also be a portion of the column names in that file.">\n       <option value="none">none - Display all features from variableMetadata (rather than choosing a subset based on significance in univariate testing)</option>\n       <option value="ttest">ttest - Student\'s t-test (parametric test, qualitative factor with exactly 2 levels)</option>\n       <option value="anova">anova - Analysis of variance (parametric test, qualitative factor with more than 2 levels)</option>\n@@ -47,8 +47,8 @@\n       truevalue="TRUE"\n       falsevalue="FALSE"\n       label="Retain only pairwise-significant features"\n-      help="Ignored when \'none\' is chosen.  Otherwise, when \'Yes\', analyze only features that differ significantly for the pair of levels being contrasted; when \'No\', include any feature that varies significantly across all levels."/>\n-    <param name="levCSV" label="Levels of interest" type="text" value = "" help="Comma-separated level-names (or comma-less regular expressions to match level-names) to consider in analysis; must match at least two levels; may include wild cards or regular expressions">\n+      help="When \'none\' is chosen, all features are included in the analysis.  Otherwise, when this option is set to \'Yes\', analysis will be performed including only features that differ significantly for the pair of levels being contrasted; when set to \'No\', any feature that varies significantly across all levels will be included (i.e., exclude any feature that is not significantly different across all levels).  See examples below."/>\n+    <param name="levCSV" label="Levels of interest" type="text" value = "*" help="Comma-separated level-names (or'..b'---------------------------------------------------------------------------------------------------------------------------------+\n+  | Level-name matching                        | use regular expressions for matching level-names                                                                                       |\n+  +--------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+\n+  | Number of features having extreme loadings | 3                                                                                                                                      |\n+  +--------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+\n+  | Output primary table                       | https://raw.githubusercontent.com/HegemanLab/w4mcorcov_galaxy_wrapper/master/test-data/expected_contrast_corcov_lohi.tsv               |\n+  +--------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+\n+  | Output salience table                      | https://raw.githubusercontent.com/HegemanLab/w4mcorcov_galaxy_wrapper/master/test-data/expected_contrast_salience_lohi.tsv             |\n+  +--------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+\n+  | Output figures PDF                         | https://raw.githubusercontent.com/HegemanLab/w4mcorcov_galaxy_wrapper/master/test-data/expected_contrast_detail_lohi.pdf               |\n+  +--------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------+\n \n \n Trademarks\n@@ -541,7 +624,16 @@\n Release notes\n -------------\n \n-v0.98.2 - first release\n+0.98.3\n+\n+- add support for two-level factors\n+- add adjusted mz and rt to output tables\n+- allow explicitly setting the number of features with extreme loadings to be labeled on the correlation vs. covariance plot\n+- add loadings to corcov table\n+\n+0.98.2\n+\n+- first release\n \n \n   ]]></help>\n@@ -556,21 +648,23 @@\n     <citation type="doi">10.1186/1748-7188-6-27</citation>\n     <!-- Rajalahti_2009 Biomarker discovery using selectivity ratio -->\n     <citation type="doi">10.1016/j.chemolab.2008.08.004</citation>\n+    <!-- Rinuardo 2016 -->\n+    <citation type="doi">10.3389/fmolb.2016.00026</citation>\n     <!-- Sun_2016 Urinary Biomarkers for adolescent idiopathic scoliosis -->\n     <citation type="doi">10.1038/srep22274</citation>\n     <!-- Th_venot_2015 Urinary metabolome statistics -->\n     <citation type="doi">10.1021/acs.jproteome.5b00354</citation>\n     <!-- ropls package -->\n     <citation type="bibtex"><![CDATA[\n-@incollection{Thevenot_ropls_2017,\n-    author = {Th{\\\'{e}}venot, Etienne A.},\n-    title = {ropls: PCA, PLS(-DA) and OPLS(-DA) for multivariate analysis and feature selection of omics data},\n-    publisher = {bioconductor.org},\n-    year = {2017},\n-    doi = {10.18129/B9.bioc.ropls},\n-    booktitle = {Bioconductor: Open source software for bioinformatics},\n-    address = {Roswell Park Cancer Institute},\n-}\n+    @incollection{Thevenot_ropls_2017,\n+      author = {Th{\\\'{e}}venot, Etienne A.},\n+      title = {ropls: PCA, PLS(-DA) and OPLS(-DA) for multivariate analysis and feature selection of omics data},\n+      publisher = {bioconductor.org},\n+      year = {2017},\n+      doi = {10.18129/B9.bioc.ropls},\n+      booktitle = {Bioconductor: Open source software for bioinformatics},\n+      address = {Roswell Park Cancer Institute},\n+    }\n     ]]></citation>\n     <!-- Wiklund_2008 OPLS PLS-DA and S-PLOT -->\n     <citation type="doi">10.1021/ac0713510</citation>\n'
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c w4mcorcov_calc.R
--- a/w4mcorcov_calc.R Mon Oct 16 14:56:52 2017 -0400
+++ b/w4mcorcov_calc.R Sun Oct 22 18:47:57 2017 -0400
[
b'@@ -8,11 +8,7 @@\n algoC <- "nipals"\n \n do_detail_plot <- function(x_dataMatrix, x_predictor, x_is_match, x_algorithm, x_prefix, x_show_labels, x_progress = print, x_env) {\n-  off <- function(x) if (x_show_labels) x else 0\n-  salience_lookup <- x_env$salience_lookup\n-  salient_rcv_lookup <- x_env$salient_rcv_lookup\n-  # x_progress("head(salience_df): ", head(salience_df))\n-  # x_progress("head(salience): ", head(salience))\n+  off <- function(x) if (x_show_labels == "0") x else 0\n   if (x_is_match && ncol(x_dataMatrix) > 0 && length(unique(x_predictor))> 1) {\n     my_oplsda <- opls(\n         x      = x_dataMatrix\n@@ -39,24 +35,20 @@\n         covariance <- covariance / lim_x\n         lim_x <- 1.2\n         main_label <- sprintf("%s for levels %s versus %s", x_prefix, fctr_lvl_1, fctr_lvl_2)\n-        # print("main_label")\n-        # print(main_label)\n         main_cex <- min(1.0, 46.0/nchar(main_label))\n         # "It is generally accepted that a variable should be selected if vj>1, [27\xe2\x80\x9329],\n         #   but a proper threshold between 0.83 and 1.21 can yield more relevant variables according to [28]."\n         #   (Mehmood 2012 doi:10.1186/1748-7188-6-27)\n         vipco <- pmax(0, pmin(1,(vip4p-0.83)/(1.21-0.83)))\n         alpha <- 0.1 + 0.4 * vipco\n-        red  <- as.numeric(correlation < 0) * vipco\n-        blue <- as.numeric(correlation > 0) * vipco\n-        minus_cor <- -correlation\n-        minus_cov <- -covariance\n-        # cex <- salience_lookup(feature = names(minus_cor))\n-        # cex <- 0.25 + (1.25 * cex / max(cex))\n+        red  <- as.numeric(correlation > 0) * vipco\n+        blue <- as.numeric(correlation < 0) * vipco\n+        plus_cor <- correlation\n+        plus_cov <- covariance\n         cex <- 0.75\n         plot(\n-          y = minus_cor\n-        , x = minus_cov\n+          y = plus_cor\n+        , x = plus_cov\n         , type="p"\n         , xlim=c(-lim_x, lim_x + off(0.1))\n         , ylim=c(-1.0 - off(0.1), 1.0)\n@@ -70,14 +62,31 @@\n         )\n         low_x <- -0.7 * lim_x\n         high_x <- 0.7 * lim_x\n-        text(x = low_x, y = -0.15, labels =  fctr_lvl_1)\n-        text(x = high_x, y = 0.15, labels =  fctr_lvl_2)\n-        if (x_show_labels) {\n+        text(x = low_x, y = -0.05, labels =  fctr_lvl_1)\n+        text(x = high_x, y = 0.05, labels =  fctr_lvl_2)\n+        if ( x_show_labels != "0" ) {\n+          my_loadp <- loadp\n+          my_loado <- loado\n+          names(my_loadp) <- tsv1$featureID\n+          names(my_loado) <- tsv1$featureID\n+          if ( x_show_labels == "ALL" ) {\n+            n_labels <- length(loadp)\n+          } else {\n+            n_labels <- as.numeric(x_show_labels)\n+          }\n+          n_labels <- min( n_labels, (1 + length(loadp)) / 2 )\n+          labels_to_show <- c(\n+            names(head(sort(my_loadp),n = n_labels))\n+          , names(head(sort(my_loado),n = n_labels))\n+          , names(tail(sort(my_loadp),n = n_labels))\n+          , names(tail(sort(my_loado),n = n_labels))\n+          )\n+          labels <- unname(sapply( X = tsv1$featureID, FUN = function(x) if( x %in% labels_to_show ) x else "" ))\n           text(\n-            y = minus_cor - 0.013\n-          , x = minus_cov + 0.020\n+            y = plus_cor - 0.013\n+          , x = plus_cov + 0.020\n           , cex = 0.3\n-          , labels = tsv1$featureID\n+          , labels = labels\n           , col = rgb(blue = blue, red = red, green = 0, alpha = 0.2 + 0.8 * alpha)\n           , srt = -30 # slant 30 degrees downward\n           , adj = 0   # left-justified\n@@ -162,6 +171,14 @@\n     return ( FALSE )\n   }\n \n+  mz             <- vrbl_metadata$mz\n+  names(mz)      <- vrbl_metadata$variableMetadata\n+  mz_lookup      <- function(feature) unname(mz[feature])\n+  \n+  rt             <- vrbl_metadata$rt\n+  names(rt)      <- vrbl_metadata$variableMetadata\n+  rt_lookup      <- function(feature) unname(rt[feature])\n+  \n   # calculate salience_df as data.frame(feature, max_level, max_median, max_rcv, mean_median, salience, salient_'..b'pply( X = chosen_facC, FUN = function(fac) if ( fac == fctr_lvl_1 ) fctr_lvl_1 else fctr_lvl_2 )\n-            my_matrix <- scdm[ chosen_samples, , drop = FALSE ]\n-            # only process this column if both factors are members of lvlCSV\n-            is_match <- isLevelSelected(fctr_lvl_1)\n-            my_cor_cov <- do_detail_plot(\n-              x_dataMatrix  = my_matrix\n-            , x_predictor   = predictor\n-            , x_is_match    = is_match\n-            , x_algorithm   = algoC\n-            , x_prefix      = "Features"\n-            , x_show_labels = labelFeatures\n-            , x_progress    = progress_action\n-            , x_env         = calc_env\n-            )\n-            if ( is.null(my_cor_cov) ) {\n-              progress_action("NOTHING TO PLOT")\n-            } else {\n-              tsv <- my_cor_cov$tsv1\n-              # tsv$salientLevel <- salient_level_lookup(tsv$featureID)\n-              # tsv$salientRCV   <- salient_rcv_lookup(tsv$featureID)\n-              # tsv$salience     <- salience_lookup(tsv$featureID)\n-              corcov_tsv_action(tsv)\n-              did_plot <<- TRUE\n-            }\n-          }\n-          #print("baz")\n-          "dummy" # need to return a value; otherwise combn fails with an error\n-        }\n-      )\n+        )\n+      }\n       ## pass 2 - contrast each selected level with each of the other levels individually ##\n       completed <- c()\n       utils::combn(\n@@ -436,9 +455,8 @@\n               progress_action("NOTHING TO PLOT")\n             } else {\n               tsv <- my_cor_cov$tsv1\n-              # tsv$salientLevel <- salient_level_lookup(tsv$featureID)\n-              # tsv$salientRCV   <- salient_rcv_lookup(tsv$featureID)\n-              # tsv$salience     <- salience_lookup(tsv$featureID)\n+              tsv$mz <- mz_lookup(tsv$featureID)\n+              tsv$rt <- rt_lookup(tsv$featureID)\n               corcov_tsv_action(tsv)\n               did_plot <<- TRUE\n             }\n@@ -510,22 +528,30 @@\n   #    Length = number of features; labels = feature identifiers.  (The same is true for $correlation and $covariance.)\n   result$vip4p     <- as.numeric(ropls_x@vipVn)\n   result$vip4o     <- as.numeric(ropls_x@orthoVipVn)\n+  result$loadp     <- as.numeric(ropls_x@loadingMN)\n+  result$loado     <- as.numeric(ropls_x@orthoLoadingMN)\n   # get the level names\n   level_names      <- sort(levels(as.factor(ropls_x@suppLs$y)))\n+  fctr_lvl_1       <- level_names[1]\n+  fctr_lvl_2       <- level_names[2]\n   feature_count    <- length(ropls_x@vipVn)\n-  result$level1    <- rep.int(x = level_names[1], times = feature_count)\n-  result$level2    <- rep.int(x = level_names[2], times = feature_count)\n+  result$level1    <- rep.int(x = fctr_lvl_1, times = feature_count)\n+  result$level2    <- rep.int(x = fctr_lvl_2, times = feature_count)\n   # print(sprintf("sd(covariance) = %f; sd(correlation) = %f", sd(result$covariance), sd(result$correlation)))\n   superresult <- list()\n   if (length(result$vip4o) == 0) result$vip4o <- NA\n+  greaterLevel <- sapply( X = result$correlation, FUN = function(my_corr) if ( my_corr < 0 ) fctr_lvl_1 else fctr_lvl_2 )\n   superresult$tsv1 <- data.frame(\n     featureID           = names(ropls_x@vipVn)\n   , factorLevel1        = result$level1\n   , factorLevel2        = result$level2\n+  , greaterLevel        = greaterLevel\n   , correlation         = result$correlation\n   , covariance          = result$covariance\n   , vip4p               = result$vip4p\n   , vip4o               = result$vip4o\n+  , loadp               = result$loadp\n+  , loado               = result$loado\n   , row.names           = NULL\n   )\n   rownames(superresult$tsv1) <- superresult$tsv1$featureID\n@@ -533,6 +559,8 @@\n   superresult$correlation <- result$correlation\n   superresult$vip4p <- result$vip4p\n   superresult$vip4o <- result$vip4o\n+  superresult$loadp <- result$loadp\n+  superresult$loado <- result$loado\n   superresult$details <- result\n   # #print(superresult$tsv1)\n   result$superresult <- superresult\n'
b
diff -r 23f9fad4edfc -r 0c2ad44b6c9c w4mcorcov_wrapper.R
--- a/w4mcorcov_wrapper.R Mon Oct 16 14:56:52 2017 -0400
+++ b/w4mcorcov_wrapper.R Sun Oct 22 18:47:57 2017 -0400
[
@@ -72,7 +72,25 @@
 my_env$pairSigFeatOnly <- as.logical(argVc["pairSigFeatOnly"])
 my_env$levCSV          <- as.character(argVc["levCSV"])
 my_env$matchingC       <- as.character(argVc["matchingC"])
-my_env$labelFeatures   <- as.logical(argVc["labelFeatures"])
+my_env$labelFeatures   <- as.character(argVc["labelFeatures"]) # number of features to label at each extreme of the loadings or 'ALL'
+
+label_features <- my_env$labelFeatures
+labelfeatures_check <- TRUE
+if ( is.na(label_features) ) {
+  labelfeatures_check <- FALSE
+} else if ( is.null(label_features) ) {
+  labelfeatures_check <- FALSE
+} else if (label_features != "ALL") {
+  if ( is.na(as.numeric(label_features)) )
+    labelfeatures_check <- FALSE
+  else if ( as.numeric(label_features) < 0 )
+    labelfeatures_check <- FALSE
+}
+if ( !labelfeatures_check ) {
+  my_log("invalid argument: labelFeatures")
+  print(label_features)
+  quit(save = "no", status = 10, runLast = TRUE)
+}
 
 tsv_action_factory <- function(file, colnames, append) {
   return (