code: def quantity_spec_string(name, quantity_dict):
      '''
  Returns a quantity specification for docstrings.
  
  Example
  -------
  
  >>> quantity_spec_string('Tv')
  >>> 'Tv : float or ndarray\n    Data for virtual temperature.'
      '''
      if name not in quantity_dict.keys():
          raise ValueError('{0} not present in quantity_dict'.format(name))
      s = '{0} : float or ndarray\n'.format(name)
      s += doc_paragraph('Data for {0}.'.format(
          quantity_string(name, quantity_dict)), indent=4)
      return f quantity_spec_string(name, quantity_dict):
      '''
  Returns a quantity specification for docstrings.
  
  Example
  -------
  
  >>> quantity_spec_string('Tv')
  >>> 'Tv : float or ndarray\n    Data for virtual temperature.'
      '''
      if name not in quantity_dict.keys():
          raise ValueError('{0} not present in quantity_dict'.format(name))
      s = '{0} : float or ndarray\n'.format(name)
      s += doc_paragraph('Data for {0}.'.format(
          quantity_string(name, quantity_dict)), indent=4)
      return s
docs: Returns a quantity specification for docstrings.
  
  Example
  -------
  
  >>> quantity_spec_string('Tv')
  >>> 'Tv : float or ndarray\n    Data for virtual temperature.'