Skip to content

Commit 4438bb4

Browse files
committed
Rename Interval mark to Range for brevity
1 parent f728e94 commit 4438bb4

File tree

5 files changed

+13
-11
lines changed

5 files changed

+13
-11
lines changed

doc/api.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ Mark objects
3131
Bars
3232
Dot
3333
Dots
34-
Interval
35-
Path
36-
Paths
3734
Line
3835
Lines
36+
Path
37+
Paths
38+
Range
3939

4040
Stat objects
4141
~~~~~~~~~~~~

doc/nextgen/api.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,14 @@ Marks
3737
Area
3838
Band
3939
Bar
40+
Bars
4041
Dot
42+
Dots
4143
Line
4244
Lines
4345
Path
4446
Paths
45-
Scatter
47+
Range
4648

4749
Stats
4850
-----

seaborn/_marks/line.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ class Lines(Paths):
201201

202202

203203
@dataclass
204-
class Interval(Paths):
204+
class Range(Paths):
205205
"""
206206
An oriented line mark drawn between min/max values.
207207
"""

seaborn/objects.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
from seaborn._marks.base import Mark # noqa: F401
3232
from seaborn._marks.area import Area, Band # noqa: F401
3333
from seaborn._marks.bar import Bar, Bars # noqa: F401
34-
from seaborn._marks.line import Line, Lines, Path, Paths, Interval # noqa: F401
34+
from seaborn._marks.line import Line, Lines, Path, Paths, Range # noqa: F401
3535
from seaborn._marks.dot import Dot, Dots # noqa: F401
3636

3737
from seaborn._stats.base import Stat # noqa: F401

tests/_marks/test_line.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
from numpy.testing import assert_array_equal
77

88
from seaborn._core.plot import Plot
9-
from seaborn._marks.line import Line, Path, Lines, Paths, Interval
9+
from seaborn._marks.line import Line, Path, Lines, Paths, Range
1010

1111

1212
class TestPath:
@@ -244,15 +244,15 @@ def test_xy_data(self):
244244
assert_array_equal(verts[1], [3, 4])
245245

246246

247-
class TestInterval:
247+
class TestRange:
248248

249249
def test_xy_data(self):
250250

251251
x = [1, 2]
252252
ymin = [1, 4]
253253
ymax = [2, 3]
254254

255-
p = Plot(x=x, ymin=ymin, ymax=ymax).add(Interval()).plot()
255+
p = Plot(x=x, ymin=ymin, ymax=ymax).add(Range()).plot()
256256
lines, = p._figure.axes[0].collections
257257

258258
for i, path in enumerate(lines.get_paths()):
@@ -267,7 +267,7 @@ def test_mapped_color(self):
267267
ymax = [2, 3, 1, 4]
268268
group = ["a", "a", "b", "b"]
269269

270-
p = Plot(x=x, ymin=ymin, ymax=ymax, color=group).add(Interval()).plot()
270+
p = Plot(x=x, ymin=ymin, ymax=ymax, color=group).add(Range()).plot()
271271
lines, = p._figure.axes[0].collections
272272

273273
for i, path in enumerate(lines.get_paths()):
@@ -282,7 +282,7 @@ def test_direct_properties(self):
282282
ymin = [1, 4]
283283
ymax = [2, 3]
284284

285-
m = Interval(color="r", linewidth=4)
285+
m = Range(color="r", linewidth=4)
286286
p = Plot(x=x, ymin=ymin, ymax=ymax).add(m).plot()
287287
lines, = p._figure.axes[0].collections
288288

0 commit comments

Comments
 (0)