BioSAK 1.83.1__tar.gz → 1.83.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (157) hide show
  1. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/VERSION +1 -1
  2. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/iTOL.py +23 -33
  3. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK.egg-info/PKG-INFO +2 -2
  4. {BioSAK-1.83.1 → BioSAK-1.83.2}/PKG-INFO +2 -2
  5. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/BLCA_op_parser.py +0 -0
  6. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/BioSAK_config.py +0 -0
  7. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/COG2020.py +0 -0
  8. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/COG_boxplot_last1row.R +0 -0
  9. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/COG_boxplot_last2row.R +0 -0
  10. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/CheckM.py +0 -0
  11. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/ConvertMSA.py +0 -0
  12. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/DnaFeaturesViewer.py +0 -0
  13. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/FastaSplitler_by_num.py +0 -0
  14. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/FastaSplitler_by_size.py +0 -0
  15. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/GTDB_for_BLCA.py +0 -0
  16. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/Gene2Ctg.py +0 -0
  17. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/KEGG.py +0 -0
  18. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/KEGG_boxplot_last1row.R +0 -0
  19. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/KEGG_get_eukaryotic_kos.py +0 -0
  20. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/KeepRemovingTmp.py +0 -0
  21. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/MeanMappingDepth.py +0 -0
  22. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/MetaBiosample.py +0 -0
  23. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/MetaCHIP_phylo.hmm +0 -0
  24. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/MetaCyc_reactions_with_ec.txt +0 -0
  25. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/NetEnzymes.py +0 -0
  26. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/Newick_tree_plotter.py +0 -0
  27. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/OneLineAln.py +0 -0
  28. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/Prodigal.py +0 -0
  29. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/Reads_simulator.py +0 -0
  30. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/RunGraphMB.py +0 -0
  31. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/SILVA_for_BLCA.py +0 -0
  32. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/SankeyTaxon.py +0 -0
  33. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/SliceMSA.py +0 -0
  34. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/SubsampleLongReads.py +0 -0
  35. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/Tax4Fun2IndOTU.py +0 -0
  36. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/VisBlastOp.py +0 -0
  37. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/VisGeneFlk.py +0 -0
  38. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/__init__.py +0 -0
  39. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/add_desc.py +0 -0
  40. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/arCOG.py +0 -0
  41. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/bam2reads.py +0 -0
  42. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/boxplot.py +0 -0
  43. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/boxplot_last1row.R +0 -0
  44. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/boxplot_matrix_COG.py +0 -0
  45. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/boxplot_matrix_COG_backup.py +0 -0
  46. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/boxplot_matrix_KEGG.py +0 -0
  47. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/boxplot_matrix_dbCAN.py +0 -0
  48. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/cat_fa.py +0 -0
  49. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/cdd2cog.pl +0 -0
  50. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/checkm_marker.py +0 -0
  51. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/compare_trees.R +0 -0
  52. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/compare_trees.py +0 -0
  53. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/cross_link_seqs.py +0 -0
  54. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/dbCAN.py +0 -0
  55. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/download_GenBank_genome_subset_prokaryotes_csv.py +0 -0
  56. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/dwnld_sra_reads.py +0 -0
  57. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/enrich.py +0 -0
  58. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/exe_cmds.py +0 -0
  59. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/ezaai2mat.py +0 -0
  60. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/fa2id.py +0 -0
  61. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/fa2phy.py +0 -0
  62. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/fa2tree.py +0 -0
  63. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/format_converter.py +0 -0
  64. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/format_leaf_name.py +0 -0
  65. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/fq2fa.py +0 -0
  66. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/gapseq.py +0 -0
  67. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/gbk2faa.py +0 -0
  68. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/gbk2ffn.py +0 -0
  69. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/gbk2fna.py +0 -0
  70. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/gbk_to_ffn_faa.py +0 -0
  71. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_EC_from_ko_stats_D.py +0 -0
  72. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_GTDB_taxon_gnm.py +0 -0
  73. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_MAG_reads_long.py +0 -0
  74. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_Pfam_hmms.py +0 -0
  75. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_SCG_tree.py +0 -0
  76. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_TopHits_taxonomy.py +0 -0
  77. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_aa_composition.py +0 -0
  78. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_bin_abundance copy.py +0 -0
  79. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_data_matrix.py +0 -0
  80. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_gc.py +0 -0
  81. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_gene_depth.py +0 -0
  82. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_genome_GTDB.py +0 -0
  83. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_genome_NCBI.py +0 -0
  84. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_genome_NCBI_v1.py +0 -0
  85. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_genome_NCBI_v2.py +0 -0
  86. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_gnm_size.py +0 -0
  87. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_ko_gene_seqs.py +0 -0
  88. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_krona_plot.py +0 -0
  89. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_reads_from_sam.py +0 -0
  90. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_reads_id_in_sam.py +0 -0
  91. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_sankey_plot.R +0 -0
  92. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_top_hit.py +0 -0
  93. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/get_total_length.py +0 -0
  94. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/global_functions.py +0 -0
  95. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/hpc3.py +0 -0
  96. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/js_cmds.py +0 -0
  97. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/js_hpc3.py +0 -0
  98. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/keep_best_hit.py +0 -0
  99. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/ko00001.keg +0 -0
  100. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/koala.py +0 -0
  101. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/label_tree.R +0 -0
  102. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/label_tree.py +0 -0
  103. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/link_16S_MAG.py +0 -0
  104. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/magabund.py +0 -0
  105. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/magabund2.py +0 -0
  106. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/manipulator_fasta.py +0 -0
  107. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/manipulator_msa.py +0 -0
  108. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/manipulator_newick.py +0 -0
  109. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/manipulator_sam.py +0 -0
  110. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/mean_MAG_cov.py +0 -0
  111. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/merge_df.py +0 -0
  112. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/merge_seq.py +0 -0
  113. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/metaAssembly.py +0 -0
  114. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/metabat2concoct.py +0 -0
  115. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/metabat2maxbin.py +0 -0
  116. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/msa_to_distance_matrix.py +0 -0
  117. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/ncbi_dataset.py +0 -0
  118. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/odp.py +0 -0
  119. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/parse_MetaCyc_RxnDB.py +0 -0
  120. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/parse_mmseqs_tsv.py +0 -0
  121. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/plot_mag.py +0 -0
  122. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/plot_sam_depth.py +0 -0
  123. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/plot_tree.R +0 -0
  124. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/prefix_file.py +0 -0
  125. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/prokka.py +0 -0
  126. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/reads2bam.py +0 -0
  127. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/rename_leaves.py +0 -0
  128. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/rename_reads_for_Reago.py +0 -0
  129. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/rename_seq.py +0 -0
  130. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/rename_seqs.py +0 -0
  131. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/ribbon.py +0 -0
  132. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/sam2bam.py +0 -0
  133. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/sampling_GTDB_gnms.py +0 -0
  134. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/select_seq.py +0 -0
  135. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/sep_reads_by_barcode.py +0 -0
  136. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/slice_seq.py +0 -0
  137. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/split_fasta.py +0 -0
  138. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/split_folder.py +0 -0
  139. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/split_sam.py +0 -0
  140. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/submitHPC.py +0 -0
  141. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/subset_GTDB_meta.py +0 -0
  142. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/subset_df.py +0 -0
  143. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/subset_tree.py +0 -0
  144. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/top_16S_hits.py +0 -0
  145. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/top_hits_in_a_group.py +0 -0
  146. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/transpose.py +0 -0
  147. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK/usearch_uc.py +0 -0
  148. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK.egg-info/SOURCES.txt +0 -0
  149. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK.egg-info/dependency_links.txt +0 -0
  150. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK.egg-info/requires.txt +0 -0
  151. {BioSAK-1.83.1 → BioSAK-1.83.2}/BioSAK.egg-info/top_level.txt +0 -0
  152. {BioSAK-1.83.1 → BioSAK-1.83.2}/LICENSE +0 -0
  153. {BioSAK-1.83.1 → BioSAK-1.83.2}/MANIFEST.in +0 -0
  154. {BioSAK-1.83.1 → BioSAK-1.83.2}/README.md +0 -0
  155. {BioSAK-1.83.1 → BioSAK-1.83.2}/bin/BioSAK +0 -0
  156. {BioSAK-1.83.1 → BioSAK-1.83.2}/setup.cfg +0 -0
  157. {BioSAK-1.83.1 → BioSAK-1.83.2}/setup.py +0 -0
