#10 Barplot with number of observation

This page explains how to display the number of observation per group on a barplot. Just use the text function of matplotlib to add the label one by one in a loop.

If you need to add the number of observation on top of each bar, it means that you have several observation per group. In this case, barplot is probably not the most appropriate method for visualising your data! Indeed, all the information behind each bar is lost.