Applying a function to data via starmap() and map()