@@ -1,4 +1,4 @@
1
- 1.83.1
1
+ 1.83.2
2
2
  - fixed bugs
3
3
 
4
4
  1.83.0
@@ -17,6 +17,7 @@ BioSAK iTOL -ColorStrip -lg MagTaxon.txt -lt Phylum -o ColorStrip_taxon.txt
17
17
  BioSAK iTOL -ColorRange -lg MagTaxon.txt -lt Phylum -o ColorRange_taxon.txt
18
18
  BioSAK iTOL -ColorRange -taxon Taxonomy.txt -rank f -lt Family -o ColorRange_taxon.txt
19
19
  BioSAK iTOL -ExternalShape -lm identity_matrix.txt -lt Identity -scale 25-50-75-100 -o ExternalShape_identity.txt
20
+ BioSAK iTOL -PieChart -lv MagCompleteness.txt -lt Completeness -o PieChart_completeness.txt
20
21
 
21
22
  # Leaf-to-Group file format (-lg, tab separated, no header)
22
23
  genome_1 Bacteria
@@ -58,7 +59,6 @@ def get_color_list(color_num):
58
59
 
59
60
  else:
60
61
  color_num_each = math.ceil(color_num/8) + 2
61
-
62
62
  color_list_1 = sns.color_palette('Blues', n_colors=color_num_each).as_hex()
