Updated documentation to include offset parameter.