OSCR

SOX12 and DELTA mediate ecdysone-driven adult neural cell proliferation during metamorphosis

Code ↔ Paper

1 match between paragraphs of the paper and lines of its authors' code, computed by the harvester (lexical-v1). Click a colored paragraph or line to see its counterpart.

The 1 match
  1. [1] § Experimental Procedures › RNA-seq data analysis ↔ src/process_argv.cpp, lines 1013–1150 · score 0.52 · SOAPnuke, contamination, adapters, threshold, quality, raw

Paper

Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC

The paper is loaded when this pane is shown.

The authors' code

C++ · 1,638 lines · 53 KB · GPL-3.0 · 1 match

  1. #include "process_argv.h"
  2. #include <stdlib.h>
  3. #include <iostream>
  4. #include <stdio.h>
  5. #include <getopt.h>
  6. #include <map>
  7. #include <fstream>
  8. #include "global_parameter.h"
  9. #include "sys/sysinfo.h"
  10. // #include <string>
  11. using namespace ::std;
  12. #define ADA_RATIO 0.4
  13. map<string, vector<string>> wrong_paras;
  14. void check_module(int argc, char *argv[])
  15. {
  16. if (argc < 2)
  17. {
  18. printModule();
  19. }
  20. else
  21. {
  22. set<string> modules;
  23. modules.insert("filter");
  24. modules.insert("filtersRNA");
  25. modules.insert("filterMeta");
  26. #ifdef _PROCESSHTS
  27. modules.insert("filterHts");
  28. #endif
  29. modules.insert("filterStLFR");
  30. string module = argv[1];
  31. if (modules.find(module) == modules.end())
  32. {
  33. if (module == "-h" || module == "--help")
  34. {
  35. printModule();
  36. }
  37. else if (module == "-v" || module == "--version")
  38. {
  39. printVersion();
  40. }
  41. else
  42. {
  43. if (module == "filterHts")
  44. {
  45. cout
  46. << "Error:filterHts module not installed, please re-make after set USEHTS true in Makefile, details see Install part in Readme"
  47. << endl;
  48. }
  49. cerr << "Error:no such module,type -h/--help for help" << endl;
  50. exit(1);
  51. }
  52. }
  53. else
  54. {
  55. if (argc == 2)
  56. {
  57. if (module == "filterHts")
  58. {
  59. printHtsUsage();
  60. }
  61. else
  62. {
  63. printUsage(module);
  64. }
  65. }
  66. }
  67. }
  68. }
  69. int global_parameter_initial(int argc, char *argv[], C_global_parameter &gp)
  70. {
  71. // const char *shortOptions = "f:r:1:2:K:M:A:l:T:q:n:m:p:d3in:N:t:e:c:SO:P:Q:L:I:G:a:o:C:D:R:W:5:6:7:8:9:Eb:x:y:z:hv";
  72. string c_module(argv[1]);
  73. // const char *shortOptions ="j1:2:R:W:C:D:o:5:8:E:Jaf:r:Z:z:c:d:k:Y:K:F:iQ:G:l:q:m:x:y:n:p:g:X:t:B:O:P:7e:T:3:4:L:w:M:A:9:S:s:U:u:b:0:hv";
  74. const char *shortOptions = "j1:2:C:D:o:c:E:Jf:r:l:q:m:x:y:n:p:g:X:t:T:3:4:L:w:hv";
  75. // move some uncommonly used parameters to config file
  76. // include RW58aZzYcdkKFiBOP7eMA9SsUub0QG
  77. const struct option longOptions[] = {
  78. // common parameter
  79. // input and output file
  80. //{"mode",1,NULL,'E'},
  81. {"streaming", 0, NULL, 'j'},
  82. {"fq1", 1, NULL, '1'},
  83. {"fq2", 1, NULL, '2'},
  84. // { "trimFq1" , 1, NULL, 'R' },//uncommonly used parameters
  85. // { "trimFq2" , 1, NULL, 'W' },//uncommonly used parameters
  86. {"cleanFq1", 1, NULL, 'C'},
  87. {"cleanFq2", 1, NULL, 'D'},
  88. {"outDir", 1, NULL, 'o'},
  89. {"configFile", 1, NULL, 'c'},
  90. // input and output file type
  91. // { "seqType" , 1, NULL, '5' },//uncommonly used parameters
  92. // {"outFileType",1,NULL,'8'},//uncommonly used parameters
  93. // reference for cram input
  94. {"ref", 1, NULL, 'E'},
  95. {"ada_trim", 0, NULL, 'J'},
  96. // {"contam_trim",0,NULL,'a'},//uncommonly used parameters
  97. {"adapter1", 1, NULL, 'f'},
  98. {"adapter2", 1, NULL, 'r'},
  99. // { "contam1" , 1, NULL, 'Z' },//uncommonly used parameters
  100. // { "contam2" , 1, NULL, 'z' },//uncommonly used parameters
  101. // { "ctMatchR" , 1,NULL,'Y'},//uncommonly used parameters
  102. //
  103. // { "global_contams",1,NULL,'c'},//uncommonly used parameters
  104. // //uncommonly used parameters
  105. // { "glob_cotm_mR",1,NULL,'d'},//uncommonly used parameters
  106. // { "glob_cotm_mM",1,NULL,'k'},//uncommonly used parameters
  107. // { "tile" , 1, NULL, 'K' },//uncommonly used parameters
  108. // { "fov" , 1, NULL, 'F' },//uncommonly used parameters
  109. // //index remove
  110. // { "index" , 0, NULL, 'i' },//uncommonly used parameters
  111. //
  112. // //base quality
  113. // { "qualSys" , 1, NULL, 'Q' },//uncommonly used parameters
  114. // { "outQualSys" , 1, NULL, 'G' },//uncommonly used parameters
  115. {"lowQual", 1, NULL, 'l'},
  116. {"qualRate", 1, NULL, 'q'},
  117. {"mean", 1, NULL, 'm'},
  118. {"trimBadHead", 1, NULL, 'x'},
  119. {"trimBadTail", 1, NULL, 'y'},
  120. // base content
  121. {"nRate", 1, NULL, 'n'},
  122. {"highA", 1, NULL, 'p'},
  123. {"polyG_tail", 1, NULL, 'g'},
  124. {"polyX", 1, NULL, 'X'},
  125. {"trim", 1, NULL, 't'},
  126. // { "TtoU" , 0, &TtoU, 1 },
  127. // { "UtoT" , 0, &UtoT, 1 },
  128. // {"baseConvert",1,NULL,'B'},//uncommonly used parameters
  129. // //{ "small" , 0, NULL, 'S' },
  130. // //PE reads
  131. // { "overlap" , 1, NULL, 'O' },//uncommonly used parameters
  132. // { "mis" , 1, NULL, 'P' },//uncommonly used parameters
  133. // { "pe_info" , 0, NULL, '7' },//uncommonly used parameters
  134. // //computer resource
  135. // { "patch" , 1, NULL, 'e' },//uncommonly used parameters
  136. {"thread", 1, NULL, 'T'},
  137. //{ "split_line",1,NULL, '6'},
  138. // read length limit
  139. // {"maxReadLen",1,NULL,'3'},//uncommonly used parameters
  140. {"minReadLen", 1, NULL, '4'},
  141. // reads number limit
  142. // {"'totalReadsNum'" , 1, NULL, 'c' },
  143. // {"totalReadsNum",1,NULL,'L'},
  144. {"output_clean", 1, NULL, 'w'},
  145. // {"adaMis",1,NULL,'M'},//uncommonly used parameters
  146. // {"adaMR",1,NULL,'A'},//uncommonly used parameters
  147. // {"adaEdge",1,NULL,'9'},//uncommonly used parameters
  148. //
  149. // {"adaRCtg",1,NULL,'S'},//uncommonly used parameters
  150. // {"adaRAr",1,NULL,'s'},//uncommonly used parameters
  151. // {"adaRMa",1,NULL,'U'},//uncommonly used parameters
  152. // {"adaREr",1,NULL,'u'},//uncommonly used parameters
  153. // {"adaRMm",1,NULL,'b'},//uncommonly used parameters
  154. // { "append" , 1, NULL, 'a' },
  155. // { "log",1,NULL,'0'},//uncommonly used parameters
  156. {"help", 0, NULL, 'h'},
  157. {"version", 0, NULL, 'v'},
  158. {0, 0, 0, 0}};
  159. int nextOpt;
  160. gp.module_name = argv[1];
  161. if (gp.module_name == "filtersRNA")
  162. {
  163. gp.min_read_length = 18;
  164. gp.max_read_length = 49;
  165. }
  166. gp.log = "log";
  167. // int error=0;
  168. while (-1 != (nextOpt = getopt_long(argc, argv, shortOptions, longOptions, NULL)))
  169. {
  170. switch (nextOpt)
  171. {
  172. case 'E':
  173. gp.reference.assign(optarg);
  174. break;
  175. case 'j':
  176. gp.is_streaming = true;
  177. break;
  178. case '1':
  179. {
  180. gp.fq1_path.assign(optarg);
  181. if (gp.fq1_path.rfind(".gz") == gp.fq1_path.size() - 3)
  182. {
  183. gp.inputGzformat = true;
  184. }
  185. else
  186. {
  187. gp.inputGzformat = false;
  188. }
  189. break;
  190. }
  191. case '2':
  192. gp.fq2_path.assign(optarg);
  193. break;
  194. // case 'R':{
  195. // gp.trim_fq1.assign(optarg);
  196. // if(gp.trim_fq1.rfind(".gz")==gp.trim_fq1.size()-3){
  197. // gp.trimOutGzformat=true;
  198. // }else{
  199. // gp.trimOutGzformat=false;
  200. // }
  201. // break;
  202. // }
  203. // case 'W':gp.trim_fq2.assign(optarg);break;
  204. case 'C':
  205. {
  206. gp.clean_fq1.assign(optarg);
  207. if (gp.clean_fq1.rfind(".gz") == gp.clean_fq1.size() - 3)
  208. {
  209. gp.cleanOutGzFormat = true;
  210. }
  211. else
  212. {
  213. gp.cleanOutGzFormat = false;
  214. }
  215. break;
  216. }
  217. case 'D':
  218. gp.clean_fq2.assign(optarg);
  219. break;
  220. case 'o':
  221. gp.output_dir.assign(optarg);
  222. break;
  223. // case '5':gp.seq_type.assign(optarg);break;
  224. // case '8':gp.output_file_type.assign(optarg);break;
  225. case 'J':
  226. gp.adapter_discard_or_trim = "trim";
  227. break;
  228. // case 'a':gp.contam_discard_or_trim="trim";break;
  229. case 'f':
  230. {
  231. string validSeq = "ACGTacgtNn";
  232. ifstream ifAda1(optarg);
  233. if (!ifAda1)
  234. {
  235. gp.adapter1_seq.assign(optarg);
  236. gp.ada1s.push_back(gp.adapter1_seq);
  237. for (int i = 0; i < gp.adapter1_seq.size(); i++)
  238. {
  239. if (validSeq.find(gp.adapter1_seq[i]) == string::npos)
  240. {
  241. cerr << "Error:invalid character found in adapter:" << gp.adapter1_seq[i]
  242. << ". Only ACGTacgtNn are supported" << endl;
  243. exit(1);
  244. }
  245. }
  246. break;
  247. }
  248. else
  249. {
  250. cout << "input adapter1 list file:" << optarg << endl;
  251. string adaLine;
  252. while (getline(ifAda1, adaLine))
  253. {
  254. gp.ada1s.push_back(adaLine);
  255. }
  256. }
  257. ifAda1.close();
  258. break;
  259. }
  260. case 'r':
  261. {
  262. // gp.adapter2_seq.assign(optarg);break;
  263. string validSeq = "ACGTacgtNn";
  264. ifstream ifAda2(optarg);
  265. if (!ifAda2)
  266. {
  267. gp.adapter2_seq.assign(optarg);
  268. gp.ada2s.push_back(gp.adapter2_seq);
  269. for (int i = 0; i < gp.adapter2_seq.size(); i++)
  270. {
  271. if (validSeq.find(gp.adapter2_seq[i]) == string::npos)
  272. {
  273. cerr << "Error:invalid character found in adapter:" << gp.adapter2_seq[i]
  274. << ". Only ACGTacgtNn are supported" << endl;
  275. exit(1);
  276. }
  277. }
  278. break;
  279. }
  280. else
  281. {
  282. cout << "input adapter2 list file:" << optarg << endl;
  283. string adaLine;
  284. while (getline(ifAda2, adaLine))
  285. {
  286. gp.ada2s.push_back(adaLine);
  287. }
  288. }
  289. ifAda2.close();
  290. break;
  291. }
  292. // case 'Z':gp.contam1_seq.assign(optarg);break;
  293. case 'z':
  294. gp.contam2_seq.assign(optarg);
  295. break;
  296. // case 'c':gp.global_contams.assign(optarg);break;
  297. case 'c':
  298. initFromConfigFile(gp, optarg);
  299. break; //-c means config file path ,no longer for global contams
  300. // case 'd':gp.g_mrs.assign(optarg);break;
  301. // case 'k':gp.g_mms.assign(optarg);break;
  302. // case 'Y':gp.ctMatchR.assign(optarg);break;
  303. // case 'K':gp.tile.assign(optarg);break;
  304. // case 'F':gp.fov.assign(optarg);break;
  305. // case 'i':gp.index_remove = true;break;
  306. // case 'Q':{
  307. // gp.qualityPhred=atoi(optarg);
  308. // if(gp.qualityPhred==1){
  309. // gp.qualityPhred=64;
  310. // }else if(gp.qualityPhred==2){
  311. // gp.qualityPhred=33;
  312. // }
  313. // break;
  314. // }
  315. // case 'G':{
  316. // gp.outputQualityPhred=atoi(optarg);
  317. // if(gp.outputQualityPhred==1){
  318. // gp.outputQualityPhred=64;
  319. // }else if(gp.outputQualityPhred==2){
  320. // gp.outputQualityPhred=33;
  321. // }
  322. // break;
  323. // }
  324. case 'l':
  325. gp.lowQual = atoi(optarg);
  326. break;
  327. case 'q':
  328. gp.lowQualityBaseRatio = atof(optarg);
  329. break;
  330. case 'm':
  331. gp.meanQuality = atoi(optarg);
  332. break;
  333. case 'x':
  334. gp.trimBadHead.assign(optarg);
  335. break;
  336. case 'y':
  337. gp.trimBadTail.assign(optarg);
  338. break;
  339. case 'n':
  340. gp.n_ratio = atof(optarg);
  341. break;
  342. case 'p':
  343. gp.highA_ratio = atof(optarg);
  344. break;
  345. case 'g':
  346. gp.polyG_tail = atof(optarg);
  347. break;
  348. case 'X':
  349. gp.polyX_num = atof(optarg);
  350. break;
  351. case 't':
  352. gp.trim.assign(optarg);
  353. break;
  354. // case 'B':gp.base_convert.assign(optarg);break;
  355. // case 'O':gp.overlap_length=atoi(optarg);break;
  356. // case 'P':gp.peMismatchRatio=atof(optarg);break;
  357. // case '7':gp.whether_add_pe_info=true;break;
  358. // case 'e':gp.patchSize=atoi(optarg);break;
  359. case 'T':
  360. gp.threads_num = atoi(optarg);
  361. break;
  362. // case '6':gp.split_line=atoi(optarg);break;
  363. // case '3':gp.max_read_length=atoi(optarg);break;
  364. case '4':
  365. gp.min_read_length = atoi(optarg);
  366. break;
  367. // case 'L':{
  368. // string tmp_str;
  369. // tmp_str.assign(optarg);
  370. // if(tmp_str.find("head")==string::npos){
  371. // gp.total_reads_num_random=true;
  372. // //gp.catWhenrunning=false;
  373. // for(int i=0;i!=tmp_str.size();i++){
  374. // if(!isdigit(tmp_str[i]) && tmp_str[i]!='.'){
  375. // cerr<<"Error:-L value should be a positive integer or float"<<endl;
  376. // exit(1);
  377. // }
  378. // }
  379. // }else{
  380. // gp.total_reads_num_random=false;
  381. // tmp_str.erase(tmp_str.find("head"),4);
  382. // if(tmp_str.find(".")!=string::npos){
  383. // cerr<<"Error:-L value should be a integer when with head suffix"<<endl;
  384. // exit(1);
  385. // }else{
  386. // for(int i=0;i!=tmp_str.size();i++){
  387. // if(!isdigit(tmp_str[i])){
  388. // cerr<<"Error:-L value should be an integer when with head suffix"<<endl;
  389. // exit(1);
  390. // }
  391. // }
  392. // }
  393. // }
  394. //
  395. // float tmp_val=atof(optarg);
  396. // if(tmp_val==0){
  397. // cerr<<"Error:-L value should be a positive integer or float"<<endl;
  398. // exit(1);
  399. // }
  400. // gp.total_reads_num=tmp_val;
  401. // if(tmp_val<1){
  402. // gp.f_total_reads_ratio=tmp_val;
  403. // }else{
  404. // istringstream is_str(tmp_str);
  405. // is_str>>gp.l_total_reads_num;
  406. // }
  407. // if(gp.f_total_reads_ratio>0 && gp.l_total_reads_num>0){
  408. // cerr<<"Error:reads number and ratio should not be both assigned at the same time"<<endl;
  409. // exit(1);
  410. // }
  411. // break;
  412. // }
  413. case 'w':
  414. {
  415. string paraCheck(optarg);
  416. for (int i = 0; i != paraCheck.size(); i++)
  417. {
  418. if (!isdigit(paraCheck[i]))
  419. {
  420. cerr << "Error:-w value should be a positive integer" << endl;
  421. exit(1);
  422. }
  423. }
  424. gp.cleanOutSplit = atoi(paraCheck.c_str());
  425. if (gp.cleanOutSplit == 0)
  426. {
  427. cerr << "Error:-w value should be a positive integer" << endl;
  428. exit(1);
  429. }
  430. break;
  431. }
  432. // case 'M':{
  433. // wrong_paras["filtersRNA"].emplace_back("-M|--adaMis");
  434. // string tmp_str;
  435. // tmp_str.assign(optarg);
  436. // if(tmp_str.find(",")==string::npos){
  437. // gp.adaMis=atoi(optarg);
  438. // gp.adaMis2=gp.adaMis;
  439. // }else{
  440. // vector<string> values;
  441. // line_split(tmp_str,',',values);
  442. // if(values.size()<2){
  443. // cerr<<"Error:expected two values in -M parameter"<<endl;
  444. // exit(1);
  445. // }
  446. // gp.adaMis=atoi(values[0].c_str());
  447. // gp.adaMis2=atoi(values[1].c_str());
  448. // }
  449. // break;
  450. // }
  451. // case 'A':{
  452. // wrong_paras["filtersRNA"].emplace_back("-A|adaMR");
  453. // string tmp_str;
  454. // tmp_str.assign(optarg);
  455. // if(tmp_str.find(",")==string::npos){
  456. // gp.adaMR=atof(optarg);
  457. // gp.adaMR2=gp.adaMR;
  458. // }else{
  459. // vector<string> values;
  460. // line_split(tmp_str,',',values);
  461. // if(values.size()<2){
  462. // cerr<<"Error:expected two values in -A parameter"<<endl;
  463. // exit(1);
  464. // }
  465. // gp.adaMR=atof(values[0].c_str());
  466. // gp.adaMR2=atof(values[1].c_str());
  467. // }
  468. // break;
  469. // }
  470. // case '9':{
  471. // wrong_paras["filtersRNA"].emplace_back("-9|--adaEdge");
  472. // string tmp_str;
  473. // tmp_str.assign(optarg);
  474. // if(tmp_str.find(",")==string::npos){
  475. // gp.adaEdge=atoi(optarg);
  476. // gp.adaEdge2=gp.adaEdge;
  477. // }else{
  478. // vector<string> values;
  479. // line_split(tmp_str,',',values);
  480. // if(values.size()<2){
  481. // cerr<<"Error:expected two values in -9 parameter"<<endl;
  482. // exit(1);
  483. // }
  484. // gp.adaEdge=atoi(values[0].c_str());
  485. // gp.adaEdge2=atoi(values[1].c_str());
  486. // }
  487. // break;
  488. // }
  489. // case 'S':gp.adaRCtg=atoi(optarg);wrong_paras["filter"].emplace_back("-S|--adaRCtg");break;
  490. // case 's':gp.adaRAr=atof(optarg);wrong_paras["filter"].emplace_back("-s|--adaRAr");break;
  491. // case 'U':gp.adaRMa=atoi(optarg);wrong_paras["filter"].emplace_back("-U|--adaRMa");break;
  492. // case 'u':gp.adaREr=atof(optarg);wrong_paras["filter"].emplace_back("-u|--adaREr");break;
  493. // case 'b':gp.adaRMm=atoi(optarg);wrong_paras["filter"].emplace_back("-b|--adaRMm");break;
  494. // // case 'd':gp.rmdup = true;break;
  495. // case '0':gp.log.assign(optarg);break;
  496. case 'v':
  497. printVersion();
  498. return 1;
  499. case 'h':
  500. printUsage(c_module);
  501. return 1;
  502. default:
  503. {
  504. exit(1);
  505. }
  506. }
  507. }
  508. if (argc != optind + 1)
  509. {
  510. cerr << "Error:please check the options" << endl;
  511. exit(1);
  512. }
  513. if (!gp.rmdup || gp.cleanOutSplit <= 0)
  514. {
  515. }
  516. else
  517. {
  518. cerr << "Warning:generating split files(-w was set) would become slower when rmdup function was on" << endl;
  519. }
  520. if (gp.log.find("/") == string::npos)
  521. {
  522. gp.log = gp.output_dir + "/" + gp.log;
  523. }
  524. if (gp.fq1_path.rfind(".gz") != gp.fq1_path.size() - 3)
  525. {
  526. gp.mode = "ssd";
  527. }
  528. if (gp.patchSize == 0)
  529. {
  530. gp.patchSize = gp.threads_num * 20000 / 8;
  531. }
  532. /*
  533. int min_adapter_length=gp.adapter1_seq.size()>gp.adapter2_seq.size()?gp.adapter2_seq.size():gp.adapter1_seq.size();
  534. if(min_adapter_length>20){
  535. gp.adaEdge=min_adapter_length*ADA_RATIO;
  536. }
  537. */
  538. return 0;
  539. }
  540. bool check_parameter(int argc, char *argv[], C_global_parameter &gp)
  541. {
  542. // 对于filterHts模块不再做检查
  543. bool pe_data = false;
  544. if (gp.module_name != "filterHts")
  545. {
  546. if (!gp.fq1_path.empty())
  547. {
  548. if (file_exist_and_not_empty(gp.fq1_path) == 0)
  549. {
  550. cerr << "Error:input fastq1 is required" << endl;
  551. exit(1);
  552. }
  553. }
  554. else
  555. {
  556. cerr << "Error:input fastq1 is required" << endl;
  557. exit(1);
  558. }
  559. if (gp.output_dir.empty())
  560. {
  561. cerr << "Error:output directory is required" << endl;
  562. exit(1);
  563. }
  564. if (!gp.fq2_path.empty())
  565. {
  566. pe_data = true;
  567. if (file_exist_and_not_empty(gp.fq2_path) == 0)
  568. {
  569. cerr << "Error:input fastq2 is required" << endl;
  570. exit(1);
  571. }
  572. if (gp.fq1_path == gp.fq2_path)
  573. {
  574. cerr << "Error:input fq1 and fq2 are the same,please check the parameters" << endl;
  575. exit(1);
  576. }
  577. }
  578. if (gp.clean_fq1.empty())
  579. {
  580. cerr << "Error:output clean fastq is required" << endl;
  581. exit(1);
  582. }
  583. else
  584. {
  585. if (pe_data)
  586. {
  587. if (gp.clean_fq2.empty())
  588. {
  589. cerr << "Error:output clean fastq2 is required" << endl;
  590. exit(1);
  591. }
  592. if (!(
  593. gp.clean_fq1.rfind(".gz") == gp.clean_fq1.size() - 3 && gp.clean_fq2.rfind(".gz") == gp.clean_fq2.size() - 3) &&
  594. !(
  595. gp.clean_fq1.rfind(".gz") != gp.clean_fq1.size() - 3 && gp.clean_fq2.rfind(".gz") != gp.clean_fq2.size() - 3))
  596. {
  597. cerr << "Error:the format of clean fastq1 is inconsistent with fastq2" << endl;
  598. exit(1);
  599. }
  600. if (gp.cleanOutSplit > 0 || gp.total_reads_num > 0)
  601. {
  602. if (gp.clean_fq1.rfind(".gz") != gp.clean_fq1.size() - 3 && gp.clean_fq2.rfind(".gz") != gp.clean_fq2.size() - 3)
  603. {
  604. cerr << "Error:the clean out fastq should be non-gz format when clean output reads are limited"
  605. << endl;
  606. exit(1);
  607. }
  608. }
  609. }
  610. }
  611. if (!pe_data && gp.module_name != "filtersRNA")
  612. {
  613. if (!gp.adapter2_seq.empty())
  614. {
  615. cerr << "Error:no need adapter2" << endl;
  616. exit(1);
  617. }
  618. }
  619. if (!pe_data)
  620. {
  621. if (!gp.trim_fq2.empty() || !gp.clean_fq2.empty())
  622. {
  623. cerr << "Error:input file is not pe data" << endl;
  624. exit(1);
  625. }
  626. }
  627. else
  628. {
  629. if (!(
  630. gp.fq1_path.rfind(".gz") == gp.fq1_path.size() - 3 && gp.fq2_path.rfind(".gz") == gp.fq2_path.size() - 3) &&
  631. !(
  632. gp.fq1_path.rfind(".gz") != gp.fq1_path.size() - 3 && gp.fq2_path.rfind(".gz") != gp.fq2_path.size() - 3))
  633. {
  634. cerr << "Error:the format of input fastq1 is inconsistent with fastq2" << endl;
  635. exit(1);
  636. }
  637. }
  638. if (gp.seq_type != "0" && gp.seq_type != "1")
  639. {
  640. cerr << "Error:seq_type value should be 0 or 1" << endl;
  641. exit(1);
  642. }
  643. if (gp.output_file_type != "fastq" && gp.output_file_type != "fasta")
  644. {
  645. cerr << "Error:output_file_type value should be fastq or fasta" << endl;
  646. exit(1);
  647. }
  648. }
  649. if (gp.module_name == "filterStLFR")
  650. {
  651. // check barcode list file
  652. if (gp.barcodeListPath == "")
  653. {
  654. cerr << "Error:barcode list not assigned" << endl;
  655. exit(1);
  656. }
  657. else
  658. {
  659. ifstream bl(gp.barcodeListPath);
  660. if (!bl)
  661. {
  662. cerr << "Error:cannot open such file," << gp.barcodeListPath << endl;
  663. exit(1);
  664. }
  665. bl.close();
  666. }
  667. // check barcode region format
  668. if (gp.barcodeRegionStr.find("_") == string::npos)
  669. {
  670. cerr << "Error:barcode region format error, it should be set as 101_10,117_10,133_10" << endl;
  671. exit(1);
  672. }
  673. else
  674. {
  675. vector<string> eles;
  676. line_split(gp.barcodeRegionStr, ',', eles);
  677. if (eles.size() != 3)
  678. {
  679. cerr << "Error:barcode region format error, it should be set as 101_10,117_10,133_10" << endl;
  680. exit(1);
  681. }
  682. for (vector<string>::iterator ix = eles.begin(); ix != eles.end(); ix++)
  683. {
  684. vector<string> eles2;
  685. line_split(*ix, '_', eles2);
  686. if (eles2.size() != 2)
  687. {
  688. cerr << "Error:barcode region format error, it should be set as 101_10,117_10,133_10" << endl;
  689. exit(1);
  690. }
  691. }
  692. }
  693. }
  694. if (!gp.adapter_discard_or_trim.empty())
  695. {
  696. if (gp.adapter_discard_or_trim != "trim" && gp.adapter_discard_or_trim != "discard")
  697. {
  698. cerr << "Error:adapter_discard_or_trim value should be trim or discard" << endl;
  699. exit(1);
  700. }
  701. }
  702. if (!gp.tile.empty())
  703. {
  704. if (gp.tile.find("-") != string::npos)
  705. {
  706. vector<string> tmp_eles;
  707. line_split(gp.tile, '-', tmp_eles);
  708. string start, end;
  709. for (string::size_type ix = tmp_eles[0].size() - 1; ix >= 0; ix--)
  710. {
  711. if (!isalpha(tmp_eles[0][ix]))
  712. {
  713. start.insert(start.begin(), tmp_eles[0][ix]);
  714. }
  715. }
  716. for (string::size_type ix = tmp_eles[1].size() - 1; ix >= 0; ix--)
  717. {
  718. if (!isalpha(tmp_eles[1][ix]))
  719. {
  720. end.insert(end.begin(), tmp_eles[1][ix]);
  721. }
  722. }
  723. if (atoi(start.c_str()) > atoi(end.c_str()))
  724. {
  725. cerr << "Error:tile value format error" << endl;
  726. exit(1);
  727. }
  728. }
  729. for (string::size_type ix = 0; ix != gp.tile.size(); ix++)
  730. {
  731. if (!isalnum(gp.tile[ix]) && gp.tile[ix] != '-' && gp.tile[ix] != ',')
  732. {
  733. cerr << "Error:tile value format error" << endl;
  734. exit(1);
  735. }
  736. }
  737. }
  738. if (gp.qualityPhred != 64 && gp.qualityPhred != 33)
  739. {
  740. cerr << "Error:qualityPhred value error" << endl;
  741. exit(1);
  742. }
  743. if (gp.outputQualityPhred != 64 && gp.outputQualityPhred != 33)
  744. {
  745. cerr << "Error:outputQualityPhred value error" << endl;
  746. exit(1);
  747. }
  748. if (gp.module_name == "filter" || gp.module_name == "filterMeta")
  749. {
  750. if (wrong_paras["filter"].size() > 0)
  751. {
  752. cerr << "Error:these parameters should not appear in the module," << join_vector(wrong_paras["filter"], ',')
  753. << endl;
  754. exit(1);
  755. }
  756. }
  757. else
  758. {
  759. if (gp.module_name == "filtersRNA")
  760. {
  761. // adaMis,adaMR;
  762. if (wrong_paras["filtersRNA"].size() > 0)
  763. {
  764. cerr << "Error:these parameters should not appear in the module,"
  765. << join_vector(wrong_paras["filtersRNA"], ',') << endl;
  766. exit(1);
  767. }
  768. }
  769. }
  770. if (gp.cleanOutSplit != 0 && gp.cleanOutSplit < gp.patchSize)
  771. {
  772. cerr << "Error: output reads in each clean fastq file(-w) should be more than patch size(-e)" << endl;
  773. exit(1);
  774. }
  775. if (gp.module_name != "filterHts")
  776. {
  777. if (!gp.trim.empty())
  778. {
  779. vector<string> tmp_eles;
  780. line_split(gp.trim, ',', tmp_eles);
  781. if (pe_data)
  782. {
  783. if (tmp_eles.size() != 4)
  784. {
  785. cerr << "Error:trim value format error" << endl;
  786. exit(1);
  787. }
  788. }
  789. else
  790. {
  791. if (tmp_eles.size() != 2)
  792. {
  793. cerr << "Error:trim value format error" << endl;
  794. exit(1);
  795. }
  796. }
  797. for (int i = 0; i < gp.trim.size(); i++)
  798. {
  799. if (!isdigit(gp.trim[i]) && gp.trim[i] != ',')
  800. {
  801. cerr << "Error:trim value format error:" << gp.trim << endl;
  802. cerr << "e.g.: -t 10 2 10 2" << endl;
  803. exit(1);
  804. }
  805. }
  806. }
  807. if (!gp.trimBadHead.empty())
  808. {
  809. vector<string> tmp_eles;
  810. line_split(gp.trimBadHead, ',', tmp_eles);
  811. if (pe_data)
  812. {
  813. if (tmp_eles.size() != 2)
  814. {
  815. cerr << "Error:trimBadHead value format error" << endl;
  816. exit(1);
  817. }
  818. }
  819. else
  820. {
  821. if (tmp_eles.size() != 1)
  822. {
  823. cerr << "Error:trimBadHead value format error" << endl;
  824. exit(1);
  825. }
  826. }
  827. }
  828. if (!gp.trimBadTail.empty())
  829. {
  830. vector<string> tmp_eles;
  831. line_split(gp.trimBadTail, ',', tmp_eles);
  832. if (pe_data)
  833. {
  834. if (tmp_eles.size() != 2)
  835. {
  836. cerr << "Error:trimBadTail value format error" << endl;
  837. exit(1);
  838. }
  839. }
  840. else
  841. {
  842. if (tmp_eles.size() != 1)
  843. {
  844. cerr << "Error:trimBadTail value format error" << endl;
  845. exit(1);
  846. }
  847. }
  848. }
  849. }
  850. if (!gp.base_convert.empty())
  851. {
  852. set<string> acgt_s;
  853. string tmp_s = "ACGTacgt";
  854. string tmp_single;
  855. for (string::size_type ix = 0; ix != tmp_s.size(); ix++)
  856. {
  857. tmp_single.insert(tmp_single.end(), tmp_s[ix]);
  858. acgt_s.insert(tmp_single);
  859. tmp_single = "";
  860. }
  861. if (gp.base_convert.find("TO") == string::npos && gp.base_convert.find("2") == string::npos)
  862. {
  863. cerr << "Error:base_convert value format error" << endl;
  864. exit(1);
  865. }
  866. else
  867. {
  868. string firstC = gp.base_convert.substr(0, 1);
  869. string lastC = gp.base_convert.substr(gp.base_convert.size() - 1, 1);
  870. if (acgt_s.find(firstC) == acgt_s.end() || acgt_s.find(lastC) == acgt_s.end())
  871. {
  872. cerr << "Error:base_convert value format error" << endl;
  873. exit(1);
  874. }
  875. }
  876. }
  877. if (gp.cleanOutSplit > 0 && gp.total_reads_num > 0)
  878. {
  879. cerr << "Error:-w and -L cannot be both assigned" << endl;
  880. exit(1);
  881. }
  882. if (gp.cleanOutSplit > 0)
  883. {
  884. gp.clean_file_reads = gp.cleanOutSplit;
  885. }
  886. else if (gp.l_total_reads_num > 0)
  887. {
  888. gp.clean_file_reads = gp.l_total_reads_num;
  889. }
  890. if (gp.threads_num > get_nprocs())
  891. {
  892. gp.threads_num = get_nprocs();
  893. cerr << "Warning:threads number exceeds the system cpu number" << endl;
  894. // exit(1);
  895. }
  896. if (gp.patchSize > 5000000)
  897. {
  898. cerr << "Error:patchSize cannot exceed 5M considering memory usage" << endl;
  899. exit(1);
  900. }
  901. return 0;
  902. }
  903. void printModule()
  904. {
  905. cout << endl;
  906. cout << "Program: SOAPnuke\n";
  907. cout << "Version: " << PACKAGEVERSION << "." << MINORVERSION << endl;
  908. cout << "Contact: GongChun<[email hidden]> ChenYuXin<[email hidden]>" << endl;
  909. cout << "Command:\n";
  910. cout << " filter preprocessing normal Fastq files\n";
  911. #ifdef _PROCESSHTS
  912. cout << " filterHts preprocessing BAM/CRAM files\n";
  913. #endif
  914. cout << " filterStLFR preprocessing stLFR Fastq files\n";
  915. cout << " filtersRNA preprocessing sRNA Fastq files\n";
  916. // cout << " filterDGE preprocessing DGE sequences\n"; //not include filterDGE in thie version
  917. cout << " filterMeta preprocessing Meta Fastq files\n";
  918. cout << endl;
  919. exit(1);
  920. }
  921. void printHtsUsage()
  922. {
  923. cout << "Usage: "
  924. << "filterHts"
  925. << " [OPTION]... \n";
  926. cout << "\ncommonly used parameters\n";
  927. cout << "\t-E, --ref\t\tFILE\t\treference file(required when process cram format)\n";
  928. cout << "\t-1, \t\t\tFILE\t\tinput bam/cram file(required)\n";
  929. cout << "\t-2, \t\t\tFILE\t\toutput bam/cram file(required)\n";
  930. cout << "\t-o, --outDir\tSTR\t\toutput directory, directory must exists\n";
  931. cout << "\n";
  932. cout << "\t-f, --adapter1\t\tSTR\t\tadapter sequence or list file of read1\n";
  933. cout << "\t-r, --adapter2\t\tSTR\t\tadapter sequence or list file of read2 (if PE)\n";
  934. cout << "\t-J, --ada_trim\t\t\t\ttrim read when find adapter[default:discard]\n";
  935. cout << "\t-T, --thread\t\tINT\t\tthreads number used in process[6]\n";
  936. cout
  937. << "\t-c, --configFile\tSTR\t\tconfig file which include uncommonly used parameters. Each line contains a parameter, for value needed parameter: adaMis=2, for bool parameter:contam_trim, which means change mode from discard to trim\n";
  938. cout << "\t-l, --lowQual\t\tINT\t\tlow quality threshold [default:5]\n";
  939. cout << "\t-q, --qualRate\t\tFLOAT\t\tlow quality rate [default:0.5]\n";
  940. cout << "\t-n, --nRate\t\tFLOAT\t\tN rate threshold [default:0.05]\n";
  941. cout << "\t-m, --mean\t\tFLOAT\t\tfilter reads with low average quality\n";
  942. cout << "\t-p, --highA\t\tFLOAT\t\tfilter reads if ratio of A in a read exceed [FLOAT]\n";
  943. cout << "\t-g, --polyG_tail\tFLOAT\t\tfilter reads if found polyG in tail [INT]\n";
  944. cout << "\t-X, --polyX\t\tINT\t\tfilter reads if a read contains polyX [INT]\n";
  945. cout << "\t-i, --index\t\t\t\tremove index\n";
  946. cout
  947. << "\t-L, --totalReadsNum\tINT/FLOAT\tnumber/fraction of reads you want to keep in the output clean fq file(cannot be assigned when -w is given).\n";
  948. cout
  949. << "\t \t\t\t\t\tIt will extract reads randomly through the total clean fq file by default, you also can get the head reads\n";
  950. cout << "\t \t\t\t\t\tfor save time by add head suffix to the integer(e.g. -L 10000000head)\n";
  951. cout << "\t-4, --minReadLen\tINT\t\tread min length,default 18 for filtersRNA,30 for other modules\n";
  952. cout << "\t-h, --help\t\t\t\thelp" << endl;
  953. cout << "\t-v, --version\t\t\t\tshow version" << endl;
  954. cout
  955. << "\tExample: ./SOAPnuke filterHts -l 10 -q 0.1 -n 0.01 -f AAGTCGGAGGCCAAGCGGTCTTAGGAAGACAA -r AAGTCGGATCGTAGCCATGTCGTTCTGTGAGCCAAGGAGTTG --ref chr21.fa -1 input.bam -2 output.cram -o result"
  956. << endl;
  957. cout << "\n";
  958. cout << "uncommonly used parameters, which should be set in config file" << endl;
  959. // cout << "\tcontam1\t\tSTR\t\tcontaminant sequence(s) for read1, split by comma\n";
  960. // cout << "\tcontam2\t\tSTR\t\tcontaminant sequence(s) for read2, split by comma\n";
  961. cout << "\tctMatchR\tFLOAT/STR\tcontam's shortest consistent matching ratio [default:0.2]\n";
  962. // cout << "\tglobal_contams\tSTR\t\tglobal contaminant sequences which need to be detected, split by comma if more than 1\n";
  963. // cout << "\tglob_cotm_mR\tSTR\t\tminimum match ratio in global contaminant sequences detection\n";
  964. // cout << "\tglob_cotm_mM\tSTR\t\tmaximum mismatch number in global contaminant sequences detection\n";
  965. cout << "\tseqType\t\tINT\t\tSequence fq name type, 0->old fastq name, 1->new fastq name [0]\n";
  966. cout << "\t\t\t\t\t\t\t\told fastq name: @FCD1PB1ACXX:4:1101:1799:2201#GAAGCACG/2\n";
  967. cout << "\t\t\t\t\t\t\t\tnew fastq name: @HISEQ:310:C5MH9ANXX:1:1101:3517:2043 2:N:0:TCGGTCAC\n";
  968. cout << "\ttile\t\tSTR\t\ttile number to ignore reads, such as [1101-1104,1205]\n";
  969. cout << "\tfov\t\tSTR\t\tfov number to ignore reads (only for zebra-platform data), such as [C001R003,C003R004]\n";
  970. cout << "\tAdapter related:\n";
  971. // cout << "\tcontam_trim\t\t\ttrim read when find contam[default:discard]\n";
  972. cout << "\tadaMis\t\tINT,[INT]\tthe max mismatch number when match the adapter (depend on -f/-r).If different values are required for fq1 and fq2, you can set two values seperated by comma,e.g. 1,2 (same as -A/-9)[1]\n";
  973. cout << "\tadaMR\t\tFLOAT,[FLOAT]\tadapter's shortest match ratio (depend on -f/-r) [0.5]\n";
  974. cout << "\tadaEdge\t\tINT,[INT]\tthe min length for segmental alignment [6]\n";
  975. cout << endl;
  976. cout << "\toverlap\t\tINT\t\tfilter the small insert size.Not filter until the value exceed 1[-1]\n";
  977. cout << "\tmis\t\tFLOAT\t\tthe maximum mismatch ratio when find overlap between PE reads(depend on -O)[0.1]\n";
  978. cout << "\n";
  979. cout << "\tpatch\t\tINT\t\treads number of a patch processed[400000]\n";
  980. cout << "\n";
  981. cout << "\tqualSys\t\tINT\t\tquality system 1:64, 2:33[default:2]\n";
  982. cout << "\toutQualSys\tINT\t\tout quality system 1:64, 2:33[default:2]\n";
  983. cout << "\tmaxReadLen\tINT\t\tread max length,default 49 for filtersRNA\n";
  984. cout << "\n";
  985. cout << "\tpe_info\t\t\t\tAdd /1, /2 at the end of fastq name.[default:not add]\n";
  986. cout << "\tbaseConvert\tSTR\t\tconvert base when write data,example:TtoU, means convert base T to base U in the output\n";
  987. cout << "\tlog\t\tSTR\t\tlog file\n";
  988. cout << "\n";
  989. exit(1);
  990. }
  991. void printUsage(string c_module)
  992. {
  993. cout << "Usage: " << c_module << " [OPTION]... \n";
  994. cout << "\ncommonly used parameters\n";
  995. // cout << "\t-E, --mode\t\tSTR\t\tif pigz software is available,you can assign ssd mode for accelerate(-E ssd). Default is non SSD\n";
  996. cout << "\t-1, --fq1\t\tFILE\t\tfq1 file(required), .gz or normal text format are both supported(required)\n";
  997. cout << "\t-2, --fq2\t\tFILE\t\tfq2 file(used when process PE data), format should be same as fq1 file, both are gz or both are normal text\n";
  998. cout << "\t-C, --cleanFq1\t\tSTR\t\treads which passed QC from fq1 file would output to this file\n";
  999. cout << "\t-D, --cleanFq2\t\tSTR\t\treads which passed QC from fq2 file would output to this file\n";
  1000. cout << "\t-o, --outDir\t\tSTR\t\tOutput directory. Processed fq files and statistical results would be output to here\n";
  1001. cout << "\t-f, --adapter1\t\tSTR\t\tadapter sequence or list file of read1\n";
  1002. cout << "\t-r, --adapter2\t\tSTR\t\tadapter sequence or list file of read2 (if PE)\n";
  1003. cout << "\t-J, --ada_trim\t\t\t\ttrim read when find adapter[default:discard]\n";
  1004. cout << "\t-T, --thread\t\tINT\t\tthreads number used in process[6]\n";
  1005. cout << "\t-c, --configFile\tSTR\t\tconfig file which include uncommonly used parameters. Each line contains a parameter, for value needed parameter: adaMis=2, for bool parameter:contam_trim, which means change mode from discard to trim\n";
  1006. cout << "\t-l, --lowQual\t\tINT\t\tlow quality threshold [default:5]\n";
  1007. cout << "\t-q, --qualRate\t\tFLOAT\t\tlow quality rate [default:0.5]\n";
  1008. cout << "\t-n, --nRate\t\tFLOAT\t\tN rate threshold [default:0.05]\n";
  1009. cout << "\t-m, --mean\t\tFLOAT\t\tfilter reads with low average quality\n";
  1010. cout << "\t-p, --highA\t\tFLOAT\t\tfilter reads if ratio of A in a read exceed [FLOAT]\n";
  1011. cout << "\t-g, --polyG_tail\tFLOAT\t\tfilter reads if found polyG in tail [INT]\n";
  1012. cout << "\t-X, --polyX\t\tINT\t\tfilter reads if a read contains polyX [INT]\n";
  1013. cout << "\t-4, --minReadLen\tINT\t\tread min length,default 18 for filtersRNA,30 for other modules\n";
  1014. cout << "\t-w, --cleanOutSplit\tINT\t\tmax reads number in each output clean fastq file\n";
  1015. cout << "\t-h, --help\t\t\t\thelp" << endl;
  1016. cout << "\t-v, --version\t\t\t\tshow version" << endl;
  1017. if (c_module == "filter")
  1018. {
  1019. cout
  1020. << "\tExample: ./SOAPnuke filter -l 10 -q 0.1 -n 0.01 -f AAGTCGGAGGCCAAGCGGTCTTAGGAAGACAA -r AAGTCGGATCGTAGCCATGTCGTTCTGTGAGCCAAGGAGTTG -1 test.r1.fq.gz -2 test.r2.fq.gz -C clean_1.fq.gz -D clean_2.fq.gz -o result -T 8"
  1021. << endl;
  1022. }
  1023. cout << "\n";
  1024. cout << "uncommonly used parameters, which should be set in config file" << endl;
  1025. // cout << "\tcontam1\t\tSTR\t\tcontaminant sequence(s) for fq1 file, split by comma\n";
  1026. // cout << "\tcontam2\t\tSTR\t\tcontaminant sequence(s) for fq2 file, split by comma. The two parameters is similar to -f/-r, but support a list of sequences\n";
  1027. cout << "\tAdapter related:\n";
  1028. cout << "\tctMatchR\tFLOAT/STR\tcontam's shortest consistent matching ratio [default:0.2]\n";
  1029. // cout << "\tglobal_contams\tSTR\t\tglobal contaminant sequences which need to be detected, split by comma if more than 1\n";
  1030. // cout << "\tglob_cotm_mR\tSTR\t\tminimum match ratio in global contaminant sequences detection\n";
  1031. // cout << "\tglob_cotm_mM\tSTR\t\tmaximum mismatch number in global contaminant sequences detection\n";
  1032. cout << "\tseqType\t\tINT\t\tSequence fq name type, 0->old fastq name, 1->new fastq name [0]\n";
  1033. cout << "\t\t\t\t\t\t\t\told fastq name: @FCD1PB1ACXX:4:1101:1799:2201#GAAGCACG/2\n";
  1034. cout << "\t\t\t\t\t\t\t\tnew fastq name: @HISEQ:310:C5MH9ANXX:1:1101:3517:2043 2:N:0:TCGGTCAC\n";
  1035. cout << "\ttrimFq1\t\tSTR\t\ttrim fq1 file name(gz format)[optional]\n";
  1036. cout
  1037. << "\ttrimFq2\t\tSTR\t\ttrim fq2 file name[optional]. If trim related parameters were set on, these output files would include the total reads which only do trimming. For example, if read A failed QC after trimming, it will still output to -R/-W, but not to -C/-D\n";
  1038. cout << "\ttile\t\tSTR\t\ttile number to ignore reads, such as [1101-1104,1205]\n";
  1039. cout << "\tfov\t\tSTR\t\tfov number to ignore reads (only for zebra-platform data), such as [C001R003,C003R004]\n";
  1040. // cout << "\tcontam_trim\t\t\ttrim read when find contam[default:discard]\n";
  1041. if (c_module == "filter" || c_module == "filtermeta")
  1042. {
  1043. // cout << "filter and filtermeta module adapter related parameter\n";
  1044. cout
  1045. << "\tadaMis\t\tINT,[INT]\tthe max mismatch number when match the adapter (depend on -f/-r).If different values are required for fq1 and fq2, you can set two values seperated by comma,e.g. 1,2 (same as -A/-9)[1]\n";
  1046. cout << "\tadaMR\t\tFLOAT,[FLOAT]\tadapter's shortest match ratio (depend on -f/-r) [0.5]\n";
  1047. cout << "\tadaEdge\t\tINT,[INT]\tthe min length for segmental alignment [6]\n";
  1048. }
  1049. else if (c_module == "filtersRNA")
  1050. {
  1051. // cout << "filtersRNA module adapter related parameter\n";
  1052. cout << " find 5' adapter\n";
  1053. cout << "\tadaRCtg\tINT\t\tmini 5' adapter continuous alignment length (default: 6)\n";
  1054. cout << "\tadaRAr\tFLOAT\t\tmini alignment rate when find 5' adapter: alignment/tag (default: 0.8)\n";
  1055. cout << " find 3' adapter\n";
  1056. cout << "\tadaRMa\tINT\t\tmini alignment length when find 3' adapter (default: 5)\n";
  1057. cout << "\tadaREr\tFLOAT\t\tMax error rate when find 3' adapter (mismatch/match) (default: 0.4)\n";
  1058. cout << "\tadaRMm\tINT\t\tMax mismatch number when find 3' adapter (default: 4)" << endl;
  1059. }
  1060. else if (c_module == "filterStLFR")
  1061. {
  1062. /*if(para=="barcodeListPath"){
  1063. gp.barcodeListPath.assign(value.c_str());
  1064. }
  1065. if(para=="barcodeRegionStr"){
  1066. gp.barcodeRegionStr.assign(value.c_str());
  1067. }
  1068. if(para=="notCutNoLFR"){
  1069. gp.notCutNoLFR=true;
  1070. }*/
  1071. cout << "\tbarcodeListPath\tSTR\t\tbarcode list of two columns:sequence and barcodeID\n";
  1072. cout
  1073. << "\tbarcodeRegionStr\tSTR\t\tbarcode regions, such as: 101_10,117_10,145_10 or 101_10,117_10,133_10\n";
  1074. cout << "\tnotCutNoLFR\t\t\t\tdo not cut sequence when fail found barcode\n";
  1075. cout << "\tinputAsList\t\t\t\tinput file list not a file\n";
  1076. cout << "\ttenX\t\t\t\t\toutput tenX format\n";
  1077. }
  1078. cout << "\toutFileType\tSTR\t\toutput file format: fastq or fasta[fastq]\n";
  1079. cout << endl;
  1080. if (c_module == "filterStLFR" || c_module == "filter")
  1081. {
  1082. cout
  1083. << "\trmdup\t\t\tremove duplicate reads. The function contains a certain false positive rate which means a small number of non-duplicate reads would be marked as duplication, and limited in large reads number\n";
  1084. // cout<<"\tapproximateReadsNum\tSTR/LONG\tapproximate reads number. We suggest you set this parameter if you know. e.g. 100m"<<endl;
  1085. // cout<<"\tmemSizeUsedInRmdup\tSTR/LONG\tmaximum memory size used in rmdup. e.g. 1g\n";
  1086. // cout<<"\texpectedFalsePositive\tFLOAT\texpected false positive rate which means maybe a <expectedFalsePositive> of reads would be marked as duplication which actually not. e.g. 1e-7"<<endl;
  1087. }
  1088. cout << "\tindex\t\t\t\tremove index\n";
  1089. cout
  1090. << "\ttotalReadsNum\tINT/FLOAT\tnumber/fraction of reads you want to keep in the output clean fq file(cannot be assigned when -w is given).\n";
  1091. cout
  1092. << "\t \t\t\t\t\tIt will extract reads randomly through the total clean fq file by default, you also can get the head reads\n";
  1093. cout << "\t \t\t\t\t\tfor save time by add head suffix to the integer(e.g. totalReadsNum=10000000head)\n";
  1094. cout << "\ttrim\t\tINT,INT,INT,INT\n";
  1095. cout
  1096. << "\t \t\t\t\t\ttrim some bp of the read's head and tail, they means: (PE type:read1's head and tail and read2's head and tail [0,0,0,0]; SE type:read head and tail [0,0])\n";
  1097. cout
  1098. << "\ttrimBadHead\tINT,INT\t\tTrim from head ends until meeting high-quality base or reach the length threshold, set (quality threshold,MaxLengthForTrim) [0,0]\n";
  1099. cout
  1100. << "\ttrimBadTail\tINT,INT\t\tTrim from tail ends until meeting high-quality base or reach the length threshold, set (quality threshold,MaxLengthForTrim) [0,0]\n";
  1101. cout << "\n";
  1102. cout << "\toverlap\t\tINT\t\tfilter the small insert size.Not filter until the value exceed 1[-1]\n";
  1103. cout << "\tmis\t\tFLOAT\t\tthe maximum mismatch ratio when find overlap between PE reads(depend on -O)[0.1]\n";
  1104. cout << "\n";
  1105. // cout << "\tsplit_line\tINT\t\tsplit raw fastq by <split_line>, default 10M reads per file (if ssd mode is open)\n";
  1106. cout << "\tpatch\t\tINT\t\treads number of a patch processed[400000]\n";
  1107. cout << "\n";
  1108. cout << "\tqualSys\t\tINT\t\tquality system 1:64, 2:33[default:2]\n";
  1109. cout << "\toutQualSys\tINT\t\tout quality system 1:64, 2:33[default:2]\n";
  1110. cout << "\tmaxReadLen\tINT\t\tread max length,default 49 for filtersRNA\n";
  1111. // cout << "\tcleanOutSplit\tINT\t\tmax reads number in each output clean fastq file\n";
  1112. // cout << "\tappend STR the log's output place : console or file [console]\n";
  1113. cout << "\n";
  1114. cout << "\tpe_info\t\t\t\tAdd /1, /2 at the end of fastq name.[default:not add]\n";
  1115. cout
  1116. << "\tbaseConvert\tSTR\t\tconvert base when write data,example:TtoU, means convert base T to base U in the output\n";
  1117. cout << "\tmaxBaseQuality\tINT\t\tmaximum base quality[42]\n";
  1118. cout << "\tlog\t\tSTR\t\tlog file\n";
  1119. cout << "\n";
  1120. exit(1);
  1121. }
  1122. void printVersion()
  1123. {
  1124. cerr << "SOAPnuke filter tools version " << PACKAGEVERSION << "." << MINORVERSION << "\n";
  1125. exit(1);
  1126. }
  1127. void initFromConfigFile(C_global_parameter &gp, char *configFile)
  1128. {
  1129. set<string> legalParas, boolParas;
  1130. legalParas.insert("trimFq1");
  1131. legalParas.insert("trimFq2");
  1132. legalParas.insert("seqType");
  1133. legalParas.insert("outFileType");
  1134. legalParas.insert("contam_trim");
  1135. legalParas.insert("contam1");
  1136. legalParas.insert("contam2");
  1137. legalParas.insert("ctMatchR");
  1138. legalParas.insert("global_contams");
  1139. legalParas.insert("glob_cotm_mR");
  1140. legalParas.insert("glob_cotm_mM");
  1141. legalParas.insert("tile");
  1142. legalParas.insert("fov");
  1143. legalParas.insert("index");
  1144. legalParas.insert("qualSys");
  1145. legalParas.insert("outQualSys");
  1146. legalParas.insert("baseConvert");
  1147. legalParas.insert("maxBaseQuality");
  1148. legalParas.insert("overlap");
  1149. legalParas.insert("mis");
  1150. legalParas.insert("pe_info");
  1151. legalParas.insert("patch");
  1152. legalParas.insert("maxReadLen");
  1153. legalParas.insert("adaMis");
  1154. legalParas.insert("adaMR");
  1155. legalParas.insert("adaEdge");
  1156. legalParas.insert("adaRCtg");
  1157. legalParas.insert("adaRAr");
  1158. legalParas.insert("adaRMa");
  1159. legalParas.insert("adaREr");
  1160. legalParas.insert("adaRMm");
  1161. legalParas.insert("log");
  1162. legalParas.insert("totalReadsNum");
  1163. legalParas.insert("cleanOutSplit");
  1164. legalParas.insert("trim");
  1165. legalParas.insert("trimBadHead");
  1166. legalParas.insert("trimBadTail");
  1167. // stLFR
  1168. legalParas.insert("barcodeListPath");
  1169. legalParas.insert("barcodeRegionStr");
  1170. legalParas.insert("notCutNoLFR");
  1171. legalParas.insert("inputAsList");
  1172. legalParas.insert("tenX");
  1173. legalParas.insert("rmdup");
  1174. // legalParas.insert("approximateReadsNum");
  1175. // legalParas.insert("memSizeUsedInRmdup");
  1176. // legalParas.insert("expectedFalsePositive");
  1177. boolParas.insert("index");
  1178. boolParas.insert("pe_info");
  1179. boolParas.insert("contam_trim");
  1180. // stLFR
  1181. boolParas.insert("notCutNoLFR");
  1182. boolParas.insert("inputAsList");
  1183. boolParas.insert("tenX");
  1184. boolParas.insert("rmdup");
  1185. string configFilePath(configFile);
  1186. ifstream ifConfig;
  1187. ifConfig.open(configFilePath.c_str());
  1188. if (!ifConfig)
  1189. {
  1190. cerr << "Error:cannot open such file," << configFile << endl;
  1191. exit(1);
  1192. }
  1193. string line;
  1194. while (getline(ifConfig, line))
  1195. {
  1196. string para, value;
  1197. if (line.find("#") == 0)
  1198. {
  1199. continue;
  1200. }
  1201. if (line.find("=") != string::npos)
  1202. {
  1203. vector<string> eles;
  1204. line_split(line, '=', eles);
  1205. if (eles.size() != 2)
  1206. {
  1207. cerr << "Error:unrecgonized format parameter," << line << endl;
  1208. exit(1);
  1209. }
  1210. para = eles[0];
  1211. value = eles[1];
  1212. chomp_space(para, "all");
  1213. chomp_space(value, "all");
  1214. }
  1215. else
  1216. {
  1217. para = line;
  1218. if (boolParas.find(para) == boolParas.end())
  1219. {
  1220. cerr << "Error:this parameter should set a value," << para << endl;
  1221. exit(1);
  1222. }
  1223. }
  1224. if (legalParas.find(para) == legalParas.end())
  1225. {
  1226. cerr << "Error:no such parameter," << para << endl;
  1227. exit(1);
  1228. }
  1229. if (para == "trimFq1")
  1230. {
  1231. gp.trim_fq1.assign(value);
  1232. if (gp.trim_fq1.rfind(".gz") == gp.trim_fq1.size() - 3)
  1233. {
  1234. gp.trimOutGzformat = true;
  1235. }
  1236. else
  1237. {
  1238. gp.trimOutGzformat = false;
  1239. }
  1240. }
  1241. if (para == "trimFq2")
  1242. {
  1243. gp.trim_fq2.assign(value);
  1244. }
  1245. if (para == "seqType")
  1246. {
  1247. gp.seq_type.assign(value);
  1248. }
  1249. if (para == "outFileType")
  1250. {
  1251. gp.output_file_type.assign(value);
  1252. }
  1253. if (para == "contam_trim")
  1254. {
  1255. gp.contam_discard_or_trim = "trim";
  1256. }
  1257. if (para == "contam1")
  1258. {
  1259. gp.contam1_seq.assign(value);
  1260. }
  1261. if (para == "contam2")
  1262. {
  1263. gp.contam2_seq.assign(value);
  1264. }
  1265. if (para == "ctMatchR")
  1266. {
  1267. gp.ctMatchR.assign(value.c_str());
  1268. }
  1269. if (para == "global_contams")
  1270. {
  1271. gp.global_contams.assign(value.c_str());
  1272. }
  1273. if (para == "glob_cotm_mR")
  1274. {
  1275. gp.g_mrs.assign(value.c_str());
  1276. }
  1277. if (para == "glob_cotm_mM")
  1278. {
  1279. gp.g_mms.assign(value.c_str());
  1280. }
  1281. if (para == "tile")
  1282. {
  1283. gp.tile.assign(value.c_str());
  1284. }
  1285. if (para == "fov")
  1286. {
  1287. gp.fov.assign(value.c_str());
  1288. }
  1289. if (para == "index")
  1290. {
  1291. gp.index_remove = true;
  1292. }
  1293. if (para == "qualSys")
  1294. {
  1295. gp.qualityPhred = atoi(value.c_str());
  1296. if (gp.qualityPhred == 1)
  1297. {
  1298. gp.qualityPhred = 64;
  1299. }
  1300. else if (gp.qualityPhred == 2)
  1301. {
  1302. gp.qualityPhred = 33;
  1303. }
  1304. }
  1305. if (para == "outQualSys")
  1306. {
  1307. gp.outputQualityPhred = atoi(value.c_str());
  1308. if (gp.outputQualityPhred == 1)
  1309. {
  1310. gp.outputQualityPhred = 64;
  1311. }
  1312. else if (gp.outputQualityPhred == 2)
  1313. {
  1314. gp.outputQualityPhred = 33;
  1315. }
  1316. }
  1317. if (para == "baseConvert")
  1318. {
  1319. gp.base_convert.assign(value.c_str());
  1320. }
  1321. if (para == "maxBaseQuality")
  1322. {
  1323. gp.maxBaseQuality = atoi(value.c_str());
  1324. }
  1325. if (para == "overlap")
  1326. {
  1327. gp.overlap_length = atoi(value.c_str());
  1328. }
  1329. if (para == "mis")
  1330. {
  1331. gp.peMismatchRatio = atof(value.c_str());
  1332. }
  1333. if (para == "pe_info")
  1334. {
  1335. gp.whether_add_pe_info = true;
  1336. }
  1337. if (para == "patch")
  1338. {
  1339. gp.patchSize = atoi(value.c_str());
  1340. }
  1341. if (para == "maxReadLen")
  1342. {
  1343. gp.max_read_length = atoi(value.c_str());
  1344. }
  1345. if (para == "adaMis")
  1346. {
  1347. wrong_paras["filtersRNA"].emplace_back("-M|--adaMis");
  1348. string tmp_str;
  1349. tmp_str.assign(value.c_str());
  1350. if (tmp_str.find(",") == string::npos)
  1351. {
  1352. gp.adaMis = atoi(value.c_str());
  1353. gp.adaMis2 = gp.adaMis;
  1354. }
  1355. else
  1356. {
  1357. vector<string> values;
  1358. line_split(tmp_str, ',', values);
  1359. if (values.size() < 2)
  1360. {
  1361. cerr << "Error:expected two values in -M parameter" << endl;
  1362. exit(1);
  1363. }
  1364. gp.adaMis = atoi(values[0].c_str());
  1365. gp.adaMis2 = atoi(values[1].c_str());
  1366. }
  1367. }
  1368. if (para == "adaMR")
  1369. {
  1370. wrong_paras["filtersRNA"].emplace_back("-A|adaMR");
  1371. string tmp_str;
  1372. tmp_str.assign(value.c_str());
  1373. if (tmp_str.find(",") == string::npos)
  1374. {
  1375. gp.adaMR = atof(value.c_str());
  1376. gp.adaMR2 = gp.adaMR;
  1377. }
  1378. else
  1379. {
  1380. vector<string> values;
  1381. line_split(tmp_str, ',', values);
  1382. if (values.size() < 2)
  1383. {
  1384. cerr << "Error:expected two values in -A parameter" << endl;
  1385. exit(1);
  1386. }
  1387. gp.adaMR = atof(values[0].c_str());
  1388. gp.adaMR2 = atof(values[1].c_str());
  1389. }
  1390. }
  1391. if (para == "adaEdge")
  1392. {
  1393. wrong_paras["filtersRNA"].emplace_back("-9|--adaEdge");
  1394. string tmp_str;
  1395. tmp_str.assign(value.c_str());
  1396. if (tmp_str.find(",") == string::npos)
  1397. {
  1398. gp.adaEdge = atoi(value.c_str());
  1399. gp.adaEdge2 = gp.adaEdge;
  1400. }
  1401. else
  1402. {
  1403. vector<string> values;
  1404. line_split(tmp_str, ',', values);
  1405. if (values.size() < 2)
  1406. {
  1407. cerr << "Error:expected two values in -9 parameter" << endl;
  1408. exit(1);
  1409. }
  1410. gp.adaEdge = atoi(values[0].c_str());
  1411. gp.adaEdge2 = atoi(values[1].c_str());
  1412. }
  1413. }
  1414. if (para == "adaRCtg")
  1415. {
  1416. gp.adaRCtg = atoi(value.c_str());
  1417. wrong_paras["filter"].emplace_back("-S|--adaRCtg");
  1418. }
  1419. if (para == "adaRAr")
  1420. {
  1421. gp.adaRAr = atof(value.c_str());
  1422. wrong_paras["filter"].emplace_back("-s|--adaRAr");
  1423. }
  1424. if (para == "adaRMa")
  1425. {
  1426. gp.adaRMa = atoi(value.c_str());
  1427. wrong_paras["filter"].emplace_back("-U|--adaRMa");
  1428. }
  1429. if (para == "adaREr")
  1430. {
  1431. gp.adaREr = atof(value.c_str());
  1432. wrong_paras["filter"].emplace_back("-u|--adaREr");
  1433. }
  1434. if (para == "adaRMm")
  1435. {
  1436. gp.adaRMm = atoi(value.c_str());
  1437. wrong_paras["filter"].emplace_back("-b|--adaRMm");
  1438. }
  1439. if (para == "log")
  1440. {
  1441. gp.log.assign(value.c_str());
  1442. }
  1443. if (para == "totalReadsNum")
  1444. {
  1445. string tmp_str;
  1446. tmp_str.assign(value.c_str());
  1447. if (tmp_str.find("head") == string::npos)
  1448. {
  1449. gp.total_reads_num_random = true;
  1450. // gp.catWhenrunning=false;
  1451. for (int i = 0; i != tmp_str.size(); i++)
  1452. {
  1453. if (!isdigit(tmp_str[i]) && tmp_str[i] != '.')
  1454. {
  1455. cerr << "Error:-L value should be a positive integer or float" << endl;
  1456. exit(1);
  1457. }
  1458. }
  1459. }
  1460. else
  1461. {
  1462. gp.total_reads_num_random = false;
  1463. tmp_str.erase(tmp_str.find("head"), 4);
  1464. if (tmp_str.find(".") != string::npos)
  1465. {
  1466. cerr << "Error:-L value should be a integer when with head suffix" << endl;
  1467. exit(1);
  1468. }
  1469. else
  1470. {
  1471. for (int i = 0; i != tmp_str.size(); i++)
  1472. {
  1473. if (!isdigit(tmp_str[i]))
  1474. {
  1475. cerr << "Error:-L value should be an integer when with head suffix" << endl;
  1476. exit(1);
  1477. }
  1478. }
  1479. }
  1480. }
  1481. float tmp_val = atof(value.c_str());
  1482. if (tmp_val == 0)
  1483. {
  1484. cerr << "Error:-L value should be a positive integer or float" << endl;
  1485. exit(1);
  1486. }
  1487. gp.total_reads_num = tmp_val;
  1488. if (tmp_val < 1)
  1489. {
  1490. gp.f_total_reads_ratio = tmp_val;
  1491. }
  1492. else
  1493. {
  1494. istringstream is_str(tmp_str);
  1495. is_str >> gp.l_total_reads_num;
  1496. }
  1497. if (gp.f_total_reads_ratio > 0 && gp.l_total_reads_num > 0)
  1498. {
  1499. cerr << "Error:reads number and ratio should not be both assigned at the same time" << endl;
  1500. exit(1);
  1501. }
  1502. }
  1503. if (para == "cleanOutSplit")
  1504. {
  1505. string paraCheck = value;
  1506. for (int i = 0; i != paraCheck.size(); i++)
  1507. {
  1508. if (!isdigit(paraCheck[i]))
  1509. {
  1510. cerr << "Error:-w value should be a positive integer" << endl;
  1511. exit(1);
  1512. }
  1513. }
  1514. gp.cleanOutSplit = atoi(paraCheck.c_str());
  1515. if (gp.cleanOutSplit == 0)
  1516. {
  1517. cerr << "Error:-w value should be a positive integer" << endl;
  1518. exit(1);
  1519. }
  1520. }
  1521. if (para == "trim")
  1522. {
  1523. gp.trim = value;
  1524. }
  1525. if (para == "trimBadHead")
  1526. {
  1527. gp.trimBadHead = value;
  1528. }
  1529. if (para == "trimBadTail")
  1530. {
  1531. gp.trimBadTail = value;
  1532. }
  1533. /*legalParas.insert("cleanOutSplit");
  1534. legalParas.insert("trim");
  1535. legalParas.insert("trimBadHead");
  1536. legalParas.insert("trimBadTail");
  1537. */
  1538. // stLFR
  1539. /*string barcodeListPath;
  1540. string barcodeRegionStr;
  1541. bool notCutNoLFR;
  1542. */
  1543. if (para == "barcodeListPath")
  1544. {
  1545. gp.barcodeListPath.assign(value.c_str());
  1546. }
  1547. if (para == "barcodeRegionStr")
  1548. {
  1549. gp.barcodeRegionStr.assign(value.c_str());
  1550. }
  1551. if (para == "notCutNoLFR")
  1552. {
  1553. gp.notCutNoLFR = true;
  1554. }
  1555. if (para == "inputAsList")
  1556. {
  1557. gp.inputAsList = true;
  1558. }
  1559. if (para == "tenX")
  1560. {
  1561. gp.tenX = true;
  1562. }
  1563. if (para == "rmdup")
  1564. {
  1565. gp.rmdup = true;
  1566. }
  1567. // if(para=="approximateReadsNum"){
  1568. // if(isdigit(value[value.size()-1])){
  1569. // gp.approximateReadsNum=atol(value.c_str());
  1570. // }else if(value[value.size()-1]=='M' || value[value.size()-1]=='m'){
  1571. // string realValue=value.substr(0,value.size()-1);
  1572. // gp.approximateReadsNum=atol(realValue.c_str())*1024*1024;
  1573. // }else if(value[value.size()-1]=='G' || value[value.size()-1]=='g') {
  1574. // string realValue = value.substr(0, value.size() - 1);
  1575. // gp.approximateReadsNum = atol(realValue.c_str()) * 1024 * 1024 * 1024;
  1576. // }else{
  1577. // cerr<<"Error:cannot recognize value,"<<value<<endl;
  1578. // exit(1);
  1579. // }
  1580. // }
  1581. // if(para=="memSizeUsedInRmdup"){
  1582. // if(isdigit(value[value.size()-1])){
  1583. // gp.memSizeUsedInRmdup=atol(value.c_str());
  1584. // }else if(value[value.size()-1]=='M' || value[value.size()-1]=='m'){
  1585. // string realValue=value.substr(0,value.size()-1);
  1586. // gp.memSizeUsedInRmdup=atol(realValue.c_str())*1024*1024;
  1587. // }else if(value[value.size()-1]=='G' || value[value.size()-1]=='g') {
  1588. // string realValue = value.substr(0, value.size() - 1);
  1589. // gp.memSizeUsedInRmdup = atol(realValue.c_str()) * 1024 * 1024 * 1024;
  1590. // }else{
  1591. // cerr<<"Error:cannot recognize value,"<<value<<endl;
  1592. // exit(1);
  1593. // }
  1594. // }
  1595. // if(para=="expectedFalsePositive"){
  1596. // gp.expectedFalsePositive=stof(value.c_str());
  1597. // if(gp.expectedFalsePositive==0 || gp.expectedFalsePositive==1){
  1598. // cout<<"Warning:expected FP you set is "<<gp.expectedFalsePositive<<", please check the parameter"<<endl;
  1599. // }
  1600. // }
  1601. }
  1602. }

