Bases: dateutil.rrule.rrulebase
That's the base of the rrule operation. It accepts all the keywords defined in the RFC as its constructor parameters (except byday, which was renamed to byweekday) and more. The constructor prototype is:
Where freq must be one of YEARLY, MONTHLY, WEEKLY, DAILY, HOURLY, MINUTELY, or SECONDLY.
Note
Per RFC section 3.3.10, recurrence instances falling on invalid dates and times are ignored rather than coerced:
Recurrence rules may generate recurrence instances with an invalid date (e.g., February 30) or nonexistent local time (e.g., 1:30 AM on a day where the local time is moved forward by an hour at 1:00 AM). Such recurrence instances MUST be ignored and MUST NOT be counted as part of the recurrence set.
This can lead to possibly surprising behavior when, for example, the start date occurs at the end of the month:
Additionally, it supports the following keyword arguments:
count --
If given, this determines how many occurrences will be generated.
Note
As of version 2.5.0, the use of the keyword until in conjunction with count is deprecated, to make sure dateutil is fully compliant with RFC-5545 Sec. 3.3.10. Therefore, until and count must not occur in the same call to rrule.
until --
If given, this must be a datetime instance specifying the upper-bound limit of the recurrence. The last recurrence in the rule is the greatest datetime that is less than or equal to the value specified in the until parameter.
Note
As of version 2.5.0, the use of the keyword until in conjunction with count is deprecated, to make sure dateutil is fully compliant with RFC-5545 Sec. 3.3.10. Therefore, until and count must not occur in the same call to rrule.
Return new rrule with same attributes except for those attributes given new values by whichever keyword arguments are specified.


Return new rrule with same attributes except for those attributes given new values by whichever keyword arguments are specified.


Bases: matplotlib.dates.DateLocator
Return the values of the located ticks given vmin and vmax.
Note
To get tick locations with the vmin and vmax values defined automatically for the associated axis simply call the Locator instance:


Return the values of the located ticks given vmin and vmax.
Note
To get tick locations with the vmin and vmax values defined automatically for the associated axis simply call the Locator instance:


Bases: matplotlib.dates.RRuleLocator
Make ticks on occurrences of each second.
Mark every second in bysecond; bysecond can be an int or sequence. Default is to tick every second: bysecond = range(60)
interval is the interval between each iteration. For example, if interval=2, mark every second occurrence.


Set the epoch (origin for dates) for datetime calculations.
The default epoch is rcParams["dates.epoch"] (by default 1970-01-01T00:00).
If microsecond accuracy is desired, the date being plotted needs to be within approximately 70 years of the epoch. Matplotlib internally represents dates as days since the epoch, so floating point dynamic range needs to be within a factor of 2^52.
set_epoch must be called before any dates are converted (i.e. near the import section) or a RuntimeError will be raised.
See also Date Precision and Epochs.
valid UTC date parsable by numpy.datetime64 (do not include timezone).


Bases: matplotlib.dates.RRuleLocator
Make ticks on occurrences of each weekday.
Mark every weekday in byweekday; byweekday can be a number or sequence.
Elements of byweekday must be one of MO, TU, WE, TH, FR, SA, SU, the constants from dateutil.rrule, which have been imported into the matplotlib.dates namespace.
interval specifies the number of weeks to skip. For example, interval=2 plots every second week.


Bases: matplotlib.dates.RRuleLocator
Make ticks on a given day of each year that is a multiple of base.
Examples:
Mark years that are multiple of base on a given month and day (default jan 1).


Bases: object
A decorator that performs %-substitution on an object's docstring.
This decorator should be robust even if obj.__doc__ is None (for example, if -OO was passed to the interpreter).
Usage: construct a docstring.Substitution with a sequence or dictionary suitable for performing substitution; then decorate a suitable function with the constructed object, e.g.:
One can also use positional arguments:
Update self.params (which must be a dict) with the supplied args.
Copy a docstring from another source function (if present).


Copy a docstring from another source function (if present).


