biopipen 0.34.8__tar.gz → 0.34.10__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.

Potentially problematic release.


This version of biopipen might be problematic. Click here for more details.

Files changed (290) hide show
  1. {biopipen-0.34.8 → biopipen-0.34.10}/PKG-INFO +3 -2
  2. biopipen-0.34.10/biopipen/__init__.py +1 -0
  3. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/regulatory.py +4 -0
  4. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/scrna.py +22 -2
  5. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/regulatory/MotifAffinityTest.R +21 -5
  6. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/regulatory/MotifAffinityTest_AtSNP.R +9 -2
  7. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/regulatory/MotifAffinityTest_MotifBreakR.R +15 -6
  8. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/regulatory/VariantMotifPlot.R +1 -1
  9. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/regulatory/motifs-common.R +3 -2
  10. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellCellCommunication.py +4 -0
  11. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellCellCommunicationPlots.R +23 -4
  12. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellTypeAnnotation-direct.R +33 -11
  13. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/MarkersFinder.R +9 -1
  14. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ModuleScoreCalculator.R +9 -1
  15. {biopipen-0.34.8 → biopipen-0.34.10}/pyproject.toml +1 -1
  16. {biopipen-0.34.8 → biopipen-0.34.10}/setup.py +1 -1
  17. biopipen-0.34.8/biopipen/__init__.py +0 -1
  18. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/__init__.py +0 -0
  19. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/config.py +0 -0
  20. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/config.toml +0 -0
  21. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/defaults.py +0 -0
  22. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/filters.py +0 -0
  23. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/proc.py +0 -0
  24. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/core/testing.py +0 -0
  25. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/__init__.py +0 -0
  26. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/bam.py +0 -0
  27. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/bed.py +0 -0
  28. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/cellranger.py +0 -0
  29. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/cellranger_pipeline.py +0 -0
  30. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/cnv.py +0 -0
  31. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/cnvkit.py +0 -0
  32. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/cnvkit_pipeline.py +0 -0
  33. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/delim.py +0 -0
  34. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/gene.py +0 -0
  35. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/gsea.py +0 -0
  36. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/misc.py +0 -0
  37. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/plot.py +0 -0
  38. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/protein.py +0 -0
  39. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/rnaseq.py +0 -0
  40. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/scrna_metabolic_landscape.py +0 -0
  41. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/snp.py +0 -0
  42. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/stats.py +0 -0
  43. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/tcgamaf.py +0 -0
  44. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/tcr.py +0 -0
  45. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/vcf.py +0 -0
  46. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/ns/web.py +0 -0
  47. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/bam/CNAClinic.svelte +0 -0
  48. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/bam/CNVpytor.svelte +0 -0
  49. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/bam/ControlFREEC.svelte +0 -0
  50. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cellranger/CellRangerCount.svelte +0 -0
  51. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cellranger/CellRangerSummary.svelte +0 -0
  52. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cellranger/CellRangerVdj.svelte +0 -0
  53. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cnv/AneuploidyScore.svelte +0 -0
  54. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cnv/AneuploidyScoreSummary.svelte +0 -0
  55. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cnv/TMADScoreSummary.svelte +0 -0
  56. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cnvkit/CNVkitDiagram.svelte +0 -0
  57. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cnvkit/CNVkitHeatmap.svelte +0 -0
  58. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/cnvkit/CNVkitScatter.svelte +0 -0
  59. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/common.svelte +0 -0
  60. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/gsea/FGSEA.svelte +0 -0
  61. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/gsea/GSEA.svelte +0 -0
  62. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/protein/ProdigySummary.svelte +0 -0
  63. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna/CellsDistribution.svelte +0 -0
  64. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna/DimPlots.svelte +0 -0
  65. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna/MarkersFinder.svelte +0 -0
  66. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna/MetaMarkers.svelte +0 -0
  67. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna/RadarPlots.svelte +0 -0
  68. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna_metabolic_landscape/MetabolicFeatures.svelte +0 -0
  69. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna_metabolic_landscape/MetabolicPathwayActivity.svelte +0 -0
  70. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/scrna_metabolic_landscape/MetabolicPathwayHeterogeneity.svelte +0 -0
  71. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/snp/PlinkCallRate.svelte +0 -0
  72. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/snp/PlinkFreq.svelte +0 -0
  73. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/snp/PlinkHWE.svelte +0 -0
  74. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/snp/PlinkHet.svelte +0 -0
  75. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/snp/PlinkIBD.svelte +0 -0
  76. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/CDR3AAPhyschem.svelte +0 -0
  77. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/ClonalStats.svelte +0 -0
  78. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/CloneResidency.svelte +0 -0
  79. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/Immunarch.svelte +0 -0
  80. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/SampleDiversity.svelte +0 -0
  81. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/TCRClusterStats.svelte +0 -0
  82. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/TESSA.svelte +0 -0
  83. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/tcr/VJUsage.svelte +0 -0
  84. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/utils/misc.liq +0 -0
  85. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/vcf/TruvariBenchSummary.svelte +0 -0
  86. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/reports/vcf/TruvariConsistency.svelte +0 -0
  87. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/BamMerge.py +0 -0
  88. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/BamSampling.py +0 -0
  89. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/BamSort.py +0 -0
  90. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/BamSplitChroms.py +0 -0
  91. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/BamSubsetByBed.py +0 -0
  92. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/CNAClinic.R +0 -0
  93. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/CNVpytor.py +0 -0
  94. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/ControlFREEC.py +0 -0
  95. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bam/SamtoolsView.py +0 -0
  96. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bed/Bed2Vcf.py +0 -0
  97. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bed/BedConsensus.py +0 -0
  98. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bed/BedLiftOver.sh +0 -0
  99. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bed/BedtoolsIntersect.py +0 -0
  100. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bed/BedtoolsMakeWindows.py +0 -0
  101. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/bed/BedtoolsMerge.py +0 -0
  102. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cellranger/CellRangerCount.py +0 -0
  103. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cellranger/CellRangerSummary.R +0 -0
  104. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cellranger/CellRangerVdj.py +0 -0
  105. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnv/AneuploidyScore.R +0 -0
  106. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnv/AneuploidyScoreSummary.R +0 -0
  107. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnv/TMADScore.R +0 -0
  108. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnv/TMADScoreSummary.R +0 -0
  109. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitAccess.py +0 -0
  110. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitAutobin.py +0 -0
  111. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitBatch.py +0 -0
  112. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitCall.py +0 -0
  113. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitCoverage.py +0 -0
  114. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitDiagram.py +0 -0
  115. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitFix.py +0 -0
  116. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitGuessBaits.py +0 -0
  117. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitHeatmap.py +0 -0
  118. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitReference.py +0 -0
  119. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitScatter.py +0 -0
  120. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/CNVkitSegment.py +0 -0
  121. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/cnvkit/guess_baits.py +0 -0
  122. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/delim/RowsBinder.R +0 -0
  123. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/delim/SampleInfo.R +0 -0
  124. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/gene/GeneNameConversion.R +0 -0
  125. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/gene/GenePromoters.R +0 -0
  126. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/gsea/Enrichr.R +0 -0
  127. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/gsea/FGSEA.R +0 -0
  128. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/gsea/GSEA.R +0 -0
  129. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/gsea/PreRank.R +0 -0
  130. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/misc/Config2File.py +0 -0
  131. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/misc/Plot.R +0 -0
  132. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/misc/Shell.sh +0 -0
  133. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/misc/Str2File.py +0 -0
  134. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/plot/Heatmap.R +0 -0
  135. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/plot/Manhattan.R +0 -0
  136. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/plot/QQPlot.R +0 -0
  137. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/plot/ROC.R +0 -0
  138. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/plot/Scatter.R +0 -0
  139. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/plot/VennDiagram.R +0 -0
  140. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/protein/MMCIF2PDB.py +0 -0
  141. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/protein/PDB2Fasta.py +0 -0
  142. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/protein/Prodigy.py +0 -0
  143. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/protein/ProdigySummary.R +0 -0
  144. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/protein/RMSD.py +0 -0
  145. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/regulatory/MotifScan.py +0 -0
  146. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/rnaseq/Simulation-ESCO.R +0 -0
  147. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/rnaseq/Simulation-RUVcorr.R +0 -0
  148. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/rnaseq/Simulation.R +0 -0
  149. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/rnaseq/UnitConversion.R +0 -0
  150. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/AnnData2Seurat.R +0 -0
  151. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CCPlotR-patch.R +0 -0
  152. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellTypeAnnotation-celltypist.R +0 -0
  153. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellTypeAnnotation-hitype.R +0 -0
  154. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellTypeAnnotation-sccatch.R +0 -0
  155. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellTypeAnnotation-sctype.R +0 -0
  156. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellTypeAnnotation.R +0 -0
  157. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/CellsDistribution.R +0 -0
  158. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/DimPlots.R +0 -0
  159. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ExprImputation-alra.R +0 -0
  160. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ExprImputation-rmagic.R +0 -0
  161. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ExprImputation-scimpute.R +0 -0
  162. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ExprImputation.R +0 -0
  163. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/LoomTo10X.R +0 -0
  164. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/MetaMarkers.R +0 -0
  165. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/PseudoBulkDEG.R +0 -0
  166. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/RadarPlots.R +0 -0
  167. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SCImpute.R +0 -0
  168. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ScFGSEA.R +0 -0
  169. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ScSimulation.R +0 -0
  170. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/ScVelo.py +0 -0
  171. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/Seurat2AnnData.R +0 -0
  172. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClusterStats-clustree.R +0 -0
  173. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClusterStats-dimplots.R +0 -0
  174. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClusterStats-features.R +0 -0
  175. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClusterStats-ngenes.R +0 -0
  176. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClusterStats-stats.R +0 -0
  177. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClusterStats.R +0 -0
  178. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratClustering.R +0 -0
  179. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratFilter.R +0 -0
  180. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratLoading.R +0 -0
  181. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratMap2Ref.R +0 -0
  182. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratMetadataMutater.R +0 -0
  183. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratPreparing.R +0 -0
  184. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratSplit.R +0 -0
  185. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratSubClustering.R +0 -0
  186. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratSubset.R +0 -0
  187. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/SeuratTo10X.R +0 -0
  188. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/Slingshot.R +0 -0
  189. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/Subset10X.R +0 -0
  190. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/TopExpressingGenes.R +0 -0
  191. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/celltypist-wrapper.py +0 -0
  192. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/sctype.R +0 -0
  193. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna/seurat_anndata_conversion.py +0 -0
  194. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna_metabolic_landscape/MetabolicFeatures.R +0 -0
  195. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna_metabolic_landscape/MetabolicPathwayActivity.R +0 -0
  196. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/scrna_metabolic_landscape/MetabolicPathwayHeterogeneity.R +0 -0
  197. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/MatrixEQTL.R +0 -0
  198. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/Plink2GTMat.py +0 -0
  199. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkCallRate.R +0 -0
  200. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkFilter.py +0 -0
  201. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkFreq.R +0 -0
  202. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkFromVcf.py +0 -0
  203. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkHWE.R +0 -0
  204. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkHet.R +0 -0
  205. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkIBD.R +0 -0
  206. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkSimulation.py +0 -0
  207. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/snp/PlinkUpdateName.py +0 -0
  208. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/stats/ChowTest.R +0 -0
  209. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/stats/DiffCoexpr.R +0 -0
  210. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/stats/LiquidAssoc.R +0 -0
  211. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/stats/Mediation.R +0 -0
  212. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/stats/MetaPvalue.R +0 -0
  213. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/stats/MetaPvalue1.R +0 -0
  214. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcgamaf/Maf2Vcf.py +0 -0
  215. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcgamaf/MafAddChr.py +0 -0
  216. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcgamaf/maf2vcf.pl +0 -0
  217. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Attach2Seurat.R +0 -0
  218. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/CDR3AAPhyschem.R +0 -0
  219. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/ClonalStats.R +0 -0
  220. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/CloneResidency.R +0 -0
  221. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/CloneSizeQQPlot.R +0 -0
  222. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/GIANA/GIANA.py +0 -0
  223. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/GIANA/GIANA4.py +0 -0
  224. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/GIANA/Imgt_Human_TRBV.fasta +0 -0
  225. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/GIANA/query.py +0 -0
  226. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-basic.R +0 -0
  227. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-clonality.R +0 -0
  228. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-diversity.R +0 -0
  229. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-geneusage.R +0 -0
  230. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-kmer.R +0 -0
  231. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-overlap.R +0 -0
  232. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-spectratyping.R +0 -0
  233. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-tracking.R +0 -0
  234. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch-vjjunc.R +0 -0
  235. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch.R +0 -0
  236. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/Immunarch2VDJtools.R +0 -0
  237. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/ImmunarchFilter.R +0 -0
  238. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/ImmunarchLoading.R +0 -0
  239. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/ImmunarchSplitIdents.R +0 -0
  240. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/SampleDiversity.R +0 -0
  241. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/ScRepCombiningExpression.R +0 -0
  242. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/ScRepLoading.R +0 -0
  243. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TCRClusterStats.R +0 -0
  244. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TCRClustering.R +0 -0
  245. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TCRDock.py +0 -0
  246. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA.R +0 -0
  247. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/Atchley_factors.csv +0 -0
  248. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/BriseisEncoder.py +0 -0
  249. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/MCMC_control.R +0 -0
  250. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/TrainedEncoder.h5 +0 -0
  251. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/fixed_b.csv +0 -0
  252. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/initialization.R +0 -0
  253. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/post_analysis.R +0 -0
  254. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/real_data.R +0 -0
  255. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/update.R +0 -0
  256. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/TESSA_source/utility.R +0 -0
  257. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/VJUsage.R +0 -0
  258. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/immunarch-patched.R +0 -0
  259. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/tcr/vdjtools-patch.sh +0 -0
  260. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/BcftoolsAnnotate.py +0 -0
  261. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/BcftoolsFilter.py +0 -0
  262. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/BcftoolsMerge.py +0 -0
  263. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/BcftoolsSort.py +0 -0
  264. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/BcftoolsView.py +0 -0
  265. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/TruvariBench.sh +0 -0
  266. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/TruvariBenchSummary.R +0 -0
  267. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/TruvariConsistency.R +0 -0
  268. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/Vcf2Bed.py +0 -0
  269. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfAnno.py +0 -0
  270. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfDownSample.sh +0 -0
  271. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfFilter.py +0 -0
  272. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfFix.py +0 -0
  273. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfFix_utils.py +0 -0
  274. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfIndex.py +0 -0
  275. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfIntersect.py +0 -0
  276. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfLiftOver.sh +0 -0
  277. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/VcfSplitSamples.py +0 -0
  278. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/vcf/bcftools_utils.py +0 -0
  279. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/web/Download.py +0 -0
  280. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/web/DownloadList.py +0 -0
  281. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/web/GCloudStorageDownloadBucket.py +0 -0
  282. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/web/GCloudStorageDownloadFile.py +0 -0
  283. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/scripts/web/gcloud_common.py +0 -0
  284. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/__init__.py +0 -0
  285. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/common_docstrs.py +0 -0
  286. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/gene.py +0 -0
  287. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/misc.py +0 -0
  288. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/reference.py +0 -0
  289. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/reporter.py +0 -0
  290. {biopipen-0.34.8 → biopipen-0.34.10}/biopipen/utils/vcf.py +0 -0
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.3
1
+ Metadata-Version: 2.4
2
2
  Name: biopipen