63
63
  color_list_2 = sns.light_palette('navy', n_colors=color_num_each).as_hex()
64
64
  color_list_3 = sns.light_palette('orange', n_colors=color_num_each).as_hex()
@@ -122,6 +122,7 @@ def iTOL(args):
122
122
  ExternalShape = args['ExternalShape']
123
123
  Binary = args['Binary']
124
124
  Connection = args['Connection']
125
+ PieChart = args['PieChart']
125
126
  LeafGroup = args['lg']
126
127
  GroupColor = args['gc']
127
128
  ColumnColor = args['cc']
@@ -150,11 +151,9 @@ def iTOL(args):
150
151
  # Heatmap
151
152
  Heatmap_STRIP_WIDTH = 60
152
153
 
153
- # ExternalShape
154
-
155
154
  # check the number of specified file type
156
155
  True_num = 0
157
- for file_type in [Labels, ColorStrip, ColorRange, SimpleBar, Heatmap, ExternalShape, Binary]:
156
+ for file_type in [Labels, ColorStrip, ColorRange, SimpleBar, Heatmap, ExternalShape, Binary, PieChart]:
158
157
  if file_type is True:
159
158
  True_num += 1
160
159
 
@@ -234,8 +233,6 @@ def iTOL(args):
234
233
  FileOut_handle.write('LEGEND_SHAPES\t%s\n' % '\t'.join(['1' for i in Group_to_Color_dict]))
235
234
  FileOut_handle.write('LEGEND_COLORS\t%s\n' % '\t'.join(color_list))
236
235
  FileOut_handle.write('LEGEND_LABELS\t%s\n' % '\t'.join(group_list))
237
-
238
- # write out data info
239
236
  FileOut_handle.write('\n# provide data here\nDATA\n')
240
237
  for leaf in Leaf_to_Group_dict:
241
238
  leaf_group = Leaf_to_Group_dict[leaf]
@@ -245,7 +242,6 @@ def iTOL(args):
245
242
  FileOut_handle.write('%s\t%s\t%s\n' % (leaf, leaf_color, leaf_group))
246
243
  if ColorRange is True:
247
244
  FileOut_handle.write('%s\trange\t%s\t%s\n' % (leaf, leaf_color, leaf_group))
248
-
249
245
  FileOut_handle.close()
250
246
 
251
247
  ####################################################################################################################
@@ -272,13 +268,9 @@ def iTOL(args):
272
268
  max_value = float(leaf_value_split[1])
273
269
 
274
270
  SimpleBar_FileOut_handle = open(FileOut, 'w')
275
-
276
- # write out header
277
271
  SimpleBar_FileOut_handle.write('DATASET_SIMPLEBAR\n')
278
272
  SimpleBar_FileOut_handle.write('# Reference: https://itol.embl.de/help/dataset_simplebar_template.txt\n')
279
273
  SimpleBar_FileOut_handle.write('\nSEPARATOR TAB\n')
280
-
281
- # write out SimpleBar attributes
282
274
  SimpleBar_FileOut_handle.write('\n# customize barchart attributes here\n')
283
275
  SimpleBar_FileOut_handle.write('DATASET_LABEL\t%s\n' % LegendTitle)
