adding bar chart when a triangle is clicked