1

Hi all I am trying to avoid this future warning in python, stranged because it is refering to scipy and i haven't imported scipy library.

%matplotlib inline
import json
from pandas.io.json import json_normalize
import numpy as np
import seaborn as sns
import pandas as pd
import matplotlib.pyplot as plt
from matplotlib.patches import Arc, Rectangle, ConnectionPatch
from matplotlib.offsetbox import  OffsetImage
import squarify
from functools import reduce






fig, ax = plt.subplots()
fig.set_size_inches(8, 6)

ax.set_xlim([0,120])
ax.set_ylim([0,80])

x_coord = [i[0] for i in ozil_action["location"]]
y_coord = [i[1] for i in ozil_action["location"]]

#shades: give us the heat map we desire
# n_levels: draw more lines, the larger n, the more bluerry it loos
sns.kdeplot(x_coord, y_coord, shade = "True", color = "green", n_levels = 30)
plt.show()

Future Warning

C:\ProgramData\Anaconda3\lib\site-packages\scipy\stats\stats.py:1713: 
FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; 
use `arr[tuple(seq)]` instead of `arr[seq]`. 
In the future this will be interpreted as an array index, `arr[np.array(seq)]`, 
which will result either in an error or a different result.

  return np.add.reduce(sorted[indexer] * weights, axis=axis) / sumval

Versions of the packages used for my anaconda environment numpy, seaborn,matplotlib

import numpy as np
np.__version__
'1.16.4'


scipy.__version__
'1.1.0'


matplotlib.__version__
'3.0.2'

seaborn.__version__
'0.9.0'

Thanks in advance.

0 Answers0