process_argv.cpp at commit 2d5b727, under GPL-3.0 · at the source

Overview

Authors: Lin Wang1, Li-Qiang Liang1, Pei-Yao Feng1, Yan Li1, Jin-Xing Wang1, Xiao-Fan Zhao1
  1. Shandong Provincial Key Laboratory of Development and Regeneration, School of Life Sciences, Shandong University, Qingdao, China
Journal: The Journal of biological chemistry, volume 302, issue 9, article 113409
Dates: received 7 April 2026; published online 7 August 2026; in print August 2026
Type: Research article · Language: English
License: CC BY
Identifiers: DOI · PMCID PMC13553576
Status: code verified
Categories: other (organism), cellular / molecular (subfield)
Methods: Statistics, Preprocessing, Evoked potentials
Keywords: brain, cell proliferation, 20-hydroxyecdyone, SOX12, DELTA
Citations: not cited yet (Europe PMC); 55 references in the paper
Research resources: rabbit anti Histone H3 RRID:AB_2716755, rabbit anti-actin RRID:AB_2768234, mouse anti-RFP RRID:AB_2770409

Abstract

During metamorphic development from larva to adult, insect brains exhibit cell proliferation; however, the molecular mechanisms governing this process remain poorly understood. Employing the lepidopteran insect Helicoverpa armigera (cotton bollworm), an agricultural pest, as a model system, this study demonstrates that the steroid hormone 20-hydroxyecdysone (20E) regulates neural cell proliferation during imaginal brain development by upregulating the expression of SOX12 and DELTA via nuclear receptor EcRA. SOX12 exhibits significantly elevated expression and is localized in the brain during metamorphosis. Overexpression of SOX12-GFP in the H. armigera epidermal cell line (HaEpi) promotes cell proliferation. RNA interference (RNAi)-mediated knockdown of Sox12 in larvae leads to lethality, delayed pupation, impaired imaginal brain development, downregulation of cell proliferation-related genes, and reduced neural cell proliferation in the brain. CRISPR/Cas9 knockout of Sox12 can also impair imaginal brain development and reduce neural cell proliferation in the brain. Sox12 is upregulated by 20E through its nuclear receptor EcRA, which subsequently induces Delta expression to facilitate imaginal brain development during metamorphosis. Notably, Delta knockdown recapitulates the phenotypic effects observed on Sox12 silencing and knockout. Collectively, these findings establish that the steroid hormone 20E, acting through the EcRA-SOX12-DELTA regulatory axis, drives neural cell proliferation in the developing imaginal brain during insect metamorphosis.

