added logic to generate multiBar data