'Update the parent array, using the (latest) scaled array.
If ``update_heap_pointers`` is `False`, this will leave all the heap
pointers in P/Q columns as they are verbatim--it only makes sense to do
this if there is already data on the heap and it can be guaranteed that
that data has not been modified, and there is not new data to add to
the heap.  Currently this is only used as an optimization for
CompImageHDU that does its own handling of the heap.'

def _scale_back(self, update_heap_pointers=True):

    heapsize = 0
    for (indx, name) in enumerate(self.dtype.names):
        column = self._coldefs[indx]
        recformat = column.format.recformat
        raw_field = _get_recarray_field(self, indx)
        if isinstance(recformat, _FormatP):
            dtype = np.array([], dtype=recformat.dtype).dtype
            if (update_heap_pointers and (name in self._converted)):
                raw_field[:] = 0
                npts = [len(arr) for arr in self._converted[name]]
                raw_field[:len(npts), 0] = npts
                raw_field[1:, 1] = (np.add.accumulate(raw_field[:(-1), 0]) * dtype.itemsize)
                raw_field[:, 1][:] += heapsize
            heapsize += (raw_field[:, 0].sum() * dtype.itemsize)
        if (isinstance(recformat, _FormatX) and (name in self._converted)):
            _wrapx(self._converted[name], raw_field, recformat.repeat)
            continue
        (_str, _bool, _number, _scale, _zero, bscale, bzero, _) = self._get_scale_factors(column)
        field = self._converted.get(name, raw_field)
        if (_number or _str):
            if (_number and (_scale or _zero) and column._physical_values):
                dummy = field.copy()
                if _zero:
                    dummy -= bzero
                if _scale:
                    dummy /= bscale
                column._physical_values = False
            elif (_str or isinstance(self._coldefs, _AsciiColDefs)):
                dummy = field
            else:
                continue
            if isinstance(self._coldefs, _AsciiColDefs):
                self._scale_back_ascii(indx, dummy, raw_field)
            elif isinstance(raw_field, chararray.chararray):
                self._scale_back_strings(indx, dummy, raw_field)
            else:
                if (len(raw_field) and isinstance(raw_field[0], np.integer)):
                    dummy = np.around(dummy)
                if (raw_field.shape == dummy.shape):
                    raw_field[:] = dummy
                else:
                    raw_field[:] = dummy.ravel().view(raw_field.dtype)
            del dummy
        elif (_bool and (name in self._converted)):
            choices = (np.array([ord('F')], dtype=np.int8)[0], np.array([ord('T')], dtype=np.int8)[0])
            raw_field[:] = np.choose(field, choices)
    self._heapsize = heapsize
