# File lib/mcollective/application/ping.rb, line 15
    def spark(resp_times)
      return "" unless configuration[:graph] || Config.instance.pluginconf["rpc.graph"]

      ticks=%w[▁ ▂ ▃ ▄ ▅ ▆ ▇]

      histo = {}

      # round each time to its nearest 50ms
      # and keep a count for each 50ms
      resp_times.each do |time|
        time = Integer(time + 50 - (time % 50))
        histo[time] ||= 0
        histo[time] += 1
      end

      # set the 50ms intervals that saw no traffic to 0
      ((histo.keys.max - histo.keys.min) / 50).times do |i|
        time = (i * 50) + histo.keys.min
        histo[time] = 0 unless histo[time]
      end

      # get a numerically sorted list of times
      histo = histo.keys.sort.map{|k| histo[k]}

      range = histo.max - histo.min
      scale = ticks.size - 1
      distance = histo.max.to_f / scale

      histo.map do |val|
        tick = (val / distance).round
        tick = 0 if tick < 0

        ticks[tick]
      end.join
    end