starting to untangle data functions