Function partitionErrors

Partition array of values and errors into an array of values and an array of errors.