def generate(params = {})
      params = {
        :type => random_gender,
        :frequency => :common,
        :with_surname => true
      }.merge(params)

      
      if ! ( params[:min_freq] || params[:max_freq] )
        params[:min_freq], params[:max_freq] = frequency_values(params[:frequency])
      else

        #
        # do some basic data validation in case someone is being a knucklehead
        #
        params[:min_freq] = params[:min_freq].to_i
        params[:max_freq] = params[:max_freq].to_i

        params[:max_freq] = params[:min_freq] + 1 if params[:max_freq] <= params[:min_freq]

        # max_freq needs to be at least 4 to get any results back,
        # because the most common male name only rates 3.3
        # JAMES          3.318  3.318      1
        params[:max_freq] = 4 if params[:max_freq] < 4
      end

      
      name = get_name(params[:type], params[:min_freq], params[:max_freq])

      # add surname if needed
      if params[:type] != :surname && params[:with_surname] == true
        name = "#{name} #{get_name(:surname, params[:min_freq], params[:max_freq])}"
      end
      name
    end
def generate(params = {})
      params = {
        :type => random_gender,
        :frequency => :common,
        :with_surname => true
      }.merge(params)

      
      if ! ( params[:min_freq] || params[:max_freq] )
        params[:min_freq], params[:max_freq] = frequency_values(params[:frequency])
      else

        #
        # do some basic data validation in case someone is being a knucklehead
        #
        params[:min_freq] = params[:min_freq].to_i
        params[:max_freq] = params[:max_freq].to_i

        params[:max_freq] = params[:min_freq] + 1 if params[:max_freq] <= params[:min_freq]

        # max_freq needs to be at least 4 to get any results back,
        # because the most common male name only rates 3.3
        # JAMES          3.318  3.318      1
        params[:max_freq] = 4 if params[:max_freq] < 4
      end

      
      name = get_name(params[:type], params[:min_freq], params[:max_freq])

      # add surname if needed
      if params[:type] != :surname && params[:with_surname] == true
        name = "#{name} #{get_name(:surname, params[:min_freq], params[:max_freq])}"
      end
      name
    end
generate a name using the supplied parameter hash

 * +params+ - A hash of parameters

 ==== Params
 * +:type+ - :male, :female, :surname
 * +:frequency+ -  :common, :rare, :all
 * +:min_freq+ - raw frequency values to specify a precise range
 * +:max_freq+ - raw frequency values to specify a precise range