changing graph with each clock tick