Ejemplo n.º 1
0
        private static void EmotionCategoryFrequencyRating(double dFrequency, EmotionClassify emotion)
        {
            double dNeverVisited     = 0.05; //从未访问过
            double dFewerVisited     = 0.10; //很少访问
            double dSometimesVisited = 0.20; //有时候访问
            double dAlwaysVisited    = 0.30; //经常访问

            if (dFrequency <= dNeverVisited)
            {
                BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_A);
            }
            else if ((dFrequency > dNeverVisited) && (dFrequency <= dFewerVisited))
            {
                BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_B);
            }
            else if ((dFrequency > dFewerVisited) && (dFrequency <= dSometimesVisited))
            {
                BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_C);
            }
            else if ((dFrequency > dSometimesVisited) && (dFrequency <= dAlwaysVisited))
            {
                BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_D);
            }
            else if (dFrequency > dAlwaysVisited)
            {
                BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_E);
            }
        }
Ejemplo n.º 2
0
 private static void EmotionCategoryFrequencyRating(double dFrequency, EmotionClassify emotion)
 {
     double dNeverVisited = 0.05;//从未访问过
     double dFewerVisited = 0.10;//很少访问
     double dSometimesVisited = 0.20;//有时候访问
     double dAlwaysVisited = 0.30;//经常访问
     if (dFrequency <= dNeverVisited)
     {
         BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_A);
     }
     else if ((dFrequency > dNeverVisited) && (dFrequency <= dFewerVisited))
     {
         BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_B);
     }
     else if ((dFrequency > dFewerVisited) && (dFrequency <= dSometimesVisited))
     {
         BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_C);
     }
     else if ((dFrequency > dSometimesVisited) && (dFrequency <= dAlwaysVisited))
     {
         BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_D);
     }
     else if (dFrequency > dAlwaysVisited)
     {
         BehaviorFeatureAnalysis.UpdateBehaviorFeature_PAN_EmotionClassify(emotion, RadioSelectionCategory.RadioSelected_E);
     }
 }
 /// <summary>
 /// 网页的情感分类
 /// </summary>
 /// <param name="emotion"></param>
 /// <param name="iSelected"></param>
 public static void UpdateBehaviorFeature_PAN_EmotionClassify(EmotionClassify emotion,RadioSelectionCategory iSelected)
 {
     switch(emotion)
     {
         case EmotionClassify.AngerClassify:
             PAN_Anger = (int)iSelected;
             break;
         case EmotionClassify.BoredClassify:
             break;
         case EmotionClassify.HappyClassify:
             PAN_Happy = (int)iSelected;
             break;
         case EmotionClassify.PeculiarClassify:
             PAN_Peculiar = (int)iSelected;
             break;
         case EmotionClassify.SadnessClassify:
             PAN_Sadness = (int)iSelected;
             break;
     }
 }