added functionality

getData is the function tim is writing