Co-Evolution of Selection and Influence in Social Networks