Added automatic i, and fixed missing argument.