{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
""
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# H/ICH/MedDRA/FMQs by FDA\n",
"\n",
"The Medical Dictionary for Regulatory Activities (MedDRA) is a set of standardized terminologies commonly used in clinical safety recording, communicating, and reporting activities. MedDRA is developed and maintained by the International Council for Harmonisation of Technical Requirements for Pharmaceuticals for Human Use (ICH)[^1],[^2]. \n",
"\n",
"The FDA Medical Queries (FMQs) are groups of MedDRA terms used to describe conditions of interest published by FDA for the goal of improving transparency. \n",
"FMQ is available in public domain [^3],[^4],[^5]. A consolidated list of FMQ is shipped with this module.\n",
"The FMQ list shipped with this module is for demonstrating purpose. \n",
"The author(s) can not provide warranty or promises for the correctness, completeness, or usability of the list.\n",
"\n",
"The module `emt` includes basic functions for working with FMQs."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Assign FMQ File Path\n",
"\n",
"To find FMQ list file:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"from mtbp3.health.emt import Emt\n",
"\n",
"emt = Emt(folder_name='')\n",
"print(emt.find_files())\n",
"print(emt.find_fmq_file(file_path=\"\"))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"To get a list of FMQ terms:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"fmq_list = emt.find_fmq(fmq=[])"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"To check if a list of queries are included in the FMQ list file found above:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"print( emt.find_fmq(fmq_list[:3]+['This is not a standard query!']) )"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Find Terms Given a FMQ\n",
"\n",
"There are currently 104 FMQs.\n",
"There are 8,839 PTs utilized to define either broad or narrow scope of FMQs.\n",
"Note that 4 of 104 FMQs are algorithm based. \n",
"Algorithm based FMQs may utilize additional data sources, including labs, concomitant medication records, patient histories, etc.\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"To find a list of PT related to the first FMQ on the list:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"pt_list = emt.find_terms_given_fmq(fmq=[fmq_list[0]], narrow_only=False)\n",
"print(pt_list['classification'].value_counts())"
]
},
{
"cell_type": "markdown",
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"source": [
"## FMQ Tree\n",
"\n",
"To list PT under selected FMQs by classification:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"print('\\n'.join(emt.show_fmq_tree(fmq_list[:2])))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"To list PT under selected FMQs by classification and SOC:"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"print('\\n'.join(emt.show_fmq_tree(fmq_list[:2], with_soc=True)))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Please note that the SOCs involved in the output above are **synthetic**, and groupings may **NOT** make senses.\n",
"When the simulated distribution files were used, the function uses synthetic SOCs for the purpose of demonstrating the function usage. \n",
"The reason of using synthetic SOCs is to simplify data sharing during module development.\n",
"\n",
"**When a MedDRA distribution folder is assigned** by the user, the function will list real SOCs in the output.\n",
"\n",
"To align the output to the right:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"print('\\n'.join(emt.show_fmq_tree(fmq_list[:2], with_soc=True, to_right=True)))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Save Demo FMQ List to Local\n",
"\n",
"The FMQ list shipped with this module is for demonstrating purpose. \n",
"The author(s) can not provide warranty or promises for the correctness, completeness, or usability of the list.\n",
"\n",
"To save the FMQ list shipped with this module to a local folder in CSV format:"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"vscode": {
"languageId": "plaintext"
}
},
"outputs": [],
"source": [
"\n",
"# emt.save_fmq_consolidated_list_csv(folder_path=\"a_valid_folder_path\")"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Appendix - View PTs Given Any FMQ\n",
"\n",
"This folder does not host interactive contents. \n",
"A web version notebook is provided for using an interactive drop-down menu, and viewing all related PTs without installation of Python.\n",
"\n",
"Please visit the web page \n",
"[here](https://mybinder.org/v2/gh/yh202109/mtbp3supp/main?filepath=binder/example_emt3_appendix.ipynb)."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Reference\n",
"\n",
"[^1]: ICH. (2013). Understanding MedDRA. ([pdf](https://admin.meddra.org/sites/default/files/page/documents_insert/meddra2013_0.pdf))\n",
"[^2]: Dutta, A. (2020). MedDRA - Terminologies & Coding. ([pdf](https://meddra.org/sites/default/files/page/documents_insert/meddra_-_terminologies_coding.pdf))\n",
"[^3]: FDA. (2022). BIRRS FDA Medical Queries (FMQ) Project Update.([pdf](https://www.fda.gov/media/164639/download))\n",
"[^4]: Duke Margolis Institute for Health Policy. (2022). Public Workshop Advancing Premarket Safety Analytics. ([web page](https://healthpolicy.duke.edu/events/advancing-premarket-safety-analytics))\n",
"[^5]: Clio Wu. (2023) Why FDA Medical Queries (FMQs) for Adverse Events of Special Interest? Implementation and Case Study. PharmaSUG 2023 - Paper DS-036. ([pdf](https://www.lexjansen.com/pharmasug/2023/DS/PharmaSUG-2023-DS-036.pdf))"
]
}
],
"metadata": {
"language_info": {
"name": "python"
}
},
"nbformat": 4,
"nbformat_minor": 2
}