Scale¶
- Scale(scale, *args, **kwargs)[source]¶
Return a
ScaleBase
instance.- Parameters
scale (
ScaleBase
,str
, ortuple
) – The axis scale specification. If aScaleBase
instance already, the input argument is simply returned. Otherwise,scale
should be a string corresponding to one of the “registered” axis scales or axis scale presets (see below table).If
scale
is a list or tuple and the first element is a “registered” scale name, subsequent elements are passed to the scale class as positional arguments.Key
Class
Description
'linear'
Linear
'log'
Logarithmic
'symlog'
Logarithmic beyond finite space around zero
'logit'
Logistic
'inverse'
Inverse
'function'
Arbitrary forward and backwards transformations
'sine'
Sine function (in degrees)
'mercator'
Mercator latitude function (in degrees)
'exp'
Arbitrary exponential function
'power'
Arbitrary power function
'cutoff'
Arbitrary piecewise linear transformations
'quadratic'
PowerScale
(preset)Quadratic function
'cubic'
PowerScale
(preset)Cubic function
'quartic'
PowerScale
(preset)Quartic function
'db'
ExpScale
(preset)Ratio expressed as decibels
'np'
ExpScale
(preset)Ratio expressed as nepers
'idb'
ExpScale
(preset)Decibels expressed as ratio
'inp'
ExpScale
(preset)Nepers expressed as ratio
'pressure'
ExpScale
(preset)Height (in km) expressed linear in pressure
'height'
ExpScale
(preset)Pressure (in hPa) expressed linear in height
- Other Parameters
*args, **kwargs – Passed to the
ScaleBase
class.- Returns
ScaleBase
– The scale instance.