@@ -744,6 +744,7 @@ def test_probplot_prob(plot_data):
744
744
745
745
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
746
746
def test_probplot_qq (plot_data ):
747
+ plt .close ("all" )
747
748
fig , ax = plt .subplots ()
748
749
fig = viz .probplot (
749
750
plot_data ,
@@ -759,6 +760,7 @@ def test_probplot_qq(plot_data):
759
760
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
760
761
@pytest .mark .skipif (stats is None , reason = "no scipy" )
761
762
def test_probplot_qq_dist (plot_data ):
763
+ plt .close ("all" )
762
764
fig , ax = plt .subplots ()
763
765
norm = stats .norm (* stats .norm .fit (plot_data ))
764
766
fig = viz .probplot (
@@ -769,6 +771,7 @@ def test_probplot_qq_dist(plot_data):
769
771
770
772
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
771
773
def test_probplot_pp (plot_data ):
774
+ plt .close ("all" )
772
775
fig , ax = plt .subplots ()
773
776
scatter_kws = dict (
774
777
color = "b" , linestyle = "--" , markeredgecolor = "g" , markerfacecolor = "none"
@@ -791,6 +794,7 @@ def test_probplot_pp(plot_data):
791
794
remove_text = True ,
792
795
)
793
796
def test_probplot_prob_bestfit (plot_data ):
797
+ plt .close ("all" )
794
798
fig , ax = plt .subplots ()
795
799
fig = viz .probplot (
796
800
plot_data ,
@@ -806,6 +810,7 @@ def test_probplot_prob_bestfit(plot_data):
806
810
807
811
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
808
812
def test_probplot_prob_bestfit_exceedance (plot_data ):
813
+ plt .close ("all" )
809
814
fig , ax = plt .subplots ()
810
815
fig = viz .probplot (
811
816
plot_data ,
@@ -822,6 +827,7 @@ def test_probplot_prob_bestfit_exceedance(plot_data):
822
827
823
828
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
824
829
def test_probplot_qq_bestfit (plot_data ):
830
+ plt .close ("all" )
825
831
fig , ax = plt .subplots ()
826
832
fig = viz .probplot (
827
833
plot_data ,
@@ -837,6 +843,7 @@ def test_probplot_qq_bestfit(plot_data):
837
843
838
844
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
839
845
def test_probplot_pp_bestfit (plot_data ):
846
+ plt .close ("all" )
840
847
fig , ax = plt .subplots ()
841
848
scatter_kws = {"marker" : "s" , "color" : "red" }
842
849
line_kws = {"linestyle" : "--" , "linewidth" : 3 }
@@ -857,6 +864,7 @@ def test_probplot_pp_bestfit(plot_data):
857
864
858
865
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
859
866
def test_probplot_prob_probax_y (plot_data ):
867
+ plt .close ("all" )
860
868
fig , ax = plt .subplots ()
861
869
fig = viz .probplot (
862
870
plot_data , ax = ax , datalabel = "Test xlabel" , datascale = "log" , probax = "y"
@@ -867,6 +875,7 @@ def test_probplot_prob_probax_y(plot_data):
867
875
868
876
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
869
877
def test_probplot_qq_probax_y (plot_data ):
878
+ plt .close ("all" )
870
879
fig , ax = plt .subplots ()
871
880
fig = viz .probplot (
872
881
plot_data ,
@@ -882,6 +891,7 @@ def test_probplot_qq_probax_y(plot_data):
882
891
883
892
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
884
893
def test_probplot_pp_probax_y (plot_data ):
894
+ plt .close ("all" )
885
895
fig , ax = plt .subplots ()
886
896
scatter_kws = dict (
887
897
color = "b" , linestyle = "--" , markeredgecolor = "g" , markerfacecolor = "none"
@@ -901,6 +911,7 @@ def test_probplot_pp_probax_y(plot_data):
901
911
902
912
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
903
913
def test_probplot_prob_bestfit_probax_y (plot_data ):
914
+ plt .close ("all" )
904
915
fig , ax = plt .subplots ()
905
916
fig = viz .probplot (
906
917
plot_data ,
@@ -917,6 +928,7 @@ def test_probplot_prob_bestfit_probax_y(plot_data):
917
928
918
929
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
919
930
def test_probplot_qq_bestfit_probax_y (plot_data ):
931
+ plt .close ("all" )
920
932
fig , ax = plt .subplots ()
921
933
fig = viz .probplot (
922
934
plot_data ,
@@ -933,6 +945,7 @@ def test_probplot_qq_bestfit_probax_y(plot_data):
933
945
934
946
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
935
947
def test_probplot_pp_bestfit_probax_y (plot_data ):
948
+ plt .close ("all" )
936
949
fig , ax = plt .subplots ()
937
950
scatter_kws = {"marker" : "s" , "color" : "red" }
938
951
line_kws = {"linestyle" : "--" , "linewidth" : 3 }
@@ -955,6 +968,7 @@ def test_probplot_pp_bestfit_probax_y(plot_data):
955
968
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = LOOSE_TOLERANCE )
956
969
@pytest .mark .skipif (stats is None , reason = "no scipy" )
957
970
def test_probplot_beta_dist_best_fit_y (plot_data ):
971
+ plt .close ("all" )
958
972
fig , (ax1 , ax2 ) = plt .subplots (ncols = 2 )
959
973
dist = stats .beta (3 , 3 )
960
974
fig = viz .probplot (
@@ -990,6 +1004,7 @@ def test_probplot_beta_dist_best_fit_y(plot_data):
990
1004
)
991
1005
@pytest .mark .skipif (stats is None , reason = "no scipy" )
992
1006
def test_probplot_beta_dist_best_fit_x (plot_data ):
1007
+ plt .close ("all" )
993
1008
fig , (ax1 , ax2 ) = plt .subplots (nrows = 2 )
994
1009
dist = stats .beta (3 , 3 )
995
1010
fig = viz .probplot (
@@ -1019,6 +1034,7 @@ def test_probplot_beta_dist_best_fit_x(plot_data):
1019
1034
1020
1035
1021
1036
def test_probplot_test_results (plot_data ):
1037
+ plt .close ("all" )
1022
1038
fig , ax = plt .subplots ()
1023
1039
fig , results = viz .probplot (plot_data , return_best_fit_results = True )
1024
1040
@@ -1046,6 +1062,7 @@ def test__set_prob_limits_x(probax, N, minval, maxval):
1046
1062
1047
1063
@pytest .mark .mpl_image_compare (baseline_dir = BASELINE_DIR , tolerance = TIGHT_TOLERANCE )
1048
1064
def test_probplot_color_and_label (plot_data ):
1065
+ plt .close ("all" )
1049
1066
fig , ax = plt .subplots ()
1050
1067
fig = viz .probplot (plot_data , ax = ax , color = "pink" , label = "A Top-Level Label" )
1051
1068
ax .legend (loc = "lower right" )
0 commit comments