| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -14,7 +14,7 @@ | |||
| 14 | 14 | # make sure we have Python 3.6 or better | |
| 15 | 15 | import sys | |
| 16 | 16 | if sys.version_info < (3, 6): | |
| 17 | - logger.warn('modsim.py depends on Python 3.6 features.') | ||
| 17 | + logger.warning('modsim.py depends on Python 3.6 features.') | ||
| 18 | 18 | ||
| 19 | 19 | import inspect | |
| 20 | 20 | import matplotlib.pyplot as plt | |
@@ -385,7 +385,7 @@ def run_odeint(system, slope_func, **options): | |||
| 385 | 385 | solution will be computed:""" | |
| 386 | 386 | raise ValueError(msg) | |
| 387 | 387 | ||
| 388 | - # make sure `system` contains `ts` | ||
| 388 | + # make sure `system` contains `init` | ||
| 389 | 389 | if not hasattr(system, 'init'): | |
| 390 | 390 | msg = """It looks like `system` does not contain `init` | |
| 391 | 391 | as a system variable. `init` should be a State | |
@@ -729,10 +729,10 @@ def contour(df, **options): | |||
| 729 | 729 | ||
| 730 | 730 | df: DataFrame | |
| 731 | 731 | """ | |
| 732 | - x = results.columns | ||
| 733 | - y = results.index | ||
| 732 | + x = df.columns | ||
| 733 | + y = df.index | ||
| 734 | 734 | X, Y = np.meshgrid(x, y) | |
| 735 | - cs = plt.contour(X, Y, results, **options) | ||
| 735 | + cs = plt.contour(X, Y, df, **options) | ||
| 736 | 736 | plt.clabel(cs, inline=1, fontsize=10) | |
| 737 | 737 | ||
| 738 | 738 | ||
@@ -812,13 +812,13 @@ def __init__(self, fig, axes_seq): | |||
| 812 | 812 | self.axes_seq = axes_seq | |
| 813 | 813 | self.current_axes_index = 0 | |
| 814 | 814 | ||
| 815 | - def current_axes(): | ||
| 815 | + def current_axes(self): | ||
| 816 | 816 | return self.axes_seq(self.current_axes_index) | |
| 817 | 817 | ||
| 818 | 818 | # TODO: consider making SubPlots iterable | |
| 819 | 819 | def next_axes(self): | |
| 820 | 820 | self.current_axes_index += 1 | |
| 821 | - return current_axes() | ||
| 821 | + return self.current_axes() | ||
| 822 | 822 | ||
| 823 | 823 | ||
| 824 | 824 | def subplots(*args, **options): | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -14,7 +14,7 @@ | |||
| 14 | 14 | # make sure we have Python 3.6 or better | |
| 15 | 15 | import sys | |
| 16 | 16 | if sys.version_info < (3, 6): | |
| 17 | - logger.warn('modsim.py depends on Python 3.6 features.') | ||
| 17 | + logger.warning('modsim.py depends on Python 3.6 features.') | ||
| 18 | 18 | ||
| 19 | 19 | import inspect | |
| 20 | 20 | import matplotlib.pyplot as plt | |
| Back | FazBrowse Home | New Git URL |
0 commit comments