code: function smog(counts) {
    if (!counts || !counts.sentence) {
      return NaN
    }
  
    return (
      base +
      weight *
        Math.sqrt(
          (counts.polysillabicWord || 0) * (sentenceSize / counts.sentence)
        )
    )
  }
docs: Get the grade level of a given value according to the SMOG formula. More information is available at WikiPedia: <http://en.wikipedia.org/wiki/SMOG>