fixes missing Imports for reshape2; fixes undocumented 'leg.pos' argument; fixes failing example due to typo