Refactor away from dataset functions to mapping objects