First time loading the visual :  getting expected output but after switching to and from data the visual is displayed as:  which is not correct again after switching back to the initial data the whole visual is breaking 
First time loading the visual :

getting expected output
but after switching to and from data the visual is displayed as:

which is not correct
again after switching back to the initial data the whole visual is breaking
