updated data gathering script