text_plain_output_1.png
import matplotlib.pyplot as plt

import pandas as pd

import seaborn as sns

import numpy as np
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
sns.set_style('darkgrid')

ds = pd.read_csv('/kaggle/input/spotify-datacsv/spotify_data.csv', dtype={'19': float})
ds

ds.isna().sum()

ds.shape

ds.columns

len(ds.columns)

top_ten_genre = ds.groupby('artists').count().sort_values(by='name', ascending=False)['name'][:10]
top_ten_genre

top_ten_genre.plot.barh()

top_loudest_tracks = ds[['loudness', 'artists']].sort_values(by='loudness', ascending=False)[:5]
top_loudest_tracks

top_loudest_tracks.plot.barh()

plt.figure(figsize=(12, 7))
sns.barplot(x='loudness', y='artists', data=top_loudest_tracks)
plt.title('Top 5 loudest Tracks')
plt.show()