The regression discontinuity (RD) design is a quasi-experimental design that estimates the causal effects of atreatment by exploiting naturally occurring treatment rules. It can be applied in any context where a particu-lar treatment or intervention is administered according to a pre-specified rule linked to a continuous variable.Such thresholds are common in primary care drug prescription where the RD design can be used to estimate thecausal effect of medication in the general population. Such results can then be contrasted to those obtained fromrandomised controlled trials (RCTs) and inform prescription policy and guidelines based on a more realisticand less expensive context. In this paper, we focus on statins, a class of cholesterol-lowering drugs, however, themethodology can be applied to many other drugs provided these are prescribed in accordance to pre-determinedguidelines. Current guidelines in the UK state that statins should be prescribed to patients with 10-year cardio-vascular disease risk scores in excess of 20%. If we consider patients whose risk scores are close to the 20% riskscore threshold, we find that there is an element of random variation in both the risk score itself and its mea-surement. We can therefore consider the threshold as a randomising device that assigns statin prescription toindividuals just above the threshold and withholds it from those just below. Thus, we are effectively replicatingthe conditions of an RCT in the area around the threshold, removing or at least mitigating confounding. We framethe RD design in the language of conditional independence, which clarifies the assumptions necessary to applyan RD design to data, and which makes the links with instrumental variables clear. We also have context-specific knowledge about the expected sizes of the effects of statin prescription and are thus able to incorporate this intoBayesian models by formulating informative priors on our causal parameters.