284
276
  SimpleBar_FileOut_handle.write('COLOR\t%s\n' % SimpleBar_COLOR)
@@ -296,8 +288,6 @@ def iTOL(args):
296
288
  SimpleBar_FileOut_handle.write('\n# customize scale attributes here\n')
297
289
  SimpleBar_FileOut_handle.write('# format: VALUE-LABEL-COLOR-WIDTH-DASHED-LABEL_SCALE_FACTOR, LABEL_SCALE_FACTOR controls font size\n')
298
290
  SimpleBar_FileOut_handle.write('DATASET_SCALE\t%s\n' % '\t'.join(scale_attributes_list))
299
-
300
- # write out data info
301
291
  SimpleBar_FileOut_handle.write('\n# provide data here\n')
302
292
  SimpleBar_FileOut_handle.write('DATA\n')
303
293
 
@@ -378,18 +368,12 @@ def iTOL(args):
378
368
  n += 1
379
369
 
380
370
  Heatmap_FileOut_handle = open(FileOut, 'w')
381
-
382
- # write out header
383
371
  Heatmap_FileOut_handle.write('DATASET_HEATMAP\n')
384
372
  Heatmap_FileOut_handle.write('# Reference https://itol.embl.de/help/dataset_heatmap_template.txt\n')
385
373
  Heatmap_FileOut_handle.write('\nSEPARATOR TAB\n')
386
-
387
- # write out heatmap attributes
388
374
  Heatmap_FileOut_handle.write('\n# customize heatmap attributes here\n')
389
375
  Heatmap_FileOut_handle.write('MARGIN\t%s\n' % MARGIN)
390
376
  Heatmap_FileOut_handle.write('STRIP_WIDTH\t%s\n' % Heatmap_STRIP_WIDTH)
391
-
392
- # write out legend info
393
377
  Heatmap_FileOut_handle.write('\n# customize legend here\n')
394
378
  Heatmap_FileOut_handle.write('AUTO_LEGEND\t1\n')
395
379
  Heatmap_FileOut_handle.write('DATASET_LABEL\t%s\n' % LegendTitle)
@@ -403,13 +387,10 @@ def iTOL(args):
403
387
  Heatmap_FileOut_handle.write('# USER_MAX_VALUE 10\n')
404
388
  Heatmap_FileOut_handle.write('\n# customize column name here\n')
405
389
  Heatmap_FileOut_handle.write('FIELD_LABELS\t%s\n' % '\t'.join(col_name_list))
406
-
407
- # write out data info
408
390
  Heatmap_FileOut_handle.write('\n# Provide data here\n')
409
391
  Heatmap_FileOut_handle.write('DATA\n')
410
392
  for leaf in leaf_matrix_dict:
411
393
  Heatmap_FileOut_handle.write('%s\t%s\n' % (leaf, '\t'.join(leaf_matrix_dict[leaf])))
412
-
413
394
  Heatmap_FileOut_handle.close()
414
395
 
415
396
  ####################################################################################################################
@@ -445,6 +426,25 @@ def iTOL(args):
445
426
 
446
427
  ####################################################################################################################
447
428
 
429
+ # Prepare PieChart file
430
+ if PieChart is True:
431
+ PieChart_FileOut_handle = open(FileOut, 'w')
432
+ PieChart_FileOut_handle.write('DATASET_PIECHART\n')
433
+ PieChart_FileOut_handle.write('SEPARATOR TAB\n')
434
+ PieChart_FileOut_handle.write('DATASET_LABEL\tCompleteness\n')
435
+ PieChart_FileOut_handle.write('COLOR\t#ff0000\n')
436
+ PieChart_FileOut_handle.write('FIELD_COLORS\t#5DADE2\t#FFFFFF\n')
437
+ PieChart_FileOut_handle.write('FIELD_LABELS\tf1\tf2\n')
438
+ PieChart_FileOut_handle.write('DATA\n')
439
+ for each in open(LeafValue):
440
+ each_split = each.strip().split('\t')
441
+ node_id = each_split[0]
442
+ node_value = float(each_split[1])
443
+ PieChart_FileOut_handle.write('%s\t-1\t1\t%s\t%s\n' % (node_id, node_value, (100 - node_value)))
444
+ PieChart_FileOut_handle.close()
445
+
446
+ ####################################################################################################################
447
+
448
448
  # Prepare ExternalShape file
