Skip to content

Commit

Permalink
Bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JiayuSuPKU committed Nov 30, 2023
1 parent 390c511 commit 185f230
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions smoother/visualization.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import matplotlib.pyplot as plt
from mpl_toolkits.axes_grid1 import make_axes_locatable
from plotnine import *
from smoother.utils import normalize_minmax

def plot_celltype_props(p_inf, coords, cell_type_names = None, n_col = 4, figsize = None):
"""Plot the deconvolution results.
Expand Down Expand Up @@ -207,6 +208,9 @@ def cluster_and_plot_celltype_props(p_inf_list, coords, names = None, n_col = 4,
if isinstance(coords, pd.DataFrame):
coords = coords.values

# scale the coordinates for geom_tile
coords = normalize_minmax(coords)

# cluster cell type proportions
clu_inf_list = [
cluster_features(p_inf, transform = transform, n_neighbors=n_neighbors, res = res)
Expand Down

0 comments on commit 185f230

Please sign in to comment.