Menu

Checking Data Quality

Checking Data Quality

Before building the recommendation system, we need to ensure that the dataset is clean and complete. Missing values or duplicate records can affect the quality of the recommendations.

Code

news.isnull().sum()

news.duplicated().sum()

Explanation

The first statement checks for missing values in each column.

The second statement counts the number of duplicate records in the dataset.

Output

The number of missing values and duplicate records is displayed.