AddCountedWordPairToValueLists
(
CountedWordPair oCountedWordPair,
WordMetricUserSettings oWordMetricUserSettings,
List<GraphMetricValueOrdered> oWordPairWord1Values,
List<GraphMetricValueOrdered> oWordPairWord2Values,
List<GraphMetricValueOrdered> oWordPairCountValues,
List<GraphMetricValueOrdered> oWordPairSalienceValues,
List<GraphMetricValueOrdered> oWordPairMutualInformationValues
)
{
Debug.Assert(oCountedWordPair != null);
Debug.Assert(oWordMetricUserSettings != null);
Debug.Assert(oWordPairWord1Values != null);
Debug.Assert(oWordPairWord2Values != null);
Debug.Assert(oWordPairCountValues != null);
Debug.Assert(oWordPairSalienceValues != null);
Debug.Assert(oWordPairMutualInformationValues != null);
AssertValid();
if (
oCountedWordPair.Count == 1
&&
oWordMetricUserSettings.SkipSingleTerms
)
{
return (false);
}
oWordPairWord1Values.Add( new GraphMetricValueOrdered(
ExcelUtil.ForceCellText(oCountedWordPair.Word1) ) );
oWordPairWord2Values.Add( new GraphMetricValueOrdered(
ExcelUtil.ForceCellText(oCountedWordPair.Word2) ) );
oWordPairCountValues.Add(
new GraphMetricValueOrdered(oCountedWordPair.Count) );
oWordPairSalienceValues.Add(
new GraphMetricValueOrdered(oCountedWordPair.Salience) );
oWordPairMutualInformationValues.Add(
new GraphMetricValueOrdered(oCountedWordPair.MutualInformation) );
return (true);
}