def data_id(full_formula, data) # :nodoc:
      return unless full_formula

      # Strip the leading '=' from the formula.
      formula = full_formula.sub(/^=/, '')

      # Store the data id in a hash keyed by the formula and store the data
      # in a separate array with the same id.
      if @formula_ids.has_key?(formula)
        # Formula already seen. Return existing id.
        id = @formula_ids[formula]
        # Store user defined data if it isn't already there.
        @formula_data[id] ||= data
      else
        # Haven't seen this formula before.
        id = @formula_ids[formula] = @formula_data.size
        @formula_data << data
      end

      id
    end
def data_id(full_formula, data) # :nodoc:
      return unless full_formula

      # Strip the leading '=' from the formula.
      formula = full_formula.sub(/^=/, '')

      # Store the data id in a hash keyed by the formula and store the data
      # in a separate array with the same id.
      if @formula_ids.has_key?(formula)
        # Formula already seen. Return existing id.
        id = @formula_ids[formula]
        # Store user defined data if it isn't already there.
        @formula_data[id] ||= data
      else
        # Haven't seen this formula before.
        id = @formula_ids[formula] = @formula_data.size
        @formula_data << data
      end

      id
    end
Assign an id to a each unique series formula or title/axis formula. Repeated
 formulas such as for categories get the same id. If the series or title
 has user specified data associated with it then that is also stored. This
 data is used to populate cached Excel data when creating a chart.
 If there is no user defined data then it will be populated by the parent
 workbook in Workbook::_add_chart_data