text_html_output_1.png
import pandas as pd

df = pd.read_csv('../input/sms-spam-collection-dataset/spam.csv', encoding='latin-1')

df.shape

df.drop(columns=['Unnamed: 2', 'Unnamed: 3', 'Unnamed: 4'], inplace=True)

df.rename(columns={'v1': 'target', 'v2': 'text'}, inplace=True)

df.isnull().sum()

df.duplicated().sum()

df = df.drop_duplicates(keep='first')

df.duplicated().sum()

df.shape

df[df['target'] == 1][['num_char', 'NUm_words', 'Num_sentence']].describe()