y1(d => nyScale(d[1]));
            
            // set the animation interval; 
            render(prestack, keys, area);
            render(prestack_hubei, keys_hubei, area_hubei); 
            console.log(alldates);
            let c = 0; 
            let width_step = innerWidth / (alldates.length-1);
            let intervalId = setInterval(function(){
                if(c >= alldates.length){
                    console.log('time to close this animation');
                    clearInterval(intervalId);