Updated for input data