IPython notebook test for weighted/directed