. Advertisement .
..3..
. Advertisement .
..4..
I am trying to write a python that returns an invalid answer. I don’t know where the incorrect command is in the “module ‘seaborn’ has no attribute ‘histplot’.” My detail is:
sns.histplot(train, x = "Age", hue="Sex")
and I end up with the warning message:
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-11-d14c3b5a0670> in <module>
----> 1 sns.histplot(train, x = "Age", hue="Sex")
AttributeError: module 'seaborn' has no attribute 'histplot'
Pls, suggest the best answer to fix it.
The cause: I think the cause of this error is that you haven’t updated your seaborn module.
The solution: Please update your seaborn module with:
To extend Ahsan Goheer’s answer. You can update seaborn with:
Next, restart the Notebook’s Kernel. It should now work