Skip to content

Commit fa4067f

Browse files
fixed minor bugs in plotting functions
1 parent bb4d7e4 commit fa4067f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

diffxpy/testing/det.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1113,7 +1113,7 @@ def plot_gene_fits(
11131113
from matplotlib import rcParams
11141114

11151115
plt.ioff()
1116-
nrows = len(par_loc) // ncols + int((len(par_loc) % ncols) > 0)
1116+
nrows = len(gene_names) // ncols + int((len(gene_names) % ncols) > 0)
11171117

11181118
gs = gridspec.GridSpec(
11191119
nrows=nrows,
@@ -1142,14 +1142,14 @@ def plot_gene_fits(
11421142
})
11431143
if covariate_x is not None:
11441144
if covariate_x in self.model_estim.design_loc.columns:
1145-
summary_fit["x"] = self.model_estim.design_loc.[covariate_x]
1146-
else
1145+
summary_fit["x"] = self.model_estim.design_loc[covariate_x]
1146+
else:
11471147
raise ValueError("covariate_x=%s not found in location model" % covariate_x)
11481148

11491149
if covariate_hue is not None:
11501150
if covariate_hue in self.model_estim.design_loc.columns:
1151-
summary_fit["hue"] = self.model_estim.design_loc.[covariate_hue]
1152-
else
1151+
summary_fit["hue"] = self.model_estim.design_loc[covariate_hue]
1152+
else:
11531153
raise ValueError("covariate_x=%s not found in location model" % covariate_x)
11541154

11551155
# Prepare model fit plot.

0 commit comments

Comments
 (0)