Script to create graph