Giter Club home page Giter Club logo

Comments (1)

bnavigator avatar bnavigator commented on August 24, 2024

Also leads to test failure:

[  842s] __________________ TestDataFramePlots.test_plot_scatter_shape __________________
[  842s] [gw0] linux -- Python 3.11.9 /usr/bin/python3.11
[  842s] 
[  842s] self = <pandas.tests.plotting.frame.test_frame.TestDataFramePlots object at 0x7f63b3211590>
[  842s] 
[  842s]     def test_plot_scatter_shape(self):
[  842s]         df = DataFrame(
[  842s]             np.random.default_rng(2).standard_normal((6, 4)),
[  842s]             index=list(string.ascii_letters[:6]),
[  842s]             columns=["x", "y", "z", "four"],
[  842s]         )
[  842s]         # GH 6951
[  842s] >       axes = df.plot(x="x", y="y", kind="scatter", subplots=True)
[  842s] 
[  842s] pandas/tests/plotting/frame/test_frame.py:828: 
[  842s] _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
[  842s] pandas/plotting/_core.py:975: in __call__
[  842s]     return plot_backend.plot(data, x=x, y=y, kind=kind, **kwargs)
[  842s] pandas/plotting/_matplotlib/__init__.py:71: in plot
[  842s]     plot_obj.generate()
[  842s] pandas/plotting/_matplotlib/core.py:503: in generate
[  842s]     self._make_legend()
[  842s] pandas/plotting/_matplotlib/core.py:896: in _make_legend
[  842s]     ax.legend(loc="best")
[  842s] /usr/lib64/python3.11/site-packages/matplotlib/axes/_axes.py:341: in legend
[  842s]     handles, labels, kwargs = mlegend._parse_legend_args([self], *args, **kwargs)
[  842s] /usr/lib64/python3.11/site-packages/matplotlib/legend.py:1364: in _parse_legend_args
[  842s]     _api.warn_external(
[  842s] _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
[  842s] 
[  842s] message = 'No artists with labels found to put in legend.  Note that artists whose label start with an underscore are ignored when legend() is called with no argument.'
[  842s] category = None
[  842s] 
[  842s]     def warn_external(message, category=None):
[  842s]         """
[  842s]         `warnings.warn` wrapper that sets *stacklevel* to "outside Matplotlib".
[  842s]     
[  842s]         The original emitter of the warning can be obtained by patching this
[  842s]         function back to `warnings.warn`, i.e. ``_api.warn_external =
[  842s]         warnings.warn`` (or ``functools.partial(warnings.warn, stacklevel=2)``,
[  842s]         etc.).
[  842s]         """
[  842s]         frame = sys._getframe()
[  842s]         for stacklevel in itertools.count(1):
[  842s]             if frame is None:
[  842s]                 # when called in embedded context may hit frame is None
[  842s]                 break
[  842s]             if not re.match(r"\A(matplotlib|mpl_toolkits)(\Z|\.(?!tests\.))",
[  842s]                             # Work around sphinx-gallery not setting __name__.
[  842s]                             frame.f_globals.get("__name__", "")):
[  842s]                 break
[  842s]             frame = frame.f_back
[  842s]         # preemptively break reference cycle between locals and the frame
[  842s]         del frame
[  842s] >       warnings.warn(message, category, stacklevel)
[  842s] E       UserWarning: No artists with labels found to put in legend.  Note that artists whose label start with an underscore are ignored when legend() is called with no argument.
[  842s] 

from pandas.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.