Created prototype to update the label of a graph.