updated formatting of positioning info and fixed output file such that positioning info is appended to the end of the file