Update return values of the idx indexes, fixed plotting code so it doesnt look like butt
Merge remote-tracking branch 'origin/master'