Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace pylab with matplotlib.pyplot #128

Merged
merged 2 commits into from
Dec 11, 2019
Merged
Changes from 1 commit
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
Next Next commit
Replace pylab with matplotlib.pyplot
  • Loading branch information
shanosborne committed Nov 25, 2019
commit a69491d42713214839044cbe8d871164da4614f3
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -59,7 +59,7 @@ Plotting (only a small subset of options is illustrated):
</p>

````
import pylab as pl
import matplotlib.pyplot as pl

pl.figure(figsize=(4, 4), facecolor='w', edgecolor='k'); pl.clf()

2 changes: 1 addition & 1 deletion examples/make_nircam_siaf_figures_script.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"""Script adaptation of make_nircam_siaf_figures.ipynb that also includes saving figures to PDF. """
import os
import pylab as pl
import matplotlib.pyplot as pl
import pysiaf

show_plot = True
2 changes: 1 addition & 1 deletion generate/generate_miri.py
Original file line number Diff line number Diff line change
@@ -22,7 +22,7 @@

from astropy.io import fits
import numpy as np
import pylab as pl
import matplotlib.pyplot as pl

import pysiaf
from pysiaf import iando
2 changes: 1 addition & 1 deletion generate/generate_nircam.py
Original file line number Diff line number Diff line change
@@ -20,7 +20,7 @@

import numpy as np
from astropy.table import Table
import pylab as pl
import matplotlib.pyplot as pl

import pysiaf
from pysiaf.utils import tools, compare
4 changes: 2 additions & 2 deletions pysiaf/aperture.py
Original file line number Diff line number Diff line change
@@ -32,7 +32,7 @@
import sys

import numpy as np
import pylab as pl
import matplotlib.pyplot as pl
from astropy.modeling import models
from astropy.table import Table
import astropy.units as u
@@ -504,7 +504,7 @@ def plot(self, frame='tel', label=False, ax=None, title=False, units='arcsec',
Add text label. If True, text will be the default aperture name.
ax : matplotlib.Axes
Desired destination axes to plot into (If None, current
axes are inferred from pylab)
axes are inferred)
title : str
Figure title. If set, add a label to the plot indicating which frame was plotted.
units : str
2 changes: 1 addition & 1 deletion pysiaf/siaf.py
Original file line number Diff line number Diff line change
@@ -25,7 +25,7 @@ class inherits from it. The class methods support basic operations and

from astropy.table import Table
import numpy as np
import pylab as pl
import matplotlib.pyplot as pl

from .iando import read

2 changes: 1 addition & 1 deletion pysiaf/tests/test_nirspec.py
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@
from astropy.table import Table
import copy
import numpy as np
import pylab as pl
import matplotlib.pyplot as pl
# import pytest


2 changes: 1 addition & 1 deletion pysiaf/tests/test_plotting.py
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@

import matplotlib
matplotlib.use('agg')
import pylab as pl
import matplotlib.pyplot as pl
import pytest

from ..constants import JWST_TEMPORARY_DATA_ROOT
2 changes: 1 addition & 1 deletion pysiaf/tests/test_polynomial.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

import numpy as np
from pysiaf.utils import polynomial
import pylab as pl
import matplotlib.pyplot as pl


def makeup_polynomial(order = 5):
2 changes: 1 addition & 1 deletion pysiaf/utils/compare.py
Original file line number Diff line number Diff line change
@@ -17,7 +17,7 @@

from astropy.table import vstack, Table
import numpy as np
import pylab as pl
import matplotlib.pyplot as pl

from ..constants import JWST_PRD_VERSION
from ..iando.read import get_siaf, read_siaf_aperture_definitions