added code to remove svg when new histogram is rendered