public static void scoreString(StringAndScores strAndScores) {
		int[] asciiCodes = strAndScores.getAsciiCodes();

		double ngScore;

		if (asciiCodes.length < 3) {
			ngScore = defaultLogValue;
		}
		else {
			ngScore = calculateTrigrams(asciiCodes);
		}

		strAndScores.setNgramScore(ngScore);

		int strLen = strAndScores.getScoredStringLength();

		double thresholdToUse =
			strLen >= NG_THRESHOLDS.length ? MAX_NG_THRESHOLD : NG_THRESHOLDS[strLen];

		strAndScores.setScoreThreshold(thresholdToUse);
	}
Calculates and stores scores for the [string in the] given StringAndScores object.
 
@param strAndScores  Object that stores input string and associated scores
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/string/NGramUtils.java