def climatology_check(temperature, interpMNTemp, interpSDTemp, sigmaFactor=5.0):
  """
  temperature: Float for temperature
  interpMNTemp: interpolated temperature from climatology file
  interpSDTemp: interpolated standard deviation from climatology file
  sigmaFactor: tolerated deviation from climatological temperature, in standard deviations.
  """

  if interpMNTemp == 99999.99 or interpSDTemp == 99999.99 or interpSDTemp <= 0.0:
    return 0

  if abs(temperature-interpMNTemp)/interpSDTemp <= sigmaFactor:
    return 1
  else:
    return 4