Added code exerpt to piechart and barchart.