Skip to content
Snippets Groups Projects
Commit e345d4bb authored by Jameson Graef Rollins's avatar Jameson Graef Rollins
Browse files

fix plotting of nested traces

Use more generic collections.abc.Mapping to detect a nested dict.
parent 01e4f900
No related branches found
No related tags found
No related merge requests found
from numpy import sqrt
from collections import OrderedDict
from collections.abc import Mapping
def plot_noise(
......@@ -25,7 +25,7 @@ def plot_noise(
ylim = kwargs.get('ylim')
for name, trace in traces.items():
if isinstance(trace, OrderedDict):
if isinstance(trace, Mapping):
trace = trace['Total']
try:
data, style = trace
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment