Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions petab/visualize/plotter.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ def generate_lineplot(
if plotTypeData == REPLICATE:
replicates = np.stack(
measurements_to_plot.data_to_plot.repl.values)
if replicates.ndim == 1:
replicates = np.expand_dims(replicates, axis=1)

# plot first replicate
p = ax.plot(
Expand Down Expand Up @@ -544,6 +546,8 @@ def _line_plot_at_t_inf(
p = None
if plotTypeData == REPLICATE:
replicates = measurements_data_to_plot_inf.repl
if replicates.ndim == 0:
replicates = np.expand_dims(replicates, axis=0)

# plot first replicate
p = ax_inf.plot(
Expand Down Expand Up @@ -587,6 +591,8 @@ def _line_plot_at_t_inf(

if plotTypeData == REPLICATE:
replicates = simulations_data_to_plot_inf.repl
if replicates.ndim == 0:
replicates = np.expand_dims(replicates, axis=0)

# plot first replicate
p = ax_inf.plot(
Expand Down