image_output_1.png
import matplotlib.pyplot as plt

import numpy as np

import pandas as pd

train_df = pd.read_csv('/kaggle/input/commonlitreadabilityprize/train.csv')
train_df.drop(train_df[(train_df.target == 0) & (train_df.standard_error == 0)].index, inplace=True)
train_df.reset_index(drop=True, inplace=True)
test_df = pd.read_csv('/kaggle/input/commonlitreadabilityprize/test.csv')
submission_df = pd.read_csv('/kaggle/input/commonlitreadabilityprize/sample_submission.csv')

print('target Variable')
print('----------')
target_mean = train_df['target'].mean()
print(f'Mean: {target_mean}')
target_median = train_df['target'].median()
print(f'Median: {target_median}')
target_std = train_df['target'].std()
print(f'Standard Deviation: {target_std}')
target_min = train_df['target'].min()
print(f'Minimum Value: {target_min}')
target_25 = np.percentile(train_df['target'], 25)
print(f'25th Percentile: {target_25}')
target_50 = np.percentile(train_df['target'], 50)
print(f'50th Percentile: {target_50}')
target_75 = np.percentile(train_df['target'], 75)
print(f'75th Percentile: {target_75}')
target_max = train_df['target'].max()
print(f'Maximum Value: {target_max}')
target_skew = train_df['target'].skew(axis=0, skipna=True)
print(f'Skew: {target_skew}')
plt.hist(train_df['target'], edgecolor='black', bins=50)