Bases: object
A decorator that performs %-substitution on an object's docstring.
This decorator should be robust even if obj.__doc__ is None (for example, if -OO was passed to the interpreter).
Usage: construct a docstring.Substitution with a sequence or dictionary suitable for performing substitution; then decorate a suitable function with the constructed object, e.g.:
One can also use positional arguments:
Update self.params (which must be a dict) with the supplied args.


Update self.params (which must be a dict) with the supplied args.


A module for reading dvi files output by TeX. Several limitations make this not (currently) useful as a general-purpose dvi preprocessor, but it is currently used by the pdf backend for processing usetex text.
Interface:
Bases: object
A reader for a dvi ("device-independent") file, as produced by TeX.
The current implementation can only iterate through pages in order, and does not even attempt to verify the postamble.
This class can be used as a context manager to close the underlying file upon exit. Pages can be read via iteration. Here is an overly simple way to extract text without trying to detect whitespace:
Read the data from the file named filename and convert TeX's internal units to units of dpi per inch. dpi only sets the units and does not limit the resolution. Use None to return TeX's internal units.
Close the underlying file if it is open.
Bases: object
Encapsulation of a font that a DVI file can refer to.
This class holds a font's texname and size, supports comparison, and knows the widths of glyphs in the same units as the AFM file. There are also internal attributes (for use by dviread.py) that are not used for comparison.
The size is in Adobe points (converted from TeX points).
Factor by which the font is scaled from its natural size.
TeX font metrics for this font
Name of the font as used internally by TeX and friends, as an ASCII bytestring. This is usually very different from any external font names; PsfontsMap can be used to find the external name of the font.
A TeX "virtual font" file, or None if this font is not virtual.
Size of the font in Adobe points, converted from the slightly smaller TeX points.
Widths of glyphs in glyph-space units, typically 1/1000ths of the point size.
Bases: tuple
Create new instance of PsFont(texname, psname, effects, encoding, filename)
Alias for field number 2
Alias for field number 3
Alias for field number 4
Alias for field number 1
Alias for field number 0
Bases: object
A psfonts.map formatted file, mapping TeX fonts to PS fonts.
For historical reasons, TeX knows many Type-1 fonts by different names than the outside world. (For one thing, the names have to fit in eight characters.) Also, TeX's native fonts are not Type-1 but Metafont, which is nontrivial to convert to PostScript except as a bitmap. While high-quality conversions to Type-1 format exist and are shipped with modern TeX distributions, we need to know which Type-1 fonts are the counterparts of which native fonts. For these reasons a mapping is needed from internal font names to font file names.
A texmf tree typically includes mapping files called e.g. psfonts.map, pdftex.map, or dvipdfm.map. The file psfonts.map is used by dvips, pdftex.map by pdfTeX, and dvipdfm.map by dvipdfm. psfonts.map might avoid embedding the 35 PostScript fonts (i.e., have no filename for them, as in the Times-Bold example above), while the pdf-related files perhaps only avoid the "Base 14" pdf fonts. But the user may have configured these files differently.
Bases: object
A TeX Font Metric file.
This implementation covers only the bare minimum needed by the Dvi class.
Used for verifying against the dvi file.
Design size of the font (unknown units)
Dimensions of each character, need to be scaled by the factor specified in the dvi file. These are dicts because indexing may not start from 0.
Bases: matplotlib.dviread.Dvi
A virtual font (*.vf file) containing subroutines for dvi files.
The virtual font format is a derivative of dvi: http://mirrors.ctan.org/info/knuth/virtual-fonts This class reuses some of the machinery of Dvi but replaces the _read loop and dispatch mechanism.
Read the data from the file named filename and convert TeX's internal units to units of dpi per inch. dpi only sets the units and does not limit the resolution. Use None to return TeX's internal units.
Find a file in the texmf tree.
Calls kpsewhich which is an interface to the kpathsea library [1]. Most existing TeX distributions on Unix-like systems use kpathsea. It is also available as part of MikTeX, a popular distribution on Windows.
If the file is not found, an empty string is returned.
Used as the value of the --format option to kpsewhich. Could be e.g. 'tfm' or 'vf' to limit the search to that type of files. Deprecated.
Kpathsea documentation The library that kpsewhich is part of.


