Area with `y2` triggers ununderstandable ndarray VisibleDeprecationWarning
See original GitHub issueALL software version info
# Name Version Build Channel
hvplot 0.7.0 pyhd3deb0d_0 conda-forge
# packages in environment at /home/maye/miniconda3/envs/py38:
#
# Name Version Build Channel
bokeh 2.2.3 py38h578d9bd_0 conda-forge
# packages in environment at /home/maye/miniconda3/envs/py38:
#
# Name Version Build Channel
ipython 7.19.0 py38h81c977d_2 conda-forge
ipython_genutils 0.2.0 py_1 conda-forge
jupyter-lsp-python 1.1.1 pyhd8ed1ab_0 conda-forge
msgpack-python 1.0.2 py38h1fd1430_1 conda-forge
python 3.8.6 hffdb5ce_4_cpython conda-forge
python-dateutil 2.8.1 py_0 conda-forge
python-jsonrpc-server 0.4.0 pyh9f0ad1d_0 conda-forge
python-language-server 0.36.2 pyhd8ed1ab_0 conda-forge
python_abi 3.8 1_cp38 conda-forge
# packages in environment at /home/maye/miniconda3/envs/py38:
#
# Name Version Build Channel
notebook 6.2.0 py38h578d9bd_0 conda-forge
# packages in environment at /home/maye/miniconda3/envs/py38:
#
# Name Version Build Channel
jupyter 1.0.0 py38h578d9bd_6 conda-forge
jupyter-lsp 1.1.1 pyhd8ed1ab_0 conda-forge
jupyter-lsp-python 1.1.1 pyhd8ed1ab_0 conda-forge
jupyter_client 6.1.11 pyhd8ed1ab_1 conda-forge
jupyter_console 6.2.0 py_0 conda-forge
jupyter_core 4.7.0 py38h578d9bd_1 conda-forge
jupyter_server 1.2.2 py38h578d9bd_1 conda-forge
jupyterlab 3.0.6 pyhd8ed1ab_0 conda-forge
jupyterlab-lsp 3.2.0 pyhd8ed1ab_0 conda-forge
jupyterlab_code_formatter 1.4.2 pyhd8ed1ab_0 conda-forge
jupyterlab_pygments 0.1.2 pyh9f0ad1d_0 conda-forge
jupyterlab_server 2.1.3 pyhd8ed1ab_0 conda-forge
jupyterlab_widgets 1.0.0 pyhd8ed1ab_1 conda-forge
Description of expected behavior and the observed behavior
Because I am doing a lot of these plots I get a ton of these warnings. A first work-around would be a way to suppress them. I expect no error because all my arrays are of the same length, no column or arrays are staggered with tuples or something like that (like [arr1, (arr2, 1)]…
Use of the y2
option triggers an ndarray VisibleDeprecationWarning about ragged sequences but there are none on the user’s side, so I presume the issue with an hvplot helper routine in core/util.py
.
Complete, minimal, self-contained example code that reproduces the issue
testdf = pd.DataFrame(np.random.rand(100), columns=["a"])
testdf['b'] = testdf['a']+2
testdf.hvplot.area(x='index', y='a', y2='b')
Stack traceback and/or browser JavaScript console output
/home/maye/miniconda3/envs/py38/lib/python3.8/site-packages/holoviews/core/util.py:980: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify ‘dtype=object’ when creating the ndarray arr = np.array(values)
Screenshots or screencasts of the bug in action
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (5 by maintainers)
Top GitHub Comments
v1.14.1 is old, we are tagging v1.14.2 in the next 5 mins.
Sorry, should have looked at the ChangeLog.