In computing any time period in this chapter, the court shall exclude the following periods: (1) Any time in which the defendant is unable to participate in a preliminary screening examination, a full competence examination, or treatment to restore competence due to physical incapacity; (2) Any time in which the defendant fails or refuses to participate in a preliminary screening examination, a full competence examination, or treatment to restore competence; (3) Any time due to the defendant’s failure to appear for a preliminary screening examination, a full competence examination, or treatment to restore competence; and (4) Any time from the filing of a motion or petition through its disposition, including any appeals, which prevents or delays the conduct of a preliminary screening examination, a full competence examination, or treatment to restore competence, including involuntary medication.