Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

README.md 13KB

3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
3 lat temu
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266
  1. # Quality control of germline variants calling results using a Chinese Quartet family
  2. > Author: Run Luyao
  3. >
  4. > E-mail:18110700050@fudan.edu.cn
  5. >
  6. > Git: http://47.103.223.233/renluyao/quartet_dna_quality_control_big_pipeline.git
  7. >
  8. > Last Updates: 2021/7/5
  9. ## Install
  10. ```
  11. open-choppy-env
  12. choppy install renluyao/quartet_dna_quality_control_big_pipeline
  13. ```
  14. ## Introduction of Chinese Quartet DNA reference materials
  15. 建立高通量全基因组测序的生物计量和质量控制关键技术体系,是保障测序数据跨技术平台、跨实验室可比较、相关研究结果可重复、数据可共享的重要关键共性技术。建立国家基因组标准物质和基准数据集,突破基因组学的生物计量技术,是将测序技术转化成临床应用的重要环节与必经之路,目前国际上尚属空白。中国计量科学研究院与复旦大学、复旦大学泰州健康科学研究院共同研制了人源中华家系1号基因组标准物质(**Quartet,一套4个样本,编号分别为LCL5,LCL6,LCL7,LCL8,其中LCL5和LCL6为同卵双胞胎女儿,LCL7为父亲,LCL8为母亲**),以及相应的全基因组测序序列基准数据集(“量值”),为衡量基因序列检测准确与否提供一把“标尺”,成为保障基因测序数据可靠性的国家基准。人源中华家系1号基因组标准物质来源于泰州队列同卵双生双胞胎家庭,从遗传结构上体现了我国南北交界的人群结构特征,同时家系的设计也为“量值”的确定提供了遗传学依据。
  16. 中华家系1号DNA标准物质的Small Variants标称值包括高置信单核苷酸变异信息、高置信短插入缺失变异信息和高置信参考基因组区。该系列标准物质可以用于评估基因组测序的性能,包括全基因组测序、全外显子测序、靶向测序,如基因捕获测序;还可用于评估测序过程和数据分析过程中对SNV和InDel检出的真阳性、假阳性、真阴性和假阴性水平,为基因组测序技术平台、实验室、相关产品的质量控制与性能验证提供标准物质和标准数据。此外,我们还可根据中华家系1号的生物遗传关系计算同卵双胞胎检测突变的一致性和符合四口之家遗传规律的一致率估计测序错误的比例,评估数据产生和分析的质量好坏。
  17. ![Picture1](./pictures/Picture1.png)
  18. 该Quality_control APP用于全基因组测序(whole-genome sequencing,WGS)数据的质量评估,包括原始数据质控、比对数据质控和突变检出数据质控。
  19. ## 流程与参数
  20. ![workflow](./pictures/workflow.png)
  21. ### 1. Pre-alignment QC
  22. #### [Fastqc](<https://www.bioinformatics.babraham.ac.uk/projects/fastqc/>) v0.11.5
  23. [FastQC](<https://www.bioinformatics.babraham.ac.uk/projects/fastqc/Help/3%20Analysis%20Modules/>) is used to investigate the quality of fastq files
  24. ```bash
  25. fastqc -t <threads> -o <output_directory> <fastq_file>
  26. ```
  27. #### [Fastq Screen](<https://www.bioinformatics.babraham.ac.uk/projects/fastq_screen/>) 0.12.0
  28. Fastq Screen is used to inspect whether the library were contaminated. For example, we expected 99% reads aligned to human genome, 10% reads aligned to mouse genome, which is partly homologous to human genome. If too many reads are aligned to E.Coli or Yeast, libraries or cell lines are probably comtminated.
  29. ```bash
  30. fastq_screen --aligner <aligner> --conf <config_file> --top <number_of_reads> --threads <threads> <fastq_file>
  31. ```
  32. ### 2. Post-alignment QC
  33. #### [Qualimap](<http://qualimap.bioinfo.cipf.es/>) 2.0.0
  34. Qualimap is used to check the quality od bam files
  35. ```bash
  36. qualimap bamqc -bam <bam_file> -outformat PDF:HTML -nt <threads> -outdir <output_directory> --java-mem-size=32G
  37. ```
  38. ### 3. Variants Calling QC
  39. ![performance](./pictures/performance.png)
  40. #### 3.1 Performance assessment based on reference datasets
  41. #### [Hap.py](<https://github.com/Illumina/hap.py>) v0.3.9
  42. ```bash
  43. hap.py <truth_vcf> <query_vcf> -f <bed_file> --threads <threads> -o <output_filename>
  44. ```
  45. #### 3.2 Performance assessment based on Quartet genetic built-in truth
  46. #### [Mendelian Concordance Rate](https://github.com/sbg/VBT-TrioAnalysis) (vbt v1.1)
  47. We splited the Quartet family to two trios (F7, M8, D5 and F7, M8, D6) and then do the Mendelian analysis. A Quartet Mendelian concordant variant is the same between the twins (D5 and D6) , and follow the Mendelian concordant between parents (F7 and M8). Mendelian concordance rate is the Mendelian concordance variant divided by total detected variants in a Quartet family.
  48. ```bash
  49. vbt mendelian -ref <fasta_file> -mother <family_merged_vcf> -father <family_merged_vcf> -child <family_merged_vcf> -pedigree <ped_file> -outDir <output_directory> -out-prefix <output_directory_prefix> --output-violation-regions -thread-count <threads>
  50. ```
  51. ## Input files
  52. ```bash
  53. choppy samples renluyao/quartet_dna_quality_control_big_pipeline-latest --output samples
  54. ```
  55. ####Samples文件的输入包括
  56. **1. inputSamplesFile**,该文件的上传至阿里云,samples文件中填写该文件的阿里云地址
  57. 请查看示例 **inputSamples.Examples.txt**
  58. ```bash
  59. #read1 #read2 #sample_name
  60. ```
  61. read1 是阿里云上fastq read1的地址
  62. read2 是阿里云上fastq read2的地址
  63. sample_name是指样本的命名
  64. 所有上传的文件应有规范的命名
  65. Quartet_DNA_SequenceTech_SequenceMachine_SequenceSite_Sample_Replicate_Date.R1/R2.fastq.gz
  66. SequenceTech是指测序平台,如ILM、BGI等
  67. SequenceMachine是指测序仪器,如XTen、Nova、Hiseq(Illumina)、SEQ500、SEQ1000(BGI)等
  68. SequenceSite是指测序单位的英文缩写
  69. Sample是指LCL5、LCL6、LCL7、LCL8
  70. Replicate是指技术重复,从1开始依次增加
  71. Date是指数据获得日期,格式为20200710
  72. 后缀一定是R1/R2.fastq.gz,不可以随意更改,R1/R2不可以写成r1/r2,fastq.gz不可以写成fq.gz
  73. 各个缩写规范请见 https://fudan-pgx.yuque.com/docs/share/5baa851b-da97-47b9-b6c4-78f2b60595ab?# 《数据命名规范》
  74. **2. project**
  75. 这个项目的名称,可以写自己可以识别的字符串,只能写英文和数字,不可以写中文
  76. **samples文件的示例请查看choppy_samples_example.csv**
  77. #### Quartet样本的组合问题
  78. ##### 1. 没有测LCL5和LCL6,或者没有同时测LCL5和LCL6
  79. 只给出原始数据质控、比对数据质控、与标准集的比较
  80. ##### 2. 包含LCL5和LCL6同卵双胞胎的数据,但是父母的数据不全
  81. 只给出原始数据质控、比对数据质控、与标准集的比较、同卵双胞胎一致性
  82. ##### 3. 四个quartet样本都测了
  83. 给出所有结果原始数据质控、比对数据质控、与标准集的比较、同卵双胞胎一致性,符合孟德尔遗传比例
  84. **注意**:本app假设每个批次测的技术重复都一样,如batch 1测了LCL5、LCL6、LCL7和LCL8,batch 2 和batch 3也都测了这四个样本。本app不解决特别复杂的问题,例如batch1测了LCL5,LCL6,batch2测了LCL7和LCL8,本app只能给出原始数据质控、比对数据质控、与标准集的比较,不会把多个批次的数据合并计算孟德尔符合率和姐妹一致性。
  85. ## App输出文件
  86. 本计算会产生大量的中间结果,这里说明最后整合好的结果文件。两个tasks输出最终的结果:
  87. #### 1. extract_tables.wdl
  88. 原始结果质控 pre_alignment.txt
  89. 比对结果指控 post_alignment.txt
  90. 突变检出指控 variants.calling.qc.txt
  91. 如果用户输入4个一组完整的家系样本则可以得到每个家庭单位的precision和recall的平均值,用于报告第一页的展示:
  92. reference_datasets_aver-std.txt
  93. ####2. quartet_mendelian.wdl
  94. 基于Quartet家系的质控 mendelian.txt
  95. Quartet家系结果的平均值和SD值,用于报告第一页的展示
  96. quartet_indel_aver-std.txt
  97. quartet_snv_aver-std.txt
  98. ## 结果展示与解读
  99. ####1. 原始数据质量控制
  100. 原始数据质量控制主要通过考察测序数据的基本特征判断数据质量的好坏,比如数据量是否达到要求、reads的重复率是否过多、碱基质量、ATGC四种碱基的分布、GC含量、接头序列含量以及是否有其他物种的污染等等。
  101. FastQC和FastqScreen是两个常用的原始数据质量控制软件
  102. 总结表格 **pre_alignment.txt**
  103. | 列名 | 说明 |
  104. | ------------------------- | ------------------------------------ |
  105. | Sample | 样本名,R1结尾为read1,R2结尾为read2 |
  106. | %Dup | % Duplicate reads |
  107. | %GC | Average % GC content |
  108. | Total Sequences (million) | Total sequences |
  109. | %Human | 比对到人类基因组的比例 |
  110. | %EColi | 比对到大肠杆菌基因组的比例 |
  111. | %Adapter | 比对到接头序列的比例 |
  112. | %Vector | 比对到载体基因组的比例 |
  113. | %rRNA | 比对到rRNA序列的比例 |
  114. | %Virus | 比对到病毒基因组的比例 |
  115. | %Yeast | 比对到酵母基因组的比例 |
  116. | %Mitoch | 比对到线粒体序列的比例 |
  117. | %No hits | 没有比对到以上基因组的比例 |
  118. #### 2. 比对后数据质量控制
  119. 总结表格 **post_alignment.txt**
  120. | 列名 | 说明 |
  121. | --------------------- | --------------------------------------------- |
  122. | Sample | 样本名 |
  123. | %Mapping | % mapped reads |
  124. | %Mismatch Rate | Mapping error rate |
  125. | Mendelian Insert Size | Median insert size(bp) |
  126. | %Q20 | % bases >Q20 |
  127. | %Q30 | % bases >Q30 |
  128. | Mean Coverage | Mean deduped coverage |
  129. | Median Coverage | Median deduped coverage |
  130. | PCT_1X | Fraction of genome with at least 1x coverage |
  131. | PCT_5X | Fraction of genome with at least 5x coverage |
  132. | PCT_10X | Fraction of genome with at least 10x coverage |
  133. | PCT_30X | Fraction of genome with at least 30x coverage |
  134. ####3. 突变检出数据质量控制
  135. 具体信息 **variants.calling.qc.txt**
  136. | 列名 | 说明 |
  137. | --------------- | ------------------------------ |
  138. | Sample | 样本名 |
  139. | SNV number | 检测到SNV的数目 |
  140. | INDEL number | 检测到INDEL的数目 |
  141. | SNV query | 在高置信基因组区域中的SNV数目 |
  142. | INDEL query | 在高置信基因组区域中INDEL数目 |
  143. | SNV TP | 真阳性SNV |
  144. | INDEL TP | 真阳性INDEL |
  145. | SNV FP | 假阳性SNV |
  146. | INDEL FP | 假阳性INDEL |
  147. | SNV FN | 假阴性SNV |
  148. | INDEL FN | 假阴性INDEL |
  149. | SNV precision | SNV与标准集比较的precision |
  150. | INDEL precision | INDEL的与标准集比较的precision |
  151. | SNV recall | SNV与标准集比较的recall |
  152. | INDEL recall | INDEL的与标准集比较的recall |
  153. | SNV F1 | SNV与标准集比较的F1-score |
  154. | INDEL F1 | INDEL与标准集比较的F1-score |
  155. 与标准集比较的家庭单元整合结果**reference_datasets_aver-std.txt**
  156. | | Mean | SD |
  157. | --------------- | ---- | ---- |
  158. | SNV precision | | |
  159. | INDEL precision | | |
  160. | SNV recall | | |
  161. | INDEL recall | | |
  162. | SNV F1 | | |
  163. | INDEL F1 | | |
  164. ####4 Quartet家系关系评估 mendelian.txt
  165. | 列名 | 说明 |
  166. | ----------------------------- | ------------------------------------------------------------ |
  167. | Family | 家庭名字,我们目前的设计是4个Quartet样本,每个三个技术重复,family_1是指rep1的4个样本组成的家庭单位,以此类推。 |
  168. | Total_Variants | 四个Quartet样本一共能检测到的变异位点数目 |
  169. | Mendelian_Concordant_Variants | 符合孟德尔规律的变异位点数目 |
  170. | Mendelian_Concordance_Quartet | 符合孟德尔遗传的比例 |
  171. 家系结果的整合结果**quartet_indel_aver-std.txt**和**quartet_snv_aver-std.txt**
  172. | | Mean | SD |
  173. | --------------------------- | ---- | ---- |
  174. | SNV/INDEL(根据文件名判断) | | |