A hack to sort 1D data into coordinate order
Merged master into chris/fix-issue-59
Minor formatting fixes.