449
449
  if ExternalShape is True:
450
450
 
@@ -478,8 +478,6 @@ def iTOL(args):
478
478
  exit()
479
479
 
480
480
  ExternalShape_FileOut_handle = open(FileOut, 'w')
481
-
482
- # write out header
483
481
  ExternalShape_FileOut_handle.write('DATASET_EXTERNALSHAPE\n')
484
482
  ExternalShape_FileOut_handle.write('# Reference https://itol.embl.de/help/dataset_external_shapes_template.txt\n')
485
483
  ExternalShape_FileOut_handle.write('\nSEPARATOR TAB\n')
@@ -499,8 +497,6 @@ def iTOL(args):
499
497
  ExternalShape_FileOut_handle.write('LEGEND_COLORS\t%s\n' % '\t'.join(LEGEND_COLORS_list))
500
498
  ExternalShape_FileOut_handle.write('LEGEND_LABELS\t%s\n' % '\t'.join(scale_list))
501
499
  ExternalShape_FileOut_handle.write('LEGEND_SHAPE_SCALES\t%s\n' % '\t'.join(str(i) for i in SHAPE_SCALES_list))
502
-
503
- # write out ExternalShape attributes
504
500
  ExternalShape_FileOut_handle.write('\n# customize attributes here\n')
505
501
  ExternalShape_FileOut_handle.write('VERTICAL_GRID\t0\n')
506
502
  ExternalShape_FileOut_handle.write('HORIZONTAL_GRID\t0\n')
@@ -525,8 +521,6 @@ def iTOL(args):
525
521
  if ColumnColor is not None:
526
522
  color_list = [Column_to_Color_dict[i] for i in col_name_list]
527
523
  ExternalShape_FileOut_handle.write('FIELD_COLORS\t%s\n' % '\t'.join(color_list))
528
-
529
- # write out data info
530
524
  ExternalShape_FileOut_handle.write('\n# Provide data here\n')
531
525
  ExternalShape_FileOut_handle.write('DATA\n')
532
526
  for leaf in leaf_matrix_dict:
@@ -549,6 +543,7 @@ if __name__ == '__main__':
549
543
  parser.add_argument('-ExternalShape', required=False, action='store_true', help='ExternalShape')
550
544
  parser.add_argument('-Binary', required=False, action='store_true', help='Binary')
551
545
  parser.add_argument('-Connection', required=False, action='store_true', help='Connection')
546
+ parser.add_argument('-PieChart', required=False, action='store_true', help='PieChart')
552
547
  parser.add_argument('-ll', required=False, default=None, help='Leaf Label')
553
548
  parser.add_argument('-lg', required=False, default=None, help='Leaf Group')
554
549
  parser.add_argument('-gc', required=False, default=None, help='Specify Group/column Color (optional)')
@@ -561,8 +556,3 @@ if __name__ == '__main__':
561
556
  parser.add_argument('-o', required=True, help='Output filename')
562
557
  args = vars(parser.parse_args())
563
558
  iTOL(args)
564
-
565
-
566
- # parser.add_argument('-taxon', required=False, default=None, help='Leaf taxonomy, gtdb format')
567
- # parser.add_argument('-rank', required=False, default=None, help='Taxonomy rank, select from p, c, o, f, g or s')
568
- # LABELS Labels
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: BioSAK
3
- Version: 1.83.1
3
+ Version: 1.83.2
4
4
  Summary: BioSAK
5
5
  Home-page: https://github.com/songweizhi/BioSAK
6
6
  Author: Weizhi Song
@@ -20,4 +20,4 @@ Requires-Dist: beautifulsoup4
20
20
  Requires-Dist: ete3
21
21
  Requires-Dist: statsmodels
22
22
 
23
- BioSAK v1.83.1
23
+ BioSAK v1.83.2
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: BioSAK
3
- Version: 1.83.1
3
+ Version: 1.83.2
4
4
  Summary: BioSAK
5
5
  Home-page: https://github.com/songweizhi/BioSAK
6
6
  Author: Weizhi Song
@@ -20,4 +20,4 @@ Requires-Dist: beautifulsoup4
20
20
  Requires-Dist: ete3
21
21
  Requires-Dist: statsmodels
22
22
 
23
- BioSAK v1.83.1
23
+ BioSAK v1.83.2
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes