1 of 22

AI-Generated R Functions Integrated with Proprietary Software for Clinical Trial Simulation

2024 Boston Pharmaceutical Statistics Symposium

J. Kyle Wathen

VP Scientific Strategy and Product Innovation

2 of 22

Outline

  • Why R integrated with proprietary software?
  • “Ideal” balance
  • AI can solve everything, right?
  • East Horizon R Chatbot
  • CyneRgy – Open Source R package provide examples of how to integrate R into East Horizon
  • Brief Summary

2

3 of 22

Use Case - Description

  • Phase 2 Study with two treatments – Control and Experimental
  • Normal outcomes
  • Decision: Go or No Go
    • Option 1 – Lower limit of frequentist confidence interval above the Minimum Acceptable Value (MAV)
    • Option 2 – Posterior probability that the treatment effect is greater than MAV
    • Option 3 – Option 2 + Data from previous trial on control treatment
  • Option to include an interim analysis for futility
    • Option 1 – Bayesian predictive probability of Go at the end is small then stop for futility
    • Option 2 – Bayesian predictive probability of a No Go at the end is high then stop for futility
    • Option 3 – Futility if treatment difference is less to 0
  • Option to include an interim analysis early success
    • Option 1 – Bayesian predictive probability of Go at the end is large then stop for early success
    • Option 2 – Bayesian predictive probability of a No Go at the end is low then stop for early success
  • What if we …

3

4 of 22

“Ideal” Balance?

4

Heavy Focus Commercial

Commercial

Open-Source and Custom

Heavy Focus Open-Source

Balance

5 of 22

Combine Open-Source and Commercial

5

Balance

Synergy

6 of 22

AI Usage for R Programming

  • Google: Does chatgpt support R programming

6

7 of 22

Modify Google Search

7

8 of 22

Ask ChatGPT what ChatGPT can do?

8

9 of 22

9

10 of 22

10

11 of 22

11

12 of 22

12

13 of 22

13

14 of 22

14

15 of 22

15

16 of 22

16

17 of 22

17

18 of 22

18

19 of 22

What If You Need More Flexibility?

Currently available integration points: 

Two Arms Single Endpoint designs

    • Initialization 
    • Response Generation
    • Analysis 
    • Arrival Process (Enrollment patterns)
    • Randomization
    • Dropout Information

19

20 of 22

Imagine What is Possible with East Horizon + R Integration!

20

  • Vaccine study – 25 Serotypes where at least 23 need to be successful
  • Composite endpoint based on the minimum of several time-to-event outcomes
  • Impact on power when non-constant and/or non-proportional hazards are utilized, delayed treatment effect 🡪 modestly weighted log rank
  • Comparing Bayesian analysis and frequentist analysis in the same system
  • Bayesian (or frequentist) Go/No Go approach in design with multiple interim analysis, potential to include prior data
  • Probability of success, Conditional probability of success

21 of 22

New CyneRgy GitHub Repository

  • Public GitHub repository: https://cytel-inc.github.io/CyneRgy/
  • R package that highlights the synergistic effect of combining Cytel's products and R
  • Include functions, examples, and documentation
  • Frequent updates to include new examples
  • Advanced examples being added, eg JAGS, STAN, including current enrollment data
  • More to come!

21

22 of 22

Summary

  • Adding in AI coding assistant solves somethings, unfortunately, not everything
  • Combining commercial software with open source provide tremendous advantages over commercial software or open source alone
  • R integration removes many roadblocks often encountered in commercial software and allows for exploration of cutting edge research

22