took remkos changes to get inline citations

moved labels into figures

fixed inline cites

cleaned errors