Richard Marotta left the Boston company less than two weeks after a goodwill impairment charge contributed to a large quarterly loss.