Code for displaying papers in a graph