fix bug in generating and interpreting directed linking relations, add
arrows to D3 rendering