Reproduced under the paper's license (CC BY), from the paper cited above.

Repository

Its files are read in the Code ↔ Paper reader above, with 1 match between paragraphs and lines of code.

BGI-flexlab/SOAPnuke

License: GPL-3.0
State: the link answers, verified on 27 September 2026
Evidence: files inventoried
Commit: 2d5b727d6a7451f6188a46360a55bacf7baff158, 28 March 2024
Languages: C/C++ (15), C++ (14), R (3)
Size: 36 files, 32 scripts
Software Heritage: not checked
Found in: the text, “RNA-seq data analysis”
Holds: README, license file
Not found: CITATION.cff, environment file, tests, continuous integration, documentation
Availability: 1 check, the latest on 27 September 2026: the link answers
  • 27 September 2026: the link answers
34 files

Tracing map

Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.

What the map holds:

  • 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 32 scripts, each with its path and the digest of its content;
  • 1 match between paragraphs of the paper and lines of the code (method lexical-v1);
  • neither the text of the paper nor the code itself.

Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.

Data

No dataset and no data link were found in the paper.

Data availability

All data are contained within the article. The raw RNA-seq data generated from this study have been deposited in the Sequence Read Archive with the accession number PRJNA1498007. This article contains supporting information.

Reproduced under the paper's license (CC BY), from the paper cited above.

