Here is the design of a clinical trial:

Official Title: Alpha 2 Agonists for Sedation to Produce Better Outcomes From Critical Illness (A2B Trial): A Randomised, Parallel-group, Allocation Concealed, Controlled, Open, Phase 3 Pragmatic Clinical and Cost- Effectiveness Trial With Internal Pilot

Included conditions:
- Critical Illness

Study Armgroups:
- {'label': 'Dexmedetomidine Group', 'type': 'EXPERIMENTAL', 'description': "For dexmedetomidine, the regimen will follow the manufacturer's guidance and regimens used in previous trials. Dexmedetomidine will be up and down titrated against sedation targets set by clinical staff and reviewed at regular intervals, and documented at least daily. No loading dose will be administered. The starting dose will be 0.7 µg.kg-1.hour-1 titrated to a maximum dose 1.4 µg.kg-1 hour-1. Lower starting doses will be used at clinical discretion for patients with cardiovascular instability.", 'interventionNames': ['Drug: Dexmedetomidine']}
- {'label': 'Clonidine Group', 'type': 'EXPERIMENTAL', 'description': "For clonidine, the regimen is designed to be equipotent with dexmedetomidine based on known pharmacokinetics and pharmacodynamics. The chosen regimen is similar to that currently used in many UK ICUs as part of routine 'off label' practice. Clonidine will be up and down titrated against sedation targets set by clinical staff and reviewed at regular intervals, and at least daily. No loading dose will be administered. The starting dose will be 1.0µg.kg-1.hour-1 titrated to a maximum dose of 2 µg.kg-1.hour-1. Lower starting doses will be used at clinical discretion for patients with cardiovascular instability.", 'interventionNames': ['Drug: Clonidine']}
- {'label': 'Usual Care (Propofol) Group', 'type': 'ACTIVE_COMPARATOR', 'description': 'Usual Care Group : Patients will continue to receive intravenous propofol according to usual current care . The sedation targets, weaning, and sedation discontinuation procedures will follow the same clinical targets as for the clonidine and dexmedetomidine groups.', 'interventionNames': ['Drug: Propofol']}

Interventions:
- {'type': 'DRUG', 'name': 'Dexmedetomidine', 'description': 'Patients will commence intravenous infusion of open-label study drug according to a weight-based dose regimen as early as possible post-randomisation, and within a maximum of two hours.\n\nBedside clinical staff will transition patients to achieve sedation with the allocated α2-agonist agent as quickly as clinically feasible and safe, to replicate the way these drugs would be used in routine practice. Additional opiate will be used for analgesia using clinical judgement. Once established, additional propofol will only be used when the maximum α2-agonist dose is reached or because cardiovascular or other side-effects limit dose escalation.', 'armGroupLabels': ['Dexmedetomidine Group'], 'otherNames': ['Dexdor']}
- {'type': 'DRUG', 'name': 'Clonidine', 'description': 'Patients will commence intravenous infusion of open-label study drug according to a weight-based dose regimen as early as possible post-randomisation, and within a maximum of two hours.\n\nBedside clinical staff will transition patients to achieve sedation with the allocated α2-agonist agent as quickly as clinically feasible and safe, to replicate the way these drugs would be used in routine practice. Additional opiate will be used for analgesia using clinical judgement. Once established, additional propofol will only be used when the maximum α2-agonist dose is reached or because cardiovascular or other side-effects limit dose escalation.', 'armGroupLabels': ['Clonidine Group'], 'otherNames': ['Catapres']}
- {'type': 'DRUG', 'name': 'Propofol', 'description': 'Patients will continue to receive intravenous propofol according to current usual care.', 'armGroupLabels': ['Usual Care (Propofol) Group'], 'otherNames': ['Diprivan']}

Primary Outcomes:
- {'measure': 'Time to first successful extubation post-randomisation (hours).', 'description': 'How many hours are participants on the study ventilated for?', 'timeFrame': 'Ventilation status will be recorded twice daily from the date of randomisation until the date of documented successful extubation, or 180 days, whichever comes first.'}

Please estimate the sample size based on the assumption: 
The statistical assumptions include maintaining 99% power for stage 1 comparisons and the superiority comparison in stage 2, increasing the significance level for the non-inferiority test from 2.5% to 4%, and an increase in the familywise type I error rate from 5% to 6.5%. The power for detecting the mortality effect decreased from 83% to 76%.
Modifications to sample size due to impact of COVID-19 pandemic
          The COVID-19 pandemic had a major impact on the trial progress and recruitment. In consultation with the funder, a modification to the original sample size was agreed in February 2023. The focus was on maintaining high power for the stage 1 hypothesis testing, and included modelling the impact of a reduced sample size on the stage 2 test of non-inferiority of clonidine versus dexmedetomidine, plus the power for detecting an effect on mortality. Based on these investigations, the sample size was reduced to 1437. This maintained 99% power for the stage 1 comparisons of clonidine and dexmedetomidine versus propofol (H1 and H2), and also for the superiority comparison of dexmedetomidine versus clonidine if progression to stage 2 testing occurs (H4). The main effect on power was for the non-inferiority comparison of clonidine versus dexmedetomidine (H3). For this comparison, in order to maintain 80% power when using the non-inferiority margin of 1âday, the significance level for test H3 was increased from 2.5% to 4%. This change to the hypothesis testing hierarchy meant that the upper limit on the familywise type I error rate increased from 5% to 6.5%. For the key secondary outcome of mortality, for the same 7% mortality difference, power decreased from 83% to 76%.