Oncology, Pharmacy, Data, Open Source, Dexamethasone
Just before the world stopped for the COVID-19 pandemic, I wrote a blog post on TheDataLab’s website about High Dose Dexamethasone. I was worried that 40mg Dexamethasone seemed to be being dispensed in Primary Care. This is a huge dose and would normally only have use in Haemato-oncology as part of a handful of specialist cancer treatments. In fact, even in secondary care, I would be worried that the risk of dispensing error was too high to justify keeping this in stock.
Distracted by the pandemic I kept an eye on prescribing rates and noticed they were descending. Only last year I discovered Dexamethasone 40mg Tablets had been discontinued. We still don’t know if these dispensing events we saw were real or were data anomalies. I suggested to Chloë Waterson that she might want to take a look at the data when she was looking to learn R; whereby she told me it was no more! She had a look at some even scarier stuff instead![1]
So here is a very brief look at what happened, complete with code for those who like a simple R project
Get the Data from Open Prescribing
Code
require(tidyverse, warn.conflicts = F)require(httr, warn.conflicts = F)require(jsonlite, warn.conflicts = F)DexId <-"0603020G0AACJCJ"# This is the product code for 40mg Dex on Open Rxurl <- glue::glue("https://openprescribing.net/api/1.0/spending/?code={DexId}&format=json")response <-GET(url)# translate the API response into a datatabledata <-fromJSON(rawToChar(response$content))# translate dates as dates not textdata |>mutate(date =as.Date(date)) -> data# show the dataDT::datatable(data)
Graph the Data
Code
require(ggplot2)data |>ggplot(aes(y=quantity, x=date)) +geom_col() +# creates a basic column graphtheme_bw() +# cleaner themeggtitle("Number of 40mg Dexamethasone tablets dispensed each month") +expand_limits(x=as.Date("2024-07-01")) +# stretch the x axis to show all the missing right hand data pointsannotate( # label when the original blog happened'text',x =as.Date("2019-08-15"),y =75,label ='Blog\nPublished',fontface ='bold', size =3.5,angle =0 ) +annotate('curve',x =as.Date("2019-11-15"),y =50,yend =28,xend =as.Date("2019-11-15"),linewidth =1,curvature =0,arrow =arrow(length =unit(0.2, 'cm')) ) -> g1print(g1)
We can repeat the process for the number of prescriptions dispensed instead of the number of tablets dispensed. And we can combine those using cowplot.
Code
data |>ggplot(aes(y=items, x=date)) +geom_col() +# creates a basic column graphtheme_bw() +# cleaner themeggtitle("Number of 40mg Dexamethasone prescriptions dispensed each month") +expand_limits(x=as.Date("2024-07-01"), y=20) +# stretch the x axis to show all the missing right hand data pointsannotate( # label when the original blog happened'text',x =as.Date("2019-08-15"),y =15,label ='Blog\nPublished',fontface ='bold', size =3.5,angle =0 ) +annotate('curve',x =as.Date("2019-11-15"),y =11,yend =6.5,xend =as.Date("2019-11-15"),linewidth =1,curvature =0,arrow =arrow(length =unit(0.2, 'cm')) ) -> g2print(g2)
So it definitely looks like I can stop worrying about 40mg Dexamethasone Tablets. But that, instantly made me wonder what happened to the other products I’d been a bit worried by - the 10mg capsule. Well it seems when the 40mg tablet was discontinued a 10mg and 20mg tablet that were launched at the same time!1
Other Tablet Strengths
A browse through the dm+d directory finds these possible suspects:
“Higher” Strength Dexamethasone Tablets
Description
BNF Code
Dexamethasone 10mg capsules
0603020G0AABYBY
Dexamethasone 10mg soluble tablets sugar free
0603020G0AACLCL
Dexamethasone 20mg soluble tablets sugar free
0603020G0AACMCM
These products do still appear to be available, based on the dm+d directory at least. If we re-run the data download for each of these codes we can create a combined graph. If there was a genuine clinical use for the 40mg tablets, we might expect to see an increase in 20mg dispensing when the 40mg becomes unavailable.
Get the data
Code
# Add a strength column to the original datadata |>mutate(strength ="40mg") -> dataids =c("10mg"="0603020G0AABYBY","10mg"="0603020G0AACLCL", "20mg"="0603020G0AACMCM")# use a loop to repeat the download for each idfor ( DexId in ids ) { url <- glue::glue("https://openprescribing.net/api/1.0/spending/?code={DexId}&format=json") response <-GET(url) newdata <-fromJSON(rawToChar(response$content)) newdata |>mutate(date =as.Date(date)) |>mutate(strength =names(ids[ids == DexId]))-> newdata data <-rbind(data, newdata)}url <- glue::glue("https://openprescribing.net/api/1.0/spending/?code={DexId}&format=json")response <-GET(url)# translate the API response into a datatablenewdata <-fromJSON(rawToChar(response$content))# translate dates as dates not textnewdata |>mutate(date =as.Date(date)) -> newdata# show the dataDT::datatable(data)
It looks like we do have some higher strength dispensing happening in 2024!
Graph the new data
That’s certainly not a reassuring picture! While the majority of the use is 10mg, even 10mg is a relatively high dose for prescribing in primary care. The equivalent prednisolone dose for 10mg of dexamethasone is over 65mg.
This graph is more curious. When 40mg tablets were being dispensed (up to the end of 2022), there was a median of 2 prescriptions per month for 22 tablets per month. Between July-19 and June-21, 18 grams of dexamethasone was dispensed. If the 10mg and 20mg tablets directly replaced these, then a similar number of grams should be being dispensed in a similar time span. In fact, since the introduction of 20mg tablets, a median of 7 prescriptions per month and 83 tablets per month have been dispensed.
In the time period July-22 to June-24, 70.47 grams of dexamethasone were dispensed, representing a 4 fold increase in the use of higher strength steroid tablets.
Conclusion
The discontinuation of 40mg Dexamethasone Tablets resulted in a brief period without dispensing of any high strength dexamethasone prescriptions. While high doses may still have been dispensed using lower strength tablets, the potential to identify these as possibly erroneous is increased by the dispensing of large tablet counts to achieve high doses. However, following the introduction of 10 and 20mg tablets there now seems to be a 4 fold increase in the dispensing of high doses of steroids using higher strength tablets. I am not reassured!
— Content on this website has been produced with reasonable care. However, errors can occur. Opinions change over time. Code that worked at the time of publication may no longer work. Users of all content from this site do so at their own risk.
References
1. Waterson, C., & Polwart, C. (2023). Prescribing of SystemicAnti-CancerTherapies(SACT) Through PrimaryCare in England. Journal of Oncology Pharmacy Practice, 30(1_suppl). https://doi.org/10.1177/10781552241228011
Footnotes
There were also 4mg and 8mg tablets launched back when the 40mg tablet was launched. While they still have risks of dispensing errors, the consequential risks is lower and 4 and 8mg are doses that would be commonly prescribed in primary care.↩︎
Reuse
This post is released under CC-BY-4.0 https://creativecommons.org/licenses/by/4.0/. Data shown is sourced from Open Prescribing, who obtain it from NHS BSA under an Open Government License.