Bases: object
A reader for a dvi ("device-independent") file, as produced by TeX.
The current implementation can only iterate through pages in order, and does not even attempt to verify the postamble.
This class can be used as a context manager to close the underlying file upon exit. Pages can be read via iteration. Here is an overly simple way to extract text without trying to detect whitespace:
Read the data from the file named filename and convert TeX's internal units to units of dpi per inch. dpi only sets the units and does not limit the resolution. Use None to return TeX's internal units.
Close the underlying file if it is open.


Close the underlying file if it is open.


Bases: object
Encapsulation of a font that a DVI file can refer to.
This class holds a font's texname and size, supports comparison, and knows the widths of glyphs in the same units as the AFM file. There are also internal attributes (for use by dviread.py) that are not used for comparison.
The size is in Adobe points (converted from TeX points).
Factor by which the font is scaled from its natural size.
TeX font metrics for this font
Name of the font as used internally by TeX and friends, as an ASCII bytestring. This is usually very different from any external font names; PsfontsMap can be used to find the external name of the font.
A TeX "virtual font" file, or None if this font is not virtual.
Size of the font in Adobe points, converted from the slightly smaller TeX points.
Widths of glyphs in glyph-space units, typically 1/1000ths of the point size.


Find a file in the texmf tree.
Calls kpsewhich which is an interface to the kpathsea library [1]. Most existing TeX distributions on Unix-like systems use kpathsea. It is also available as part of MikTeX, a popular distribution on Windows.
If the file is not found, an empty string is returned.
Used as the value of the --format option to kpsewhich. Could be e.g. 'tfm' or 'vf' to limit the search to that type of files. Deprecated.
Kpathsea documentation The library that kpsewhich is part of.


Bases: tuple
Create new instance of PsFont(texname, psname, effects, encoding, filename)
Alias for field number 2
Alias for field number 3
Alias for field number 4
Alias for field number 1
Alias for field number 0


Bases: object
A psfonts.map formatted file, mapping TeX fonts to PS fonts.
For historical reasons, TeX knows many Type-1 fonts by different names than the outside world. (For one thing, the names have to fit in eight characters.) Also, TeX's native fonts are not Type-1 but Metafont, which is nontrivial to convert to PostScript except as a bitmap. While high-quality conversions to Type-1 format exist and are shipped with modern TeX distributions, we need to know which Type-1 fonts are the counterparts of which native fonts. For these reasons a mapping is needed from internal font names to font file names.
A texmf tree typically includes mapping files called e.g. psfonts.map, pdftex.map, or dvipdfm.map. The file psfonts.map is used by dvips, pdftex.map by pdfTeX, and dvipdfm.map by dvipdfm. psfonts.map might avoid embedding the 35 PostScript fonts (i.e., have no filename for them, as in the Times-Bold example above), while the pdf-related files perhaps only avoid the "Base 14" pdf fonts. But the user may have configured these files differently.


Bases: object
A TeX Font Metric file.
This implementation covers only the bare minimum needed by the Dvi class.
Used for verifying against the dvi file.
Design size of the font (unknown units)
Dimensions of each character, need to be scaled by the factor specified in the dvi file. These are dicts because indexing may not start from 0.


Bases: matplotlib.dviread.Dvi
A virtual font (*.vf file) containing subroutines for dvi files.
The virtual font format is a derivative of dvi: http://mirrors.ctan.org/info/knuth/virtual-fonts This class reuses some of the machinery of Dvi but replaces the _read loop and dispatch mechanism.
Read the data from the file named filename and convert TeX's internal units to units of dpi per inch. dpi only sets the units and does not limit the resolution. Use None to return TeX's internal units.