@@ -542,8 +542,8 @@ def test_gaps(self):
542
542
ts .plot (ax = ax )
543
543
lines = ax .get_lines ()
544
544
assert len (lines ) == 1
545
- l = lines [0 ]
546
- data = l .get_xydata ()
545
+ line = lines [0 ]
546
+ data = line .get_xydata ()
547
547
assert isinstance (data , np .ma .core .MaskedArray )
548
548
mask = data .mask
549
549
assert mask [5 :25 , 1 ].all ()
@@ -557,8 +557,8 @@ def test_gaps(self):
557
557
ax = ts .plot (ax = ax )
558
558
lines = ax .get_lines ()
559
559
assert len (lines ) == 1
560
- l = lines [0 ]
561
- data = l .get_xydata ()
560
+ line = lines [0 ]
561
+ data = line .get_xydata ()
562
562
assert isinstance (data , np .ma .core .MaskedArray )
563
563
mask = data .mask
564
564
assert mask [2 :5 , 1 ].all ()
@@ -572,8 +572,8 @@ def test_gaps(self):
572
572
ser .plot (ax = ax )
573
573
lines = ax .get_lines ()
574
574
assert len (lines ) == 1
575
- l = lines [0 ]
576
- data = l .get_xydata ()
575
+ line = lines [0 ]
576
+ data = line .get_xydata ()
577
577
assert isinstance (data , np .ma .core .MaskedArray )
578
578
mask = data .mask
579
579
assert mask [2 :5 , 1 ].all ()
@@ -592,8 +592,8 @@ def test_gap_upsample(self):
592
592
lines = ax .get_lines ()
593
593
assert len (lines ) == 1
594
594
assert len (ax .right_ax .get_lines ()) == 1
595
- l = lines [0 ]
596
- data = l .get_xydata ()
595
+ line = lines [0 ]
596
+ data = line .get_xydata ()
597
597
598
598
assert isinstance (data , np .ma .core .MaskedArray )
599
599
mask = data .mask
@@ -608,8 +608,8 @@ def test_secondary_y(self):
608
608
assert hasattr (ax , 'left_ax' )
609
609
assert not hasattr (ax , 'right_ax' )
610
610
axes = fig .get_axes ()
611
- l = ax .get_lines ()[0 ]
612
- xp = Series (l .get_ydata (), l .get_xdata ())
611
+ line = ax .get_lines ()[0 ]
612
+ xp = Series (line .get_ydata (), line .get_xdata ())
613
613
assert_series_equal (ser , xp )
614
614
assert ax .get_yaxis ().get_ticks_position () == 'right'
615
615
assert not axes [0 ].get_yaxis ().get_visible ()
@@ -639,8 +639,8 @@ def test_secondary_y_ts(self):
639
639
assert hasattr (ax , 'left_ax' )
640
640
assert not hasattr (ax , 'right_ax' )
641
641
axes = fig .get_axes ()
642
- l = ax .get_lines ()[0 ]
643
- xp = Series (l .get_ydata (), l .get_xdata ()).to_timestamp ()
642
+ line = ax .get_lines ()[0 ]
643
+ xp = Series (line .get_ydata (), line .get_xdata ()).to_timestamp ()
644
644
assert_series_equal (ser , xp )
645
645
assert ax .get_yaxis ().get_ticks_position () == 'right'
646
646
assert not axes [0 ].get_yaxis ().get_visible ()
@@ -950,25 +950,25 @@ def test_from_resampling_area_line_mixed(self):
950
950
dtype = np .float64 )
951
951
expected_y = np .zeros (len (expected_x ), dtype = np .float64 )
952
952
for i in range (3 ):
953
- l = ax .lines [i ]
954
- assert PeriodIndex (l .get_xdata ()).freq == idxh .freq
955
- tm .assert_numpy_array_equal (l .get_xdata (orig = False ),
953
+ line = ax .lines [i ]
954
+ assert PeriodIndex (line .get_xdata ()).freq == idxh .freq
955
+ tm .assert_numpy_array_equal (line .get_xdata (orig = False ),
956
956
expected_x )
957
957
# check stacked values are correct
958
958
expected_y += low [i ].values
959
- tm .assert_numpy_array_equal (l .get_ydata (orig = False ),
959
+ tm .assert_numpy_array_equal (line .get_ydata (orig = False ),
960
960
expected_y )
961
961
962
962
# check high dataframe result
963
963
expected_x = idxh .to_period ().asi8 .astype (np .float64 )
964
964
expected_y = np .zeros (len (expected_x ), dtype = np .float64 )
965
965
for i in range (3 ):
966
- l = ax .lines [3 + i ]
967
- assert PeriodIndex (data = l .get_xdata ()).freq == idxh .freq
968
- tm .assert_numpy_array_equal (l .get_xdata (orig = False ),
966
+ line = ax .lines [3 + i ]
967
+ assert PeriodIndex (data = line .get_xdata ()).freq == idxh .freq
968
+ tm .assert_numpy_array_equal (line .get_xdata (orig = False ),
969
969
expected_x )
970
970
expected_y += high [i ].values
971
- tm .assert_numpy_array_equal (l .get_ydata (orig = False ),
971
+ tm .assert_numpy_array_equal (line .get_ydata (orig = False ),
972
972
expected_y )
973
973
974
974
# high to low
@@ -981,12 +981,12 @@ def test_from_resampling_area_line_mixed(self):
981
981
expected_x = idxh .to_period ().asi8 .astype (np .float64 )
982
982
expected_y = np .zeros (len (expected_x ), dtype = np .float64 )
983
983
for i in range (3 ):
984
- l = ax .lines [i ]
985
- assert PeriodIndex (data = l .get_xdata ()).freq == idxh .freq
986
- tm .assert_numpy_array_equal (l .get_xdata (orig = False ),
984
+ line = ax .lines [i ]
985
+ assert PeriodIndex (data = line .get_xdata ()).freq == idxh .freq
986
+ tm .assert_numpy_array_equal (line .get_xdata (orig = False ),
987
987
expected_x )
988
988
expected_y += high [i ].values
989
- tm .assert_numpy_array_equal (l .get_ydata (orig = False ),
989
+ tm .assert_numpy_array_equal (line .get_ydata (orig = False ),
990
990
expected_y )
991
991
992
992
# check low dataframe result
@@ -995,12 +995,12 @@ def test_from_resampling_area_line_mixed(self):
995
995
dtype = np .float64 )
996
996
expected_y = np .zeros (len (expected_x ), dtype = np .float64 )
997
997
for i in range (3 ):
998
- l = ax .lines [3 + i ]
999
- assert PeriodIndex (data = l .get_xdata ()).freq == idxh .freq
1000
- tm .assert_numpy_array_equal (l .get_xdata (orig = False ),
998
+ lines = ax .lines [3 + i ]
999
+ assert PeriodIndex (data = lines .get_xdata ()).freq == idxh .freq
1000
+ tm .assert_numpy_array_equal (lines .get_xdata (orig = False ),
1001
1001
expected_x )
1002
1002
expected_y += low [i ].values
1003
- tm .assert_numpy_array_equal (l .get_ydata (orig = False ),
1003
+ tm .assert_numpy_array_equal (lines .get_ydata (orig = False ),
1004
1004
expected_y )
1005
1005
1006
1006
@pytest .mark .slow
0 commit comments