DJR:Added data logging