Process data and command line arguments