Esempio n. 1
0
        public void MoveEETEfficacy(BE_State nextStateIn, BE_Cycle cycleIn)
        {
            status       = BE_PatientStatus.Recurrence;
            completedEET = true;
            activeRecurrenceProbability = true;

            postEETState   = nextStateIn;
            confirmedState = nextStateIn;   //  Assumption popst EET state is always confirmed.

            currentState.Population--;
            currentState = nextStateIn;
            currentState.Population++;

            needPostEETDecision = true;
            if (postEETState.ID >= realPreEETState.ID)  //  Treatment failure. If in reality NoBarretts, it must be switched to naturel progression.
            {
                status = BE_PatientStatus.NaturalHistory;
                activeRecurrenceProbability = false;
                activeNaturalProgression    = true;
            }
            if (postEETState.ID >= preEETState.ID)  //  Treatment failure is observed
            {
                concludedAsFailedEET = true;
            }
        }
Esempio n. 2
0
 public void Die(string deathCauseIn)
 {
     status = BE_PatientStatus.Dead;
     activeNaturalProgression    = false;
     activeRecurrenceProbability = false;
     isDead     = true;
     deathAge   = age;
     deathCause = deathCauseIn;
     currentState.Population--;
     currentState.DiedPopulation++;
 }
Esempio n. 3
0
        public void MoveRecurrence(BE_EET EETIn, BE_State[] states, BE_Cycle cycleIn, Random rand)
        {
            if (rand.NextDouble() <= EETIn.recurrence[preEETState.ID])
            {
                status = BE_PatientStatus.NaturalHistory;
                activeRecurrenceProbability = false;
                activeNaturalProgression    = true;

                int newIndex = EETIn.FindRecurrenceState(preEETState.ID, rand);

                currentState.Population--;
                currentState = states[newIndex];
                stateHistory.Add(cycleIn.ID, currentState.Type);
                currentState.Population++;
            }
            else
            {
                stateHistory.Add(cycleIn.ID, currentState.Type);
            }
        }