def rangeize(x, y)
      [x, y].collect { |i| i.respond_to?(:to_i) ? (i.to_i..i.to_i) : i }
    end
def rangeize(x, y)
      [x, y].collect { |i| i.respond_to?(:to_i) ? (i.to_i..i.to_i) : i }
    end
Converts given coordinates to ranges if necessary.