Versions

The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.

Version 1, 27 September 2026: the first record

Recorded: type, language, journal, volume, issue, pages, dates, 6 authors, 5 keywords, 1 funder, 54 references, 3 RRIDs.

Cite

This paper

Wang, L., Liang, L.-Q., Feng, P.-Y., Li, Y., Wang, J.-X., & Zhao, X.-F. (2026). SOX12 and DELTA mediate ecdysone-driven adult neural cell proliferation during metamorphosis. The Journal of biological chemistry, 302(9), 113409.

BibTeX

@article{wang2026sox12,
author = {Wang, Lin and Liang, Li-Qiang and Feng, Pei-Yao and Li, Yan and Wang, Jin-Xing and Zhao, Xiao-Fan},
title = {{SOX12 and DELTA mediate ecdysone-driven adult neural cell proliferation during metamorphosis}},
journal = {The Journal of biological chemistry},
year = {2026},
month = aug,
volume = {302},
number = {9},
pages = {113409},
publisher = {American Society for Biochemistry and Molecular Biology},
issn = {0021-9258},
pmcid = {PMC13553576}
}

RIS

TY - JOUR
AU - Wang, Lin
AU - Liang, Li-Qiang
AU - Feng, Pei-Yao
AU - Li, Yan
AU - Wang, Jin-Xing
AU - Zhao, Xiao-Fan
TI - SOX12 and DELTA mediate ecdysone-driven adult neural cell proliferation during metamorphosis
T2 - The Journal of biological chemistry
J2 - J Biol Chem
PY - 2026
DA - 2026/08/07
VL - 302
IS - 9
SP - 113409
SN - 0021-9258
PB - American Society for Biochemistry and Molecular Biology
LA - en
ER -

