This code counts the words in a column.
df['businesstype'].value_counts() #value count
My question how can I plot now the 10 or 5 highest counted word in the businesstype
column ?
df.head(10)['businesstype'].value_counts().plot.bar()
That works but it counts by the axis my csv data is sorted, not by the value count.
The question is probably easy but I am learning and I haven't found anything on SO that answers my question.
The dataframe looks like this:
Index(['Rang 2014', 'Unnamed: 1', 'Rang 2013','unternehmen' , 'Sitz',
'Umsatz (Mrd. €)', 'Gewinn/Verlust (Mio. €)', 'Mitarbeiter weltweit',
'businestype'],
dtype='object')
I also checked the pd option max rows
nothing changed just plotted top and bottom half if I set max rows.