What happened to sklearn.datasets.load_boston?

Viewed 266

While I was coding a Boston housing model using sklearn.datasets.load_boston, it gave me an error saying that the database was deprecated due to 'ethical' issues. What are those issues? I looked online, and could not find anything.

Here's the full error:

DEPRECATED: load_boston is deprecated in 1.0 and will be removed in 1.2.

The Boston housing prices dataset has an ethical problem. You can refer to the documentation of this function for further details.

The scikit-learn maintainers therefore strongly discourage the use of this dataset unless the purpose of the code is to study and educate about ethical issues in data science and machine learning.

In this special case, you can fetch the dataset from the original source:
1 Answers

Actually, it is just exactly as it is in the error. You can check https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_boston.html for further details.

As I understand, there are 2 problems in the data:

  1. Racism: There is a great article, which was also cited in the Scikit-Learn documentation by M. Carlisle. It focuses on the main issues of the Boston Housing dataset, which he found that house prices effected by neighbourhood race.
  2. No suitable goal: "the goal of the research that led to the creation of this dataset was to study the impact of air quality but it did not give adequate demonstration of the validity of this assumption."

However, you can get the data from the source: http://lib.stat.cmu.edu/datasets/boston

I hope these help.

Related