improved functionality

moved all optional arguments to an arguments array to simplify api