3
- Version: 0.34.8
3
+ Version: 0.34.10
4
4
  Summary: Bioinformatics processes/pipelines that can be run from `pipen run`
5
5
  License: MIT
6
6
  Author: pwwang
@@ -13,6 +13,7 @@ Classifier: Programming Language :: Python :: 3.10
13
13
  Classifier: Programming Language :: Python :: 3.11
14
14
  Classifier: Programming Language :: Python :: 3.12
15
15
  Classifier: Programming Language :: Python :: 3.13
16
+ Classifier: Programming Language :: Python :: 3.14
16
17
  Provides-Extra: runinfo
17
18
  Requires-Dist: datar[pandas] (>=0.15.8,<0.16.0)
18
19
  Requires-Dist: pipen-board[report] (>=0.17,<0.18)
@@ -0,0 +1 @@
1
+ __version__ = "0.34.10"
@@ -132,6 +132,9 @@ class MotifAffinityTest(Proc):
132
132
  If no `regulator_col` is provided, no regulator information is written in
133
133
  the output. Otherwise, the regulator information is written in the output in
134
134
  the `Regulator` column.
135
+ var_col: The column names in the `in.motiffile` containing the variant information.
136
+ It has to be matching the names in the `in.varfile`. This is helpful when
137
+ we only need to test the pairs of variants and motifs in the `in.motiffile`.
135
138
  notfound (choice): What to do if a motif is not found in the database,
