File tree Expand file tree Collapse file tree 1 file changed +55
-0
lines changed Expand file tree Collapse file tree 1 file changed +55
-0
lines changed Original file line number Diff line number Diff line change 12
12
__all__ = ("xlab" , "ylab" , "labs" , "ggtitle" )
13
13
14
14
15
+ # TODO: Make keyword-only when python>=3.10
16
+ # i.e. @dataclass(kw_only=True)
15
17
@dataclass
16
18
class labs :
17
19
"""
@@ -20,20 +22,73 @@ class labs:
20
22
21
23
# Names of Scaled Aesthetics
22
24
x : str | None = None
25
+ """
26
+ Name of the x-axis.
27
+ """
28
+
23
29
y : str | None = None
30
+ """
31
+ Name of the y-axis.
32
+ """
33
+
24
34
alpha : str | None = None
35
+ """
36
+ Name of the alpha legend.
37
+ """
38
+
25
39
color : str | None = None
40
+ """
41
+ Name of the color legend or colorbar.
42
+ """
43
+
26
44
colour : str | None = None
45
+ """
46
+ Name of the colour legend or colourbar.
47
+
48
+ This is an alias of the `color` parameter. Only use one of
49
+ the spellings.
50
+ """
51
+
27
52
fill : str | None = None
53
+ """
54
+ Name of the fill legend/colourbar.
55
+ """
56
+
28
57
linetype : str | None = None
58
+ """
59
+ Name of the linetype legend.
60
+ """
61
+
29
62
shape : str | None = None
63
+ """
64
+ Name of the shape legend.
65
+ """
66
+
30
67
size : str | None = None
68
+ """
69
+ Name of the size legend.
70
+ """
71
+
31
72
stroke : str | None = None
73
+ """
74
+ Name of the stroke legend.
75
+ """
32
76
33
77
# Other texts
34
78
title : str | None = None
79
+ """
80
+ The title of the plot.
81
+ """
82
+
35
83
subtitle : str | None = None
84
+ """
85
+ The subtitle of the plot.
86
+ """
87
+
36
88
caption : str | None = None
89
+ """
90
+ The caption at the bottom of the plot.
91
+ """
37
92
38
93
def __post_init__ (self ):
39
94
kwargs : dict [str , str ] = {
You can’t perform that action at this time.
0 commit comments