Keywords
Cardiology, Medical Education, R Shiny, Cardiac Cycle, Wiggers Diagram, 3D Heart Model, Interactive Learning, Clinical Cases, Left Atrium.
Understanding the fundamental basics of cardiology remains a persistent challenge for students. Traditional methods often fail to present these concepts clearly. To address this educational gap, we developed CardioLearn, an interactive application designed to facilitate active learning in cardiology. The tool integrates anatomical visualisation, temporal simulations, and clinically oriented problem-solving exercises, offering a learner-centred approach to support conceptual understanding and application.
CardioLearn is an open-source, web-based application developed in R utilising the Shiny framework, along with the shinythemes and other packages. The platform comprises four interactive modules: a Cardiac Cycle Explorer, featuring an annotated Wiggers diagram to visualise pressure-volume relationships; a Quiz Module for self-assessment of the fundamentals of cardiology; a 3D Heart Model that highlights left atrial dynamics in response to user-controlled left ventricular function parameters; and a Clinical Cases module presenting scenario-based exercises to support diagnostic reasoning skills.
CardioLearn features a user-friendly interface, guiding users through four distinct modules. The Cardiac Cycle module enables phase-by-phase exploration of the cardiac cycle, with each phase visually highlighted on a Wiggers diagram accompanied by descriptive annotations. The Quiz Module reinforces active recall through multiple-choice questions, providing feedback to support knowledge retention. The 3D Heart Model displays a visualisation of the left atrium in which users can manipulate left ventricular function parameters and left atrial phase to conceptualise changes in atrial size, blood flow, and valve dynamics. The Clinical Cases module presents structured scenarios that integrate key diagnostic elements, encouraging the application of cardiology principles to real-world clinical scenarios.
CardioLearn is an accessible, interactive educational tool designed to supplement the traditional medical student curriculum. It converges visual, conceptual and applied learning modalities, improving understanding and engagement among medical students. CardioLearn addresses a pertinent educational gap in the knowledge of core cardiology concepts using an active, learner-centred approach.
Cardiology, Medical Education, R Shiny, Cardiac Cycle, Wiggers Diagram, 3D Heart Model, Interactive Learning, Clinical Cases, Left Atrium.
Globally, cardiovascular disease (CVD) is the leading cause of mortality, with an estimated 19.42 million deaths attributed to CVD.1 This highlights the growing global burden of CVD and underscores the critical importance of comprehensive and effective education in cardiovascular concepts for medical students and trainees. Fundamental topics such as the cardiac cycle, cardiovascular anatomy, and physiology are essential to clinical competence; however, they are often cited as challenging areas for students and remain a persistent knowledge gap.2–3 These challenges may appear more clearly during the practical application of these concepts to clinical scenarios and examinations. Traditional methods alone may not adequately support the comprehensive undertaking of complex medical concepts and may require supplementary learning modalities. Interactive learning tools and AI-driven simulations have shown promise in bridging this educational gap through improving student engagement and facilitating a deeper understanding.4 Interactive virtual learning tools and simulations allow students to learn and understand in a safe environment, free from the pressure of a formal teaching setting. Students can tailor their learning to suit their needs and preferred learning styles. Reflecting this, the use of simulated and virtual learning environments is increasingly adopted by medical educators to supplement traditional methods and reinforce understanding.5
Many tools have been developed to address these challenges in cardiology education through virtual learning and/or simulation. For example, the Harvey Cardiopulmonary Simulator has been used in a clinical education setting to simulate a range of cardiac findings, although its use is typically restricted to physical simulators in institutional settings.6 More recently, online platforms such as Human BioDigital offer passive visualisation of cardiovascular anatomy and physiology, but lack engaging and interactive learning modules.7 In contrast, CardioLearn aims to provide a fully open-source, browser-based environment that combines visual simulation, interactivity, self-assessment, and clinical reasoning to support active learning in the foundations of cardiology.
CardioLearn is an interactive web-based application built using the R programming language and the Shiny framework, designed to supplement understanding of cardiology principles in medical education. CardioLearn integrates several learning modalities to cover foundational aspects of cardiology and bridge the gap between theoretical knowledge and clinical application. These include a visual exploration of the cardiac cycle through an interactive Wiggers diagram, a formative self-assessment quiz to reinforce conceptual understanding, a simplified interactive 3D model illustrating left atrial dynamics, and a series of clinical case studies. Cardiolearn is designed to be an accessible, open-access supplementary resource for medical students seeking to strengthen their understanding of essential cardiology. Cardiolearn is a scalable and effective teaching modality that can be widely adopted, serving as both a self-directed learning resource for students and a teaching aid for educators.
CardioLearn was developed in R version 4 and uses several R packages to create its interactive features and user interface.8 The Shiny package provides the core framework for web applications.9 The user interface is designed using the shinythemes package (shinytheme, “flatly” theme).10 Data visualisation for 2D plots (Wiggers diagram, LA physiological curves) is generated by ggplot2.11 Data manipulation is facilitated by dplyr.12 Interactive tables for future expansions or detailed data display can be implemented with DT.13 Static educational content can be rendered using markdown.14 The 3D visualisation of the heart model utilises the rgl package for creating and displaying interactive 3D graphics within the Shiny application.15 The application’s structure is modular, with distinct sections for different learning activities:
This module utilises predefined data (cardiac_phases, Wiggers_data) to generate an annotated, interactive Wiggers diagram. Users can select a specific phase of the cardiac cycle, which is then highlighted on the diagram, along with a textual description of the anatomical and physiological events that occur during that phase ( Figure 1). The Wiggers diagram plots are simplified representations of ECG voltage, aortic pressure, ventricular pressure, atrial pressure, and ventricular volume against normalised time to enhance comparative learning across phases.
The Cardiac Cycle module displays an interactive Wiggers diagram, allowing specific phases to be selected - as illustrated for atrial systole. Users can explore synchronised ECG, pressure, and volume curves across a normalised cardiac cycle, supported by descriptive annotations to reinforce phase-specific physiology.
A list of multiple-choice questions (quiz_questions) is accessible within the application. The user interface dynamically renders one question at a time, and the server logic evaluates the user’s answer, provides immediate feedback, and tracks the score ( Figure 2).
This module utilises the rgl package to create a simplified 3D representation, focusing on the left atrium (LA). Users can adjust a slider representing “Left Ventricular Function” (in percentage terms). Reduced left ventricular (LV) function conceptually leads to an increase in the displayed left atrial (LA) size, as indicated by both diameter and 3D model radius. Users can also select the “LA Cycle Phase” (Filling or Ejection). These inputs dynamically alter: The 3D LA model’s appearance (colour) and simulated blood flow direction (represented by coloured lines for pulmonary vein inflow and LA to LV outflow). The state of a conceptual mitral valve (open/closed, represented by a colored sphere) ( Figure 3).
This module displays a 3D model of the left atrium, with user-controlled left ventricular (LV) function and atrial phase. The model in this figure shows 70% LV function during diastolic filling. The 3D model visualises chamber size and flow, while the pressure-volume loop illustrates hemodynamic changes linked to ventricular performance and atrial phase.
LA Pressure-Volume Loop, Diastolic Filling (E/A Wave), LA Pressure Curve (A, C, V waves), and LA Volume Curve. These plots are conceptual and change based on the LV function and LA cycle phase inputs to illustrate physiological trends (e.g., increased LA pressure/volume and altered E/A ratio with worsening LV function).
This section presents users with brief clinical scenarios (clinical_cases), each followed by a multiple-choice question asking for the most likely diagnosis. The application provides feedback and an explanation for the correct answer ( Figure 4).
CardioLearn is designed to be accessible via a web browser. It can also be deployed on a Shiny server (e.g., Posit Connect Cloud) or run locally if R and the necessary packages are installed.16–17 The user interface consists of a sidebar for navigating between the different modules (Home, Cardiac Cycle, Quiz, 3D Heart Model, and Clinical Cases), and a main panel where the content for the selected module is displayed.
Navigating through the application can be done by using the sidebar. The server logic uses a reactiveVal (current_page) to manage which module’s user interface is rendered in the main panel. User interactions within each module (e.g., selecting a cardiac phase, answering a quiz question, adjusting the LV function slider) trigger reactive updates to the displayed plots, text, or 3D model. The 3D model generated by rgl is embedded using rglwidgetOutput and can be manipulated (rotated and zoomed) directly by the user in the browser.
Running CardioLearn locally requires a standard computer with a modern web browser. A minimum of 1 GB of RAM and an active installation of R version 3.1.0. or higher are recommended. The application depends on the following R packages: shiny, shinythemes, ggplot2, dplyr, DT, rmarkdown, and rgl.
CardioLearn is intended for undergraduate medical students as a supplementary tool to their existing curriculum.
Visualising the Cardiac Cycle: Students can select “Isovolumetric Contraction” from the dropdown in the “Cardiac Cycle” module. The Wiggers diagram will highlight the corresponding time interval, and the description will explain that the ventricles contract with all valves closed. This helps correlate ECG events, pressure changes, and volume changes visually, allowing students to easily digest the information. Self-Assessment of Knowledge: In the “Quiz” module, a student might encounter the question, “Which ECG wave represents atrial depolarisation?” They select an option and click “Submit.” If correct, they receive positive feedback; if incorrect, the correct answer is provided. This allows for low-stakes formative assessment. Exploring Anatomical and Physiological Relationships (3D Model): A student navigates to the “3D Heart Model.” Input 1: They set “Left Ventricular Function” to 30% (simulating heart failure) and “LA Cycle Phase” to “Filling.”
Output 1: The 3D LA model appears enlarged, colored to indicate filling, with simulated flow from pulmonary veins and an open mitral valve. The associated “Diastolic Filling (E/A Wave)” plot shows a predominant A wave (or an increased E/A ratio, depending on the specific impairment logic), and the “LA Pressure-Volume Loop” is shifted upward and to the right, indicating higher pressures and volumes. Input 2: They then change “LA Cycle Phase” to “Ejection”. Output 2: The 3D LA model changes colour, flow is shown towards the conceptual LV, and the mitral valve closes. The corresponding points on the 2D curves would be highlighted if such interactive linking were implemented for the current phase.
Developing Clinical Reasoning: In the “Clinical Cases” module, students read a scenario describing a patient with crushing chest pain and ST-elevation on the ECG. They are asked for the most likely diagnosis. Upon selecting “Myocardial Infarction” and submitting, they receive confirmation and a brief explanation reinforcing the link between symptoms, ECG findings, and the diagnosis.
CardioLearn provides an interactive, multi-modal educational platform for medical students to explore fundamental cardiology concepts. By integrating visual diagrams, a 3D anatomical model, self-assessment quizzes, and clinical scenarios, it aims to cater to diverse learning preferences and promote active engagement with the material. The focus on left atrial dynamics in the 3D module, while simplified, offers a unique way to visualise the interplay between ventricular function and atrial remodelling, as well as the phases of atrial mechanical function.
CardioLearn is an educational tool and not a clinical diagnostic aid or a comprehensive physiological simulator. The Wiggers diagram, 3D heart model, and associated physiological curves are simplified representations designed for conceptual understanding rather than precise quantitative accuracy. The 3D model focuses explicitly on the left atrium and does not depict the entire heart or complex valvular mechanics in full detail. The range of quiz questions and clinical cases is currently limited but can be expanded. The physiological responses in the 3D model (e.g., LA size change with LV function) are based on general principles and are not derived from complex computational models.
Future enhancements could include expanding the content to include more cardiac conditions, a more detailed 3D heart model that covers all chambers and valves, incorporating heart sounds into the cardiac cycle module, and adding more sophisticated physiological simulations. User feedback will be instrumental in guiding further development. The open-source nature of the R and Shiny ecosystem facilitates community contributions and adaptations.
CardioLearn provides a valuable and engaging supplementary resource for medical students embarking on their journey into the field of cardiology.
All clinical cases presented in the application are hypothetical and constructed for educational purposes. No real patient data was used in the development of this tool.
The R source code for the CardioLearn Shiny application (app.R) is available on GitHub. The application can be run locally by cloning the GitHub repository and running the app.R file within an R environment with all required packages installed (shiny, shinythemes, ggplot2, dplyr, DT, markdown, rgl). It is also hosted publicly.
Software available from: https://connect.posit.cloud/786miii/content/0197370c-7a22-98e9-dd38-66571d2ad4be
Source code available from: https://github.com/mahmood789/Cardiac3d
Archived source code: https://doi.org/10.5281/zenodo.15742898 (Mahmood A. CardioLearn: An Interactive R Shiny Application for Foundational Cardiology Education (1.0) [dataset]. Zenodo; 2025. Available from: https://doi.org/10.5281/zenodo.15742898)17
License: Apache License 2.0
Standard medical and physiological units are used where implied (e.g., mmHg for pressure, % for ejection fraction). The 3D model coordinates are in arbitrary rgl units designed for visualisation. No complex mathematical scripts are presented outside the inherent logic within the R code.
The data used for the Wiggers diagram (wiggers_data), cardiac cycle phase descriptions (cardiac_phases), quiz questions (quiz_questions), and clinical cases (clinical_cases) are explicitly defined within the app.R source code. No external datasets are required to run the application. These datasets are intended for educational purposes and are provided for illustrative purposes.
Archived source code: https://doi.org/10.5281/zenodo.15742898 (Mahmood A. CardioLearn: An Interactive R Shiny Application for Foundational Cardiology Education (1.0) [dataset]. Zenodo; 2025. Available from: https://doi.org/10.5281/zenodo.15742898)17
License: Apache License 2.0
Views | Downloads | |
---|---|---|
F1000Research | - | - |
PubMed Central
Data from PMC are received and updated monthly.
|
- | - |
Provide sufficient details of any financial or non-financial competing interests to enable users to assess whether your comments might lead a reasonable person to question your impartiality. Consider the following examples, but note that this is not an exhaustive list:
Sign up for content alerts and receive a weekly or monthly email with all newly published articles
Already registered? Sign in
The email address should be the one you originally registered with F1000.
You registered with F1000 via Google, so we cannot reset your password.
To sign in, please click here.
If you still need help with your Google account password, please click here.
You registered with F1000 via Facebook, so we cannot reset your password.
To sign in, please click here.
If you still need help with your Facebook account password, please click here.
If your email address is registered with us, we will email you instructions to reset your password.
If you think you should have received this email but it has not arrived, please check your spam filters and/or contact for further assistance.
Comments on this article Comments (0)