AttributeError: 'numpy.ndarray' object has no attribute 'new_box'
时间: 2023-10-03 20:03:31 浏览: 162
AttributeError: 'numpy.ndarray' object has no attribute 'new_box'是由于在使用sns.boxplot()函数时,numpy数组对象(ndarray)没有new_box属性导致的错误。 根据提供的代码段,可以看到sns.boxplot()函数被调用了四次,每次都使用了不同的y轴变量和axes对象。然而,numpy数组对象没有名为new_box的属性,所以导致了属性错误的异常。要解决这个问题,需要检查代码中是否有使用类似于new_box的属性或方法。如果是一个拼写错误,可以将其更正。如果是一个自定义的属性或方法,需要确保在使用之前正确地定义它。请检查代码以找到并修复这个错误。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [# Pycharm关于AttributeError: ‘DataFrame’ object has no attribute ‘score’的错误](https://download.csdn.net/download/weixin_38720756/13749766)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [利用sns.boxplot绘制箱型图的时候报错:AttributeError: ‘numpy.ndarray‘ object has no attribute ...](https://blog.csdn.net/basktball_poet/article/details/128167699)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文