CSL-JSON

{
"id": "pmcid:PMC13553576",
"type": "article-journal",
"title": "SOX12 and DELTA mediate ecdysone-driven adult neural cell proliferation during metamorphosis",
"container-title": "The Journal of biological chemistry",
"author": [
{
"family": "Wang",
"given": "Lin"
},
{
"family": "Liang",
"given": "Li-Qiang"
},
{
"family": "Feng",
"given": "Pei-Yao"
},
{
"family": "Li",
"given": "Yan"
},
{
"family": "Wang",
"given": "Jin-Xing"
},
{
"family": "Zhao",
"given": "Xiao-Fan"
}
],
"container-title-short": "J Biol Chem",
"volume": "302",
"issue": "9",
"page": "113409",
"PMCID": "PMC13553576",
"ISSN": "0021-9258",
"publisher": "American Society for Biochemistry and Molecular Biology",
"language": "en",
"issued": {
"date-parts": [
[
2026,
8,
7
]
]
}
}

The tracing map gets a citation of its own once an author has validated it and it has a DOI.

Similar papers

The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.

[1] doi:10.1038/s41586-026-10797-w [code]
A global molecular code for birth order and neuronal identity in Drosophila.
Journal: Nature
In common: cellular / molecular, 2 references
[2] doi:10.1002/advs.202519889 [code]
Functional Mapping of Neurodevelopmental Disease Pathways to Key Neurodevelopmental Processes Represented in the Developmental Neurotoxicity In Vitro Testing Battery.
Journal: Advanced science (Weinheim, Baden-Wurttemberg, Germany)
In common: 2 references
[3] doi:10.1186/s13059-026-04126-7
Srr2-dependent SOX2 levels govern the chromatin and transcriptional landscape of adult neural stem cell fate decisions in mouse.
Journal: Genome biology
In common: 2 references
[4] doi:10.1038/s41598-026-41460-z [code]
NvashA function reveals temporal differences in neural subtype generation in cnidarians.
Journal: Scientific reports
In common: other, 1 reference
[5] doi:10.1038/s42003-026-10802-y
Transcriptome of fetal cortex of tree shrew underlying the emergence of outer subventricular zone.
Journal: Communications biology
In common: other, 1 reference
[6] doi:10.1038/s41598-026-54127-6
Canonical autophagy remains inactive in induced pluripotent stem cells and neuronal progenitor cells following DNA damage induced by BPDE or etoposide.
Journal: Scientific reports
In common: cellular / molecular, 1 reference
[7] doi:10.1073/pnas.2614867123 [code]
Glucocorticoid receptors in oligodendrocyte precursor cells regulate hippocampal network plasticity and stress-induced behavior in mice.
Journal: Proceedings of the National Academy of Sciences of the United States of America
In common: cellular / molecular, 1 reference
[8] doi:10.1007/s12035-026-06041-1 [code]
Glucocorticoid Signaling in PSC-Derived Neural Systems to Elucidate Mechanisms of Stress-Induced Psychiatric Vulnerability.
Journal: Molecular neurobiology
In common: cellular / molecular, 1 reference
[9] doi:10.1093/nar/gkag374
Dual role of ZIC2 during neural induction: from priming transcription factor to enhancer activator.
Journal: Nucleic acids research
In common: cellular / molecular, 1 reference
[10] doi:10.1155/humu/4225263
The Charcot-Marie-Tooth Neuropathy (CMTX3) Complex Structural Variation Causes Differential SOX3 Spatiotemporal Expression.
Journal: Human mutation
In common: cellular / molecular, 1 reference

Contribute

The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.

Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.

Request its removal

To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).

Discussion, reproductions, activity

Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.

Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.

Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.