SpatialQuery 0.0.6__tar.gz → 0.0.7__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 (35) hide show
  1. {spatialquery-0.0.6/SpatialQuery.egg-info → spatialquery-0.0.7}/PKG-INFO +1 -1
  2. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/spatial_query.py +2 -24
  3. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/spatial_query_multiple_fov.py +2 -20
  4. {spatialquery-0.0.6 → spatialquery-0.0.7/SpatialQuery.egg-info}/PKG-INFO +1 -1
  5. {spatialquery-0.0.6 → spatialquery-0.0.7}/pyproject.toml +1 -1
  6. {spatialquery-0.0.6 → spatialquery-0.0.7}/LICENSE +0 -0
  7. {spatialquery-0.0.6 → spatialquery-0.0.7}/MANIFEST.in +0 -0
  8. {spatialquery-0.0.6 → spatialquery-0.0.7}/README.md +0 -0
  9. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/__init__.py +0 -0
  10. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/plotting.py +0 -0
  11. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/__init__.py +0 -0
  12. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/core_methods.py +0 -0
  13. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/EliasFano.h +0 -0
  14. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/QueryScore.cpp +0 -0
  15. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/QueryScore.h +0 -0
  16. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/Serialization.h +0 -0
  17. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/__init__.py +0 -0
  18. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/const.h +0 -0
  19. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/eliasFano.cpp +0 -0
  20. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/fp_growth.cpp +0 -0
  21. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/fp_growth.h +0 -0
  22. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/serialization.cpp +0 -0
  23. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/typedef.h +0 -0
  24. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/utils.cpp +0 -0
  25. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/scfind4sp/cpp_src/utils.h +0 -0
  26. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/spatial_differential_pattern.py +0 -0
  27. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/spatial_gene_covarying.py +0 -0
  28. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/spatial_utils.py +0 -0
  29. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery/utils.py +0 -0
  30. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery.egg-info/SOURCES.txt +0 -0
  31. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery.egg-info/dependency_links.txt +0 -0
  32. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery.egg-info/requires.txt +0 -0
  33. {spatialquery-0.0.6 → spatialquery-0.0.7}/SpatialQuery.egg-info/top_level.txt +0 -0
  34. {spatialquery-0.0.6 → spatialquery-0.0.7}/setup.cfg +0 -0
  35. {spatialquery-0.0.6 → spatialquery-0.0.7}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: SpatialQuery
3
- Version: 0.0.6
3
+ Version: 0.0.7
4
4
  Summary: Spatial query tools for analyzing spatial transcriptomics data
5
5
  Author-email: Shaokun An <shan12@bwh.harvard.edu>
6
6
  License-Expression: MIT
@@ -439,18 +439,7 @@ class spatial_query:
439
439
  'n_motif', 'expectation', 'p-values', 'if_significant'])
440
440
  return out_pd
441
441
 
442
- if len(out_pd) == 1:
443
- out_pd['if_significant'] = True if out_pd['p-values'][0] < 0.05 else False
444
- return out_pd
445
- else:
446
- p_values = out_pd['p-values'].tolist()
447
- if_rejected, corrected_p_values = mt.fdrcorrection(p_values,
448
- alpha=0.05,
449
- method='poscorr')
450
- out_pd['adj-pval'] = corrected_p_values
451
- out_pd['if_significant'] = if_rejected
452
- out_pd = out_pd.sort_values(by='adj-pval', ignore_index=True)
453
- return out_pd
442
+ return spatial_utils.apply_fdr_correction(out_pd)
454
443
 
455
444
  def motif_enrichment_dist(self,
456
445
  ct: str,
@@ -637,18 +626,7 @@ class spatial_query:
637
626
  'n_motif', 'expectation', 'p-values', 'if_significant'])
638
627
  return out_pd
639
628
 
640
- if len(out_pd) == 1:
641
- out_pd['if_significant'] = True if out_pd['p-values'][0] < 0.05 else False
642
- return out_pd
643
- else:
644
- p_values = out_pd['p-values'].tolist()
645
- if_rejected, corrected_p_values = mt.fdrcorrection(p_values,
646
- alpha=0.05,
647
- method='poscorr')
648
- out_pd['adj-pval'] = corrected_p_values
649
- out_pd['if_significant'] = if_rejected
650
- out_pd = out_pd.sort_values(by='adj-pval', ignore_index=True)
651
- return out_pd
629
+ return spatial_utils.apply_fdr_correction(out_pd)
652
630
 
653
631
  def motif_composition_dist(self,
654
632
  ct: str,
@@ -571,16 +571,7 @@ class spatial_query_multi:
571
571
 
572
572
  out_pd = pd.DataFrame(out)
573
573
 
574
- if len(out_pd) == 1:
575
- out_pd['if_significant'] = True if out_pd['p-values'][0] < 0.05 else False
576
- else:
577
- p_values = out_pd['p-values'].tolist()
578
- if_rejected, corrected_p_values = mt.fdrcorrection(p_values,
579
- alpha=0.05,
580
- method='poscorr')
581
- out_pd['adj-pval'] = corrected_p_values
582
- out_pd['if_significant'] = if_rejected
583
- out_pd = out_pd.sort_values(by='adj-pval', ignore_index=True)
574
+ out_pd = apply_fdr_correction(out_pd)
584
575
 
585
576
  if return_cellID:
586
577
  return out_pd, motif_cell_ids, center_cell_ids
@@ -850,16 +841,7 @@ class spatial_query_multi:
850
841
 
851
842
  out_pd = pd.DataFrame(out)
852
843
 
853
- if len(out_pd) == 1:
854
- out_pd['if_significant'] = True if out_pd['p-values'][0] < 0.05 else False
855
- else:
856
- p_values = out_pd['p-values'].tolist()
857
- if_rejected, corrected_p_values = mt.fdrcorrection(p_values,
858
- alpha=0.05,
859
- method='poscorr')
860
- out_pd['adj-pval'] = corrected_p_values
861
- out_pd['if_significant'] = if_rejected
862
- out_pd = out_pd.sort_values(by='adj-pval', ignore_index=True)
844
+ out_pd = apply_fdr_correction(out_pd)
863
845
 
864
846
  if return_cellID:
865
847
  return out_pd, motif_cell_ids, center_cell_ids
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: SpatialQuery
3
- Version: 0.0.6
3
+ Version: 0.0.7
4
4
  Summary: Spatial query tools for analyzing spatial transcriptomics data
5
5
  Author-email: Shaokun An <shan12@bwh.harvard.edu>
6
6
  License-Expression: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "SpatialQuery"
7
- version = "0.0.6"
7
+ version = "0.0.7"
8
8
  description = "Spatial query tools for analyzing spatial transcriptomics data"
9
9
  readme = "README.md"
10
10
  license = "MIT"
File without changes
File without changes
File without changes
File without changes
File without changes