AFAIK, scraping is legal under US law because one does not have to circumvent any encryption to access the webpage. If LinkedIn will serve it to Google, Bing and others, then they'd be hard pressed to say "our HTML is secret."
Selling it is a different matter, and one that I don't have enough law background to answer. It may fall under the provision in US copyright law that says that facts are not copyrightable. So long as you are just selling the facts of the graph that they gladly serve to the Internet, ... again, I am not experienced enough to comment.