Skip to content

Commit 06a1e46

Browse files
committed
some docstring fixes
1 parent ee84479 commit 06a1e46

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,6 @@ format:
2727
lint:
2828
black --check .
2929
flake8 .
30+
31+
doc:
32+
sphinx-build -M html doc/ build/

tikzplotlib/_cleanfigure.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,22 +7,26 @@
77
STEP_DRAW_STYLES = ["steps-pre", "steps-post", "steps-mid"]
88

99

10-
def clean_figure(fig=None, target_resolution=600, scale_precision=1.0):
10+
def clean_figure(fig=None, target_resolution: int = 600, scale_precision: float = 1.0):
1111
"""Cleans figure as a preparation for tikz export.
1212
This will minimize the number of points required for the tikz figure.
1313
If the figure has subplots, it will recursively clean then up.
1414
1515
Note that this function modifies the figure directly (impure function).
1616
1717
:param fig: Matplotlib figure handle (Default value = None)
18+
1819
:param target_resolution: target resolution of final figure in PPI.
19-
If a scalar integer is provided, it is assumed to be square in both axis.
20-
If a list or an np.array is provided, it is interpreted as [H, W].
21-
By default 600
20+
If a scalar integer is provided, it is assumed to be
21+
square in both axis. If a list or an np.array is
22+
provided, it is interpreted as [H, W].
23+
By default 600
2224
:type target_resolution: int, list or np.array, optional
25+
2326
:param scalePrecision: scalar value indicating precision when scaling down.
24-
By default 1
27+
By default 1
2528
:type scalePrecision: float, optional
29+
2630
Examples
2731
--------
2832

0 commit comments

Comments
 (0)