text_plain_output_1.png
import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)

youtube_df = pd.read_csv('/kaggle/input/youtube-new/USvideos.csv')

youtube_df.columns

youtube_df.shape[0]

youtube = youtube_df[['video_id', 'title', 'channel_title', 'category_id', 'views', 'likes', 'dislikes']]

avg_views = round(youtube['views'].mean())
avg_views

condition = youtube[youtube.views >= avg_views].shape[0]
round(condition / youtube.shape[0] * 100)

ax1 = youtube.plot(kind='scatter', x='views', y='likes', color='g')
ax2 = youtube.plot(kind='scatter', x='views', y='dislikes', color='r', ax=ax1)
ax2.set_ylabel('viewer interactions (likes/dislikes)')