136
139
  or a regulator is not found in the regulator-motif mapping (envs.regmotifs)
137
140
  file.
@@ -200,6 +203,7 @@ class MotifAffinityTest(Proc):
200
203
  "bcftools": config.exe.bcftools,
201
204
  "motif_col": None,
202
205
  "regulator_col": None,
206
+ "var_col": None,
203
207
  "notfound": "error",
204
208
  "motifdb": config.ref.tf_motifdb,
205
209
  "regmotifs": config.ref.tf_motifs,
@@ -118,6 +118,10 @@ class SeuratPreparing(Proc):
118
118
  It doesn't work when data is loaded from loom files.
119
119
  cell_qc: Filter expression to filter cells, using
120
120
  `tidyrseurat::filter()`.
121
+ It can also be a dictionary of expressions, where the names of the list are
122
+ sample names.
123
+ You can have a default expression in the list with the name "DEFAULT" for
124
+ the samples that are not listed.
121
125
  Available QC keys include `nFeature_RNA`, `nCount_RNA`,
122
126
  `percent.mt`, `percent.ribo`, `percent.hb`, and `percent.plat`.
123
127
 
@@ -782,11 +786,16 @@ class ModuleScoreCalculator(Proc):
782
786
  will perform diffusion map as a reduction and add the first 2
783
787
  components as `DC_1` and `DC_2` to the metadata. `diffmap` is a shortcut
784
788
  for `diffusion_map`. Other key-value pairs will pass to
785
- [`destiny::DiffusionMap()`](https://www.rdocumentation.org/packages/destiny/versions/2.0.4/topics/DiffusionMap%20class).
789
+ [`destiny::DiffusionMap()`](https://www.rdocumentation.org/packages/destiny/versions/2.0.4/topics/DiffusionMap class).
786
790
  You can later plot the diffusion map by using
787
791
  `reduction = "DC"` in `env.dimplots` in `SeuratClusterStats`.
788
792
  This requires [`SingleCellExperiment`](https://bioconductor.org/packages/release/bioc/html/SingleCellExperiment.html)
789
793
  and [`destiny`](https://bioconductor.org/packages/release/bioc/html/destiny.html) R packages.
794
+ post_mutaters (type=json): The mutaters to mutate the metadata after
795
+ calculating the module scores.
796
+ The mutaters will be applied in the order specified.
797
+ This is useful when you want to create new scores based on the
798
+ calculated module scores.
790
799
  """ # noqa: E501
791
800
 
792
801
  input = "srtobj:file"
@@ -810,6 +819,7 @@ class ModuleScoreCalculator(Proc):
810
819
  # "Activation": {"features": "IFNG"},
811
820
  # "Proliferation": {"features": "STMN1,TUBB"},
812
821
  },
822
+ "post_mutaters": {},
813
823
  }
814
824
  script = "file://../scripts/scrna/ModuleScoreCalculator.R"
815
825
 
@@ -1131,7 +1141,7 @@ class MarkersFinder(Proc):
1131
1141
  - res (type=int): The resolution of the plots.
1132
1142
  - height (type=int): The height of the plots.
1133
1143
  - width (type=int): The width of the plots.
1134
- - <more>: See <https://pwwang.github.io/scplotter/reference/EnrichmentPlot.htmll>.
1144
+ - <more>: See <https://pwwang.github.io/scplotter/reference/EnrichmentPlot.html>.
1135
1145
  enrich_plots (type=json): Cases of the plots to generate for the enrichment analysis.
1136
1146
  The keys are the names of the cases and the values are the dicts inherited from `enrich_plots_defaults`.
1137
1147
  The cases under `envs.cases` can inherit this options.
@@ -1781,6 +1791,11 @@ class CellTypeAnnotation(Proc):
1781
1791
  the original cell types will be kept and nothing will be changed.
1782
1792
  ///
1783
1793
 
1794
+ more_cell_types (type=json): The additional cell type annotations to add to the metadata.
1795
+ The keys are the new column names and the values are the cell types lists.
1796
+ The cell type lists work the same as `cell_types` above.
1797
+ This is useful when you want to keep multiple annotations of cell types.
1798
+
1784
1799
  sccatch_args (ns): The arguments for `scCATCH::findmarkergene()` if `tool` is `sccatch`.
1785
1800
  - species: The specie of cells.
1786
1801
  - cancer: If the sample is from cancer tissue, then the cancer type may be defined.
@@ -1842,6 +1857,7 @@ class CellTypeAnnotation(Proc):
1842
1857
  "sctype_tissue": None,
1843
1858
  "sctype_db": config.ref.sctype_db,
1844
1859
  "cell_types": [],
1860
+ "more_cell_types": None,
1845
1861
  "sccatch_args": {
1846
1862
  "species": None,
1847
1863
  "cancer": "Normal",
@@ -2524,6 +2540,10 @@ class CellCellCommunicationPlots(Proc):
2524
2540
  cases (type=json): The cases for the plots.
2525
2541
  The keys are the names of the cases and the values are the arguments for
2526
2542
  the plots. The arguments include the ones inherited from `envs`.
2543
+ You can have a special `plot_type` `"table"` to generate a table for the
2544
+ ccc data to save as a text file and show in the report.
2545
+ If no cases are given, a default case will be used, with the
2546
+ key `Cell-Cell Communication`.
2527
2547
  <more>: Other arguments passed to
2528
2548
  [scplotter::CCCPlot](https://pwwang.github.io/scplotter/reference/CCCPlot.html)
2529
2549
  """ # noqa: E501
@@ -14,6 +14,7 @@ bcftools <- {{envs.bcftools | r}}
14
14
  genome <- {{envs.genome | r}}
15
15
  motif_col <- {{envs.motif_col | r}}
16
16
  regulator_col <- {{envs.regulator_col | r}}
17
+ var_col <- {{envs.var_col | r}}
17
18
  notfound <- {{envs.notfound | r}}
18
19
  motifdb <- {{envs.motifdb | r}}
19
20
  regmotifs <- {{envs.regmotifs | r}}
@@ -21,6 +22,7 @@ devpars <- {{envs.devpars | r}}
21
22
  plot_nvars <- {{envs.plot_nvars | r}}
22
23
  plots <- {{envs.plots | r}}
23
24
  cutoff <- {{envs.cutoff | r}}
25
+ set.seed(8525)
24
26
 
25
27
  if (is.null(motifdb) || !file.exists(motifdb)) {
26
28
  stop("Motif database (envs.motifdb) is required and must exist")
@@ -47,10 +49,21 @@ log <- get_logger()
47
49
  log$info("Reading input regulator/motif file ...")
48
50
  in_motifs <- read.table(motiffile, header=TRUE, sep="\t", stringsAsFactors=FALSE, check.names = FALSE)
49
51
 
52
+
50
53
  log$info("Ensuring motifs and regulators in the input data ...")
51
- in_motifs <- ensure_regulator_motifs(in_motifs, outdir, motif_col, regulator_col, regmotifs, notfound = notfound)
54
+ in_motifs <- ensure_regulator_motifs(in_motifs, outdir, motif_col, regulator_col, var_col, regmotifs, notfound = notfound)
52
55
  genome_pkg <- get_genome_pkg(genome)
53
56
 
57
+ motif_var_pairs <- NULL
58
+ if (!is.null(var_col)) {
59
+ log$info("Obtaining motif-variant pairs to test ...")
60
+ if (!var_col %in% colnames(in_motifs)) {
61
+ stop("Variant column (envs.var_col) not found in the input motif file")
62
+ }
63
+
64
+ motif_var_pairs <- unique(paste0(in_motifs[[motif_col]], " // ", in_motifs[[var_col]]))
65
+ }
66
+
54
67
  log$info("Reading variant file ...")
55
68
  if (grepl("\\.vcf$", varfile) || grepl("\\.vcf\\.gz$", varfile)) {
56
69
  log$info("Converting VCF file to BED file ...")
@@ -77,10 +90,13 @@ mdb <- read_meme_to_motifdb(motifdb, in_motifs, motif_col, regulator_col, notfou
77
90
  tool <- tolower(tool)
78
91
  tool <- match.arg(tool, c("motifbreakr", "atsnp"))
79
92
 
80
- if (tool == "motifbreakr") {
93
+ {% if envs.tool == "motifbreakr" %}
81
94
  motifbreakr_args <- {{envs.motifbreakr_args | r}}
82
95
  {% include biopipen_dir + "/scripts/regulatory/MotifAffinityTest_MotifBreakR.R" %}
83
- } else { # atsnp
84
- atsnp_args <- {{envs.atsnp_args | r}}
96
+ {% else %}
97
+ atsnp_args <- list_update(
98
+ list(padj_cutoff = TRUE, padj = "BH", p = "Pval_diff"),
99
+ {{envs.atsnp_args | r}}
100
+ )
85
101
  {% include biopipen_dir + "/scripts/regulatory/MotifAffinityTest_AtSNP.R" %}
86
- }
102
+ {% endif %}
@@ -46,6 +46,13 @@ atsnp_result <- ComputePValues(
46
46
  testing.mc = TRUE
47
47
  )
48
48
 
49
+ if (!is.null(motif_var_pairs)) {
50
+ log$info("Filtering motif-variant pairs ...")
51
+ atsnp_result$motifs_vars <- paste0(atsnp_result$motif, " // ", atsnp_result$snpid)
52
+ atsnp_result <- atsnp_result[atsnp_result$motifs_vars %in% motif_var_pairs, , drop = FALSE]
53
+ atsnp_result$motifs_vars <- NULL
54
+ }
55
+
49
56
  padj_col <- paste0(atsnp_args$p, "_adj")
50
57
  atsnp_result[[padj_col]] <- p.adjust(atsnp_result[[atsnp_args$p]], method = atsnp_args$padj)
51
58
  cutoff_col <- if (atsnp_args$padj_cutoff) padj_col else atsnp_args$p
@@ -87,7 +94,8 @@ write.table(
87
94
 
88
95
  log$info("Plotting variants ...")
89
96
  # Convert result to GRanges object
90
- atsnp_result$alleleDiff <- -atsnp_result[[cutoff_col]]
97
+ atsnp_result$alleleDiff <- -log10(atsnp_result[[cutoff_col]])
98
+ atsnp_result <- atsnp_result[order(-atsnp_result$alleleDiff), , drop = FALSE]
91
99
  atsnp_result$effect <- "strong"
92
100
  atsnp_result$motifPos <- lapply(atsnp_result$motifPos, function(x) as.integer(unlist(strsplit(x, ","))))
93
101
  atsnp_result <- makeGRangesFromDataFrame(atsnp_result, keep.extra.columns = TRUE, starts.in.df.are.0based = TRUE)
@@ -96,7 +104,6 @@ attributes(atsnp_result)$genome.package <- genome_pkg
96
104
  attributes(atsnp_result)$motifs <- mdb
97
105
 
98
106
  if (is.null(plots) || length(plots) == 0) {
99
- atsnp_result <- atsnp_result[order(-abs(atsnp_result$alleleDiff)), , drop = FALSE]
100
107
  atsnp_result <- atsnp_result[1:min(plot_nvars, length(atsnp_result)), , drop = FALSE]
101
108
  variants <- unique(atsnp_result$SNP_id)
102
109
  } else {
@@ -50,6 +50,7 @@ results <- motifbreakR(
50
50
 
51
51
  log$info("Calculating p values ...")
52
52
  results <- calculatePvalue(results)
53
+ results$.id <- 1:length(results)
53
54
  results_to_save <- as.data.frame(unname(results))
54
55
  results_to_save$motifPos <- lapply(results_to_save$motifPos, function(x) paste(x, collapse = ","))
55
56
  results_to_save$altPos <- lapply(results_to_save$altPos, function(x) paste(x, collapse = ","))
@@ -60,20 +61,28 @@ if (!is.null(regulator_col)) {
60
61
  drop = TRUE
61
62
  ]
62
63
  }
63
- results_to_save <- apply(results_to_save, 2, as.character)
64
+ results_to_save <- as.data.frame(apply(results_to_save, 2, as.character))
65
+
66
+ if (!is.null(motif_var_pairs)) {
67
+ log$info("Filtering motif-variant pairs ...")
68
+ results_to_save$motifs_vars <- paste0(results_to_save$providerId, " // ", results_to_save$SNP_id)
69
+ results_to_save <- results_to_save[results_to_save$motifs_vars %in% motif_var_pairs, , drop = FALSE]
70
+ results_to_save$motifs_vars <- NULL
71
+ }
64
72
 
65
73
  write.table(
66
74
  results_to_save,
67
75
  file = file.path(outdir, "motifbreakr.txt"),
68
76
  sep = "\t", quote = FALSE, row.names = FALSE
69
77
  )
70
- rm(results_to_save)
78
+ # rm(results_to_save)
71
79
 
72
80
  log$info("Plotting variants ...")
73
81
  if (is.null(plots) || length(plots) == 0) {
74
- results <- results[order(-abs(results$alleleDiff)), , drop = FALSE]
75
- results <- results[1:min(plot_nvars, length(results)), , drop = FALSE]
76
- variants <- unique(results$SNP_id)
82
+ results_to_save$alleleDiff <- as.numeric(results_to_save$alleleDiff)
83
+ results_to_save <- results_to_save[order(-abs(results_to_save$alleleDiff)), , drop = FALSE]
84
+ results_to_save <- results_to_save[1:min(plot_nvars, nrow(results_to_save)), , drop = FALSE]
85
+ variants <- unique(results_to_save$SNP_id)
77
86
  } else {
78
87
  variants <- names(plots)
79
88
  }
@@ -88,7 +97,7 @@ for (variant in variants) {
88
97
  if (is.null(plots[[variant]]$devpars)) {
89
98
  plots[[variant]]$devpars <- devpars
90
99
  }
91
- res <- results[results$SNP_id == variant, , drop = FALSE]
100
+ res <- results[results$SNP_id == variant & results$.id %in% results_to_save$.id, , drop = FALSE]
92
101
  res <- subset(res, subset = eval(parse(text = plots[[variant]]$which)))
93
102
 
94
103
  plot_variant_motifs(res, variant, plots[[variant]]$devpars, outdir)
@@ -33,7 +33,7 @@ log$info("Reading input data ...")
33
33
  indata <- read.table(infile, header=TRUE, sep="\t", stringsAsFactors=FALSE, check.names = FALSE)
34
34
 
35
35
  log$info("Ensuring regulators in the input data ...")
36
- indata <- ensure_regulator_motifs(indata, outdir, motif_col, regulator_col, regmotifs, notfound = notfound)
36
+ indata <- ensure_regulator_motifs(indata, outdir, motif_col, regulator_col, "SNP_id", regmotifs, notfound = notfound)
37
37
  genome_pkg <- get_genome_pkg(genome)
38
38
 
39
39
  log$info("Reading motif database ...")
@@ -138,12 +138,13 @@ motifdb_to_motiflib <- function(motifdb) {
138
138
  #' @param outdir Output directory, used to save un-matched regulators
139
139
  #' @param motif_col Column name for the motif
140
140
  #' @param regulator_col Column name for the regulator
141
+ #' @param var_col Column name for the variant
141
142
  #' @param regmotifs Regulator-motif mapping file
142
143
  #' @param log_indent Indentation for log messages
143
144
  #' @param notfound Action to take if regulators are not found in the mapping file
144
145
  #' @return Data frame with regulators and motifs
145
146
  #' @export
146
- ensure_regulator_motifs <- function (indata, outdir, motif_col, regulator_col, regmotifs, log_indent = "", notfound = "error", log = NULL) {
147
+ ensure_regulator_motifs <- function (indata, outdir, motif_col, regulator_col, var_col, regmotifs, log_indent = "", notfound = "error", log = NULL) {
147
148
  if (is.null(motif_col)) {
148
149
  if (is.null(regmotifs)) {
149
150
  stop("Regulator-motif mapping file (envs.regmotifs) is required when no motif column (envs.motif_col) is provided")
@@ -198,7 +199,7 @@ ensure_regulator_motifs <- function (indata, outdir, motif_col, regulator_col, r
198
199
  regulator_col <<- rm_reg_col
199
200
  }
200
201
  } else {
201
- indata <- indata[!duplicated(indata[, c(regulator_col, motif_col), drop = FALSE]), , drop = FALSE]
202
+ indata <- indata[!duplicated(indata[, c(regulator_col, motif_col, var_col), drop = FALSE]), , drop = FALSE]
202
203
  }
203
204
 
204
205
  return(indata)
@@ -7,6 +7,10 @@ import scanpy
7
7
  import liana
8
8
  import liana.method.sc._liana_pipe as _liana_pipe
9
9
 
10
+ # AttributeError: module 'numpy' has no attribute 'product'
11
+ if not hasattr(np, "product"):
12
+ np.product = np.prod
13
+
10
14
  # monkey-patch liana.method.sc._liana_pipe._trimean due to the updates by scipy 1.14
11
15
  # https://github.com/scipy/scipy/commit/a660202652deead0f3b4b688eb9fdcdf9f74066c
12
16
  def _trimean(a, axis=0):
@@ -27,7 +27,7 @@ defaults <- list(
27
27
  devpars = list(res = 100)
28
28
  )
29
29
 
30
- cases <- expand_cases(cases, defaults)
30
+ cases <- expand_cases(cases, defaults, default_case = "Cell-Cell Communication")
31
31
  log <- get_logger()
32
32
  reporter <- get_reporter()
33
33
 
@@ -35,12 +35,31 @@ do_case <- function(name) {
35
35
  log$info("- Case: {name}")
36
36
  case <- cases[[name]]
37
37
  info <- case_info(name, outdir, is_dir = FALSE)
38
- case <- extract_vars(case, "subset", "devpars", "more_formats", "descr")
38
+ case <- extract_vars(case, subset_ = "subset", "devpars", "more_formats", "descr")
39
39
 
40
40
  case$data <- ccc
41
- if (!is.null(case$subset)) {
42
- case$data <- ccc %>% dplyr::filter(!!parse_expr(case$subset))
41
+ if (!is.null(subset_)) {
42
+ case$data <- ccc %>% dplyr::filter(!!parse_expr(subset_))
43
43
  }
44
+
45
+ if (identical(case$plot_type, "table")) {
46
+ write.table(
47
+ case$data,
48
+ file = paste0(info$prefix, ".txt"),
49
+ sep = "\t",
50
+ row.names = FALSE,
51
+ col.names = TRUE,
52
+ quote = FALSE
53
+ )
54
+ report <- list(
55
+ kind = "table",
56
+ data = list(nrows = 100),
57
+ src = paste0(info$prefix, ".txt")
58
+ )
59
+ reporter$add2(report, hs = c(info$section, info$name))
60
+ return()
61
+ }
62
+
44
63
  if (is.null(case$magnitude)) {
45
64
  case$magnitude <- NULL
46
65
  }
@@ -5,11 +5,15 @@ outfile <- {{out.outfile | r}}
5
5
  celltypes <- {{envs.cell_types | r}}
6
6
  newcol <- {{envs.newcol | r}}
7
7
  merge_same_labels <- {{envs.merge | r}}
8
+ more_cell_types <- {{envs.more_cell_types | r}}
8
9
 
9
10
  log <- biopipen.utils::get_logger()
10
11
 
11
12
  if (is.null(celltypes) || length(celltypes) == 0) {
12
13
  log$warn("No cell types are given!")
14
+ if (!is.null(more_cell_types) && length(more_cell_types) > 0) {
15
+ log$warn("`envs.celltypes` is not given, won't process `envs.more_cell_types`!")
16
+ }
13
17
 
14
18
  if (merge_same_labels) {
15
19
  log$warn("Ignoring 'envs.merge' because no cell types are given!")
@@ -25,26 +29,43 @@ if (is.null(celltypes) || length(celltypes) == 0) {
25
29
  } else {
26
30
  idents <- as.character(unique(idents))
27
31
  }
28
-
29
- if (length(celltypes) < length(idents)) {
30
- celltypes <- c(celltypes, idents[(length(celltypes) + 1):length(idents)])
31
- } else if (length(celltypes) > length(idents)) {
32
- celltypes <- celltypes[1:length(idents)]
33
- log$warn("The length of cell types is longer than the number of clusters!")
32
+ process_celltypes <- function(ct, key = NULL) {
33
+ if (length(ct) < length(idents)) {
34
+ ct <- c(ct, idents[(length(ct) + 1):length(idents)])
35
+ } else if (length(ct) > length(idents)) {
36
+ ct <- ct[1:length(idents)]
37
+ if (is.null(key)) {
38
+ log$warn("The length of cell types is longer than the number of clusters!")
39
+ } else {
40
+ log$warn(paste0("The length of cell types for '", key, "' is longer than the number of clusters!"))
41
+ }
42
+ }
43
+ for (i in seq_along(ct)) {
44
+ if (ct[i] == "-" || ct[i] == "") {
45
+ ct[i] <- idents[i]
46
+ }
47
+ }
48
+ names(ct) <- idents
49
+ return(ct)
34
50
  }
35
- for (i in seq_along(celltypes)) {
36
- if (celltypes[i] == "-" || celltypes[i] == "") {
37
- celltypes[i] <- idents[i]
51
+
52
+ if (!is.null(more_cell_types) && length(more_cell_types) > 0) {
53
+ for (key in names(more_cell_types)) {
54
+ ct <- more_cell_types[[key]]
55
+ ct <- process_celltypes(ct, key)
56
+ log$info(paste0("Adding additional cell type annotation: '", key, "' ..."))
57
+ sobj@meta.data[[key]] <- ct[as.character(Idents(sobj))]
38
58
  }
39
59
  }
40
- names(celltypes) <- idents
60
+
61
+ celltypes <- process_celltypes(celltypes)
41
62
 
42
63
  log$info("Renaming cell types ...")
43
64
  if (is.null(newcol)) {
44
65
  has_na <- "NA" %in% unlist(celltypes) || anyNA(unlist(celltypes))
45
66
  sobj$seurat_clusters_id <- Idents(sobj)
46
67
  celltypes$object <- sobj
47
- sobj <- do_call(RenameIdents, celltypes)
68
+ sobj <- biopipen.utils::do_call(RenameIdents, celltypes)
48
69
  sobj$seurat_clusters <- Idents(sobj)
49
70
  if (has_na) {
50
71
  log$info("Filtering clusters if NA ...")
@@ -65,5 +86,6 @@ if (is.null(celltypes) || length(celltypes) == 0) {
65
86
  sobj <- merge_clusters_with_same_labels(sobj, newcol)
66
87
  }
67
88
 
89
+ log$info("Saving Seurat object ...")
68
90
  biopipen.utils::save_obj(sobj, outfile)
69
91
  }
@@ -353,16 +353,24 @@ process_markers <- function(markers, info, case) {
353
353
  for (db in case$dbs) {
354
354
  plots <- list()
355
355
  for (plotname in names(case$enrich_plots)) {
356
- plotargs <- case$enrich_plots[[plotname]]
356
+ plotargs <- extract_vars(case$enrich_plots[[plotname]], "descr", allow_nonexisting = TRUE)
357
357
  plotargs$data <- enrich[enrich$Database == db, , drop = FALSE]
358
358
 
359
359
  p <- do_call(VizEnrichment, plotargs)
360
360
 
361
361
  if (plotargs$plot_type == "bar") {
362
362
  attr(p, "height") <- attr(p, "height") / 1.5
363
+ descr <- descr %||% glue::glue(
364
+ "The bar plot shows the top enriched terms in database '{db}', ",
365
+ "the x-axis shows the -log10 of the adjusted p-values, ",
366
+ "and the y-axis shows the term names. The number next to each bar indicates the overlap gene count."
367
+ )
363
368
  }
364
369
  outprefix <- file.path(info$prefix, paste0("enrich.", slugify(db), ".", slugify(plotname)))
365
370
  save_plot(p, outprefix, plotargs$devpars, formats = "png")
371
+ if (!is.null(descr)) {
372
+ plots[[length(plots) + 1]] <- list(kind = "descr", content = glue::glue(descr))
373
+ }
366
374
  plots[[length(plots) + 1]] <- reporter$image(outprefix, c(), FALSE)
367
375
  }
368
376
  reporter$add2(
@@ -1,11 +1,13 @@
1
- library(Seurat)
1
+ library(rlang)
2
2
  library(dplyr)
3
+ library(Seurat)
3
4
  library(biopipen.utils)
4
5
 
5
6
  sobjfile <- {{in.srtobj | r}}
6
7
  outfile <- {{out.rdsfile | r}}
7
8
  defaults <- {{envs.defaults | r}}
8
9
  modules <- {{envs.modules | r}}
10
+ post_mutaters <- {{envs.post_mutaters | r}}
9
11
 
10
12
  log <- get_logger()
11
13
 
@@ -134,6 +136,12 @@ for (key in names(modules)) {
134
136
  }
135
137
  }
136
138
 
139
+ if (!is.null(post_mutaters) && length(post_mutaters) > 0) {
140
+ log$info("Applying post mutaters ...")
141
+ sobj@meta.data <- sobj@meta.data %>%
142
+ mutate(!!!lapply(post_mutaters, parse_expr))
143
+ }
144
+
137
145
  # save seurat object
138
146
  log$info("Saving Seurat object ...")
139
147
  save_obj(sobj, outfile)
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "biopipen"
3
- version = "0.34.8"
3
+ version = "0.34.10"
4
4
  description = "Bioinformatics processes/pipelines that can be run from `pipen run`"
5
5
  authors = ["pwwang <pwwang@pwwang.com>"]
6
6
  license = "MIT"
@@ -86,7 +86,7 @@ entry_points = \
86
86
 
87
87
  setup_kwargs = {
88
88
  'name': 'biopipen',
89
- 'version': '0.34.8',
89
+ 'version': '0.34.10',
90
90
  'description': 'Bioinformatics processes/pipelines that can be run from `pipen run`',
91
91
  'long_description': 'None',
92
92
  'author': 'pwwang',
@@ -1 +0,0 @@
1
- __version__ = "0.34.8"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes