Changeset 1004 for trunk/UTIL/PYTHON
- Timestamp:
- Jul 9, 2013, 12:54:04 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UTIL/PYTHON/planetoplot_v2/ppplot.py
r1002 r1004 341 341 units="",\ 342 342 modx=None,\ 343 xmin=None,\ 344 ymin=None,\ 345 xmax=None,\ 346 ymax=None,\ 343 347 title=""): 344 348 ## what could be defined by the user … … 361 365 self.colorb = colorb 362 366 self.modx = modx 367 self.xmin = xmin 368 self.ymin = ymin 369 self.xmax = xmax 370 self.ymax = ymax 363 371 ## other useful arguments 364 372 ## ... not used here in ppplot but need to be attached to plot object … … 426 434 self.marker = marker 427 435 self.label = label 428 self.xmin = None429 self.ymin = None430 self.xmax = None431 self.ymax = None432 436 433 437 # define_from_var … … 650 654 zelevels, cmap=palette) 651 655 # make log axes and/or invert ordinate 656 ax = mpl.gca() 652 657 if self.logx: mpl.semilogx() 653 658 if self.logy: mpl.semilogy() 654 if self.invert: ax = mpl.gca() ; ax.set_ylim(ax.get_ylim()[::-1]) 659 if self.invert: ax.set_ylim(ax.get_ylim()[::-1]) 660 if self.xmin is not None: ax.set_xbound(lower=self.xmin) 661 if self.xmax is not None: ax.set_xbound(upper=self.xmax) 662 if self.ymin is not None: ax.set_ybound(lower=self.ymin) 663 if self.ymax is not None: ax.set_ybound(upper=self.ymax) 655 664 else: 656 665 ## A 2D MAP USING PROJECTIONS (basemap)
Note: See TracChangeset
for help on using the changeset viewer.