Added new data input
Write data to file