added bar chart and accoring initializer