Optimize dummy data insertion in graphs