Restructured prototype_map function used to remap values for charts