Here is the design of a clinical trial:

Official Title: Better Outcome With Melatonin Compared to Placebo Administered to Normalize Sleep-wake Cycle and Treat Hypoactive ICU Delirium The Basel BOMP-AID Randomized Trial

Included conditions:
- Hypoactive Delirium

Study Armgroups:
- {'label': 'Melatonin (Circadin ®)', 'type': 'EXPERIMENTAL', 'interventionNames': ['Drug: Melatonin (Circadin ®)']}
- {'label': 'Placebo', 'type': 'PLACEBO_COMPARATOR', 'interventionNames': ['Drug: Placebo']}

Interventions:
- {'type': 'DRUG', 'name': 'Melatonin (Circadin ®)', 'description': '4 mg of oral melatonin at 8 p.m. for the length of the duration of the hypoactive delirium', 'armGroupLabels': ['Melatonin (Circadin ®)']}
- {'type': 'DRUG', 'name': 'Placebo', 'description': 'Lactose monohydrate, cellulose powder, magnesium stearate (Ph. Eur.), mocrocristalline cellulose', 'armGroupLabels': ['Placebo'], 'otherNames': ['Oral tablet']}

Primary Outcomes:
- {'measure': 'Duration of hypoactive delirium', 'description': 'Duration of hypoactive delirium in the ICU in 8-hour shifts', 'timeFrame': 'From study inclusion to delirium resolution, assessed daily until the date of first documented progression or date of death from any cause, whichever came first, assessed up to 28 days'}

Please estimate the sample size based on the assumption: 
Significance level (alpha) is 5%. Power (1-beta) is 90%. Dropout rate is 5%. A Wilcoxon rank-sum test was used for statistical testing.
Determination of sample size
        Sample size was estimated to be able to show the superiority of melatonin compared with placebo regarding the duration of delirium (in number of shifts).
        The sample size calculation was based on an expected duration of delirium of 15 shifts (5 days) for patients treated with placebo (in line with ï¬ndings of Page et al,28 a reduction of the duration of delirium by Î´=3 shifts (1âday), and an SD in both arms of 6 shifts (2 days).
        Sample size was calculated with a resampling method. Each sample size, ni=1,â¦,49=10,â¦, 298, was evaluated by sampling 999 times ni/2 individual patients from a normal distribution with a mean of 15 (placebo arm) and ni/2 with a mean of 12 (melatonin arm), both with an SD of 6. In addition, different effect sizes for melatonin versus placebo, ranging from 1 to 6 shifts were applied to assess the sensitivity of the sample size with regard to the expected effect size. Because the number of shifts can only be positive negative simulated values (which rarely occurred) were replaced by zero. A Wilcoxon rank-sum test was used to test for a difference between trial arms. Sample size was set to ensure at least 90% power (1âÎ²=0.9) at a signiï¬cance level of 5% (Î±=0.05).
        For this study, assuming a difference in duration of delirium of 3 shifts and a SD of 6 shifts, 190 patients should be recruited to ensure 180 evaluable patients, considering a dropout rate of 5%. Figure 1 shows the sensitivity of the sample size is with respect to the expected effect size.
        
          Figure 1
          
            Total sample size (number of patients, not including dropouts) needed to be able to show the superiority of melatonin to placebo with respect to delirium duration (number of shifts), assuming an SD of 6 shifts, depending on the expected effect size. The numbers on the curves show the corresponding power. An example is shown for an effect size of 3 shifts and a power of 90%. The curves are smoothed and for illustration only.