Updates to formatting, bug fixes