Creates a graph of friendships and interacts with the data.