Python matplotlib.ticker._Edge_integer() Examples
The following are 5
code examples of matplotlib.ticker._Edge_integer().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
matplotlib.ticker
, or try the search function
.
Example #1
Source File: dates.py From python3_ios with BSD 3-Clause "New" or "Revised" License | 6 votes |
def __init__(self, base=1, month=1, day=1, tz=None): """ Mark years that are multiple of base on a given month and day (default jan 1). """ DateLocator.__init__(self, tz) self.base = ticker._Edge_integer(base, 0) self.replaced = {'month': month, 'day': day, 'hour': 0, 'minute': 0, 'second': 0, } if not hasattr(tz, 'localize'): # if tz is pytz, we need to do this w/ the localize fcn, # otherwise datetime.replace works fine... self.replaced['tzinfo'] = tz
Example #2
Source File: dates.py From coffeegrindsize with MIT License | 6 votes |
def __init__(self, base=1, month=1, day=1, tz=None): """ Mark years that are multiple of base on a given month and day (default jan 1). """ DateLocator.__init__(self, tz) self.base = ticker._Edge_integer(base, 0) self.replaced = {'month': month, 'day': day, 'hour': 0, 'minute': 0, 'second': 0, } if not hasattr(tz, 'localize'): # if tz is pytz, we need to do this w/ the localize fcn, # otherwise datetime.replace works fine... self.replaced['tzinfo'] = tz
Example #3
Source File: dates.py From CogAlg with MIT License | 6 votes |
def __init__(self, base=1, month=1, day=1, tz=None): """ Mark years that are multiple of base on a given month and day (default jan 1). """ DateLocator.__init__(self, tz) self.base = ticker._Edge_integer(base, 0) self.replaced = {'month': month, 'day': day, 'hour': 0, 'minute': 0, 'second': 0, } if not hasattr(tz, 'localize'): # if tz is pytz, we need to do this w/ the localize fcn, # otherwise datetime.replace works fine... self.replaced['tzinfo'] = tz
Example #4
Source File: dates.py From GraphicDesignPatternByPython with MIT License | 5 votes |
def __init__(self, base=1, month=1, day=1, tz=None): """ Mark years that are multiple of base on a given month and day (default jan 1). """ DateLocator.__init__(self, tz) self.base = ticker._Edge_integer(base, 0) self.replaced = {'month': month, 'day': day, 'hour': 0, 'minute': 0, 'second': 0, 'tzinfo': tz }
Example #5
Source File: mpl_helper.py From xrayutilities with GNU General Public License v2.0 | 5 votes |
def __init__(self, nbins=7, symmetric=True): if parse_version(matplotlib.__version__) < parse_version('3.1.0'): self._base = mticker.Base(1.0) else: self._base = mticker._Edge_integer(1.0, 0) self.set_params(nbins, symmetric)