added comments, fixes, and additional code to beta sheet generator