private int SortAndRemoveDuplicates(List <ComparableEvent> eventsToCompare, bool sort)
        {
            int uniqueEvents = 1;

            if (sort)
            {
                eventsToCompare.Sort();
                if (NumberOfEvents <= 1)
                {
                    return(uniqueEvents);
                }
                ComparableEvent ce1 = eventsToCompare[0];
                for (int i = 1; i < eventsToCompare.Count; i++)
                {
                    ComparableEvent ce2 = eventsToCompare[i];
                    if (ce1.CompareTo(ce2) == 0)
                    {
                        ce1.Seen++;
                        eventsToCompare[i] = null;
                    }
                    else
                    {
                        ce1 = ce2;
                        uniqueEvents++;
                    }
                }
            }
            else
            {
                uniqueEvents = eventsToCompare.Count;
            }
            return(uniqueEvents);
        }
        private void FillArrays(List <ComparableEvent> eventsToCompare)
        {
            int j = 0;

            for (int i = 0; i < NumberOfEvents; i++)
            {
                ComparableEvent ce = eventsToCompare[i];
                if (ce != null)
                {
                    NumberOfTimesEventsSeen[j] = ce.Seen;
                    OutcomeList[j]             = ce.Outcome;
                    Contexts[j] = ce.PredicateIndices;
                    j++;
                }
            }
        }