plotastrodata 1.9.17__tar.gz → 1.9.18__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {plotastrodata-1.9.17/plotastrodata.egg-info → plotastrodata-1.9.18}/PKG-INFO +1 -1
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/__init__.py +1 -1
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/plot_utils.py +25 -12
- {plotastrodata-1.9.17 → plotastrodata-1.9.18/plotastrodata.egg-info}/PKG-INFO +1 -1
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/LICENSE +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/MANIFEST.in +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/README.md +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/analysis_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/const_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/coord_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/ext_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/fft_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/fits_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/fitting_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/los_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/matrix_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/noise_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata/other_utils.py +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata.egg-info/SOURCES.txt +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata.egg-info/dependency_links.txt +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata.egg-info/not-zip-safe +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata.egg-info/requires.txt +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/plotastrodata.egg-info/top_level.txt +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/setup.cfg +0 -0
- {plotastrodata-1.9.17 → plotastrodata-1.9.18}/setup.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: plotastrodata
|
|
3
|
-
Version: 1.9.
|
|
3
|
+
Version: 1.9.18
|
|
4
4
|
Summary: plotastrodata is a tool for astronomers to create figures from FITS files and perform fundamental data analyses with ease.
|
|
5
5
|
Home-page: https://github.com/yusukeaso-astron/plotastrodata
|
|
6
6
|
Download-URL: https://github.com/yusukeaso-astron/plotastrodata
|
|
@@ -344,14 +344,14 @@ class PlotAxes2D():
|
|
|
344
344
|
Args:
|
|
345
345
|
samexy (bool, optional): True supports same ticks between x and y. Defaults to True.
|
|
346
346
|
loglog (float, optional): If a float is given, plot on a log-log plane, and xim=(xmax / loglog, xmax) and so does ylim. Defaults to None.
|
|
347
|
-
xscale (str, optional): Defaults to
|
|
348
|
-
yscale (str, optional): Defaults to
|
|
347
|
+
xscale (str, optional): ``'log'`` labels decade ticks and ticks near the limits; other intermediate ticks are minor and unlabeled. Defaults to ``'linear'``.
|
|
348
|
+
yscale (str, optional): ``'log'`` labels decade ticks and ticks near the limits; other intermediate ticks are minor and unlabeled. Defaults to ``'linear'``.
|
|
349
349
|
xlim (list, optional): Defaults to None.
|
|
350
350
|
ylim (list, optional): Defaults to None.
|
|
351
351
|
xlabel (str, optional): Defaults to None.
|
|
352
352
|
ylabel (str, optional): Defaults to None.
|
|
353
|
-
xticks (list, optional): Defaults to None.
|
|
354
|
-
yticks (list, optional): Defaults to None.
|
|
353
|
+
xticks (list, optional): Explicit major ticks, overriding the default locator. Defaults to None.
|
|
354
|
+
yticks (list, optional): Explicit major ticks, overriding the default locator. Defaults to None.
|
|
355
355
|
xticklabels (list, optional): Defaults to None.
|
|
356
356
|
yticklabels (list, optional): Defaults to None.
|
|
357
357
|
xticksminor (list or int, optional): If int, int times more than xticks. Defaults to None.
|
|
@@ -393,16 +393,25 @@ class PlotAxes2D():
|
|
|
393
393
|
def _init_ticks(self, axis: str) -> None:
|
|
394
394
|
ax = self.ax
|
|
395
395
|
ticks_attr = f'{axis}ticks'
|
|
396
|
-
ticklabels_attr = f'{axis}ticklabels'
|
|
397
396
|
scale = getattr(self, f'{axis}scale')
|
|
398
|
-
lim = getattr(self, f'{axis}lim')
|
|
399
397
|
ticks = getattr(self, ticks_attr)
|
|
400
398
|
if ticks is None:
|
|
401
|
-
ticks = getattr(ax, f'get_{axis}ticks')()
|
|
402
399
|
if scale == 'log':
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
400
|
+
axis_obj = getattr(ax, f'{axis}axis')
|
|
401
|
+
lim = getattr(self, f'{axis}lim')
|
|
402
|
+
if lim is None:
|
|
403
|
+
lim = axis_obj.get_view_interval()
|
|
404
|
+
lim = np.sort(lim)
|
|
405
|
+
major_ticks = mpl.ticker.LogLocator(base=10).tick_values(*lim)
|
|
406
|
+
major_ticks, major_labels = logticks(major_ticks, lim)
|
|
407
|
+
axis_obj.set_ticks(major_ticks)
|
|
408
|
+
axis_obj.set_ticklabels(major_labels)
|
|
409
|
+
ll = mpl.ticker.LogLocator(base=10, subs=np.arange(2.0, 10.0))
|
|
410
|
+
axis_obj.set_minor_locator(ll)
|
|
411
|
+
axis_obj.set_minor_formatter(mpl.ticker.NullFormatter())
|
|
412
|
+
else:
|
|
413
|
+
ticks = getattr(ax, f'get_{axis}ticks')()
|
|
414
|
+
setattr(self, ticks_attr, ticks)
|
|
406
415
|
|
|
407
416
|
def _make_ticks(self, ticks: np.ndarray, ticksminor: int) -> np.ndarray:
|
|
408
417
|
dt = ticks[1] - ticks[0]
|
|
@@ -414,11 +423,15 @@ class PlotAxes2D():
|
|
|
414
423
|
ax = self.ax
|
|
415
424
|
attr = f'{axis}ticks'
|
|
416
425
|
ticks = getattr(self, attr)
|
|
417
|
-
|
|
426
|
+
if ticks is not None:
|
|
427
|
+
getattr(ax, f'set_{attr}')(ticks)
|
|
418
428
|
ticksminor = getattr(self, f'{attr}minor')
|
|
419
429
|
if ticksminor is not None:
|
|
420
430
|
if isinstance(ticksminor, int):
|
|
421
|
-
|
|
431
|
+
if ticks is None:
|
|
432
|
+
ticks = getattr(ax, f'get_{axis}ticks')()
|
|
433
|
+
major_ticks = (ticks)
|
|
434
|
+
ticksminor = self._make_ticks(major_ticks, ticksminor)
|
|
422
435
|
getattr(ax, f'set_{attr}')(ticksminor, minor=True)
|
|
423
436
|
|
|
424
437
|
def _apply_if_not_none(self, axis: str, attr: str) -> None:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: plotastrodata
|
|
3
|
-
Version: 1.9.
|
|
3
|
+
Version: 1.9.18
|
|
4
4
|
Summary: plotastrodata is a tool for astronomers to create figures from FITS files and perform fundamental data analyses with ease.
|
|
5
5
|
Home-page: https://github.com/yusukeaso-astron/plotastrodata
|
|
6
6
|
Download-URL: https://github.com/yusukeaso-astron/plotastrodata
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|