In this effort we investigate the design and use of physiological and device models to conduct pre-clinical trials to provide early insight in the design and execution of the actual clinical trial. Computer models of physiological phenomena like cardiac electrical activity can be extremely complex. However, when the purpose of the model is to interact with a medical device, then it becomes sufficient to model the measurements that the device makes, e.g. the intra-cardiac electrograms (EGMs) that an Implantable Cardioverter Defibrillator (ICD) measures. We present a probabilistic generative model of EGMs, capable of generating exemplars of various arrhythmias. The model uses deformable shape templates, or motifs, to capture the variability in EGM shapes within one EGM channel, and a cycle length parameter to capture the variability in cycle length in one EGM channel. The relation between EGM channels, which is essential for determining whether the current arrhythmia is potentially fatal, is captured by a time-delayed Markov chain, whose states model the various combinations of (learned) motifs. The heart model is minimally parameterized and is learned from real patient data. Thus the statistics of key features reflect the statistics of a real cohort, but the model can also generate rare cases and new combinations from the inferred probabilities. On the device end, algorithms for signal sensing, detection and discrimination for major ICD manufacturers have been implemented both in simulation and on hardware platforms. The generated arrhythmia episodes are used as input to both the modeled ICD algorithms and real ICDs as part of a Computer Aided Clinical Trial (CACT). In a CACT, a computer model simulates the inputs to the device (such as a new, investigational ICD), and the device’s performance is evaluated. By incorporating these results into the appropriate statistical framework, the Computer Aided Clinical Trial results can serve as regulatory evidence when planning and executing an actual clinical trial. We demonstrate this by conducting a mock trial similar to the 2005-2010 RIGHT trial which compared the discrimination algorithms from two major ICD manufacturers. The results of the CACT clearly demonstrate that the failed outcome of the RIGHT trial could have been predicted and provides statistical support for deeper results that could have been captured prior to the trial