Skip to content

mairamorenoc/MalariaScan

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MalariaScan | OCS/ICICT/Fiocruz

R Docker

MalariaScan is a web-based platform for real-time detection, analysis, and visualization of spatiotemporal malaria clusters in cross-border region between Brazil and French Guiana.

Built with R Shiny, SaTScan™, and Docker, it enables public health teams to identify potential outbreaks and support data-driven decision-making.


📒 Project Background

Malaria remains a major public health challenge in border regions such as Brazil–French Guiana, where:

  • Surveillance systems are fragmented
  • Population mobility is high
  • Access to analytical tools is limited

MalariaScan was designed to bridge the gap between advanced spatial analysis and real-world public health needs, making complex methods accessible to non-technical users.


🎯 What this application does

  • Detects abnormal increases in malaria cases
  • Identifies spatiotemporal clusters using scan statistics
  • Supports early outbreak detection
  • Provides an interactive and intuitive interface
  • Enables data-driven surveillance workflows

✅ MalariaScan Key Features

  • 📍 Interactive maps with Leaflet
  • 📈 Time series visualization with Highcharter
  • 🔍 Cluster detection via SaTScan™ software
  • 🧮 Statistical validation of detected disease clusters
  • 🤖 Integrated chatbot with FAQs to guide users in:
    • navigating the application
    • understanding analytical outputs
    • interpreting cluster detection results
  • 🧩 Modular R-based architecture
  • 🐳 Fully containerized environment via Docker

📁 Project Structure

malariascan/
│
├── app.R                         # Main Shiny application (UI + server)
├── Dockerfile                    # Container setup
├── satscan.10.2.5.linux.tar.gz   # SaTScan™ package used in the Docker build
├── README.md
├── .gitignore
│
├── R/                            # Supporting functions
│   ├── sscan_data.R
│   └── update_prm.R
│
├── data/                         # Input data (not versioned)


⚙️ Tech Stack

Languages & Frameworks

  • R
  • Shiny

Spatial & Statistical Analysis

  • SaTScan™ software

Infrastructure

  • Docker
  • Linux environment

R packages

Responsibility R package
App UI/Server shiny, shinydashboard, shinyjs
Interactive Maps leaflet, leaflet.extras, viridis
Data Visualization highcharter, DT
Data Manipulation jsonlite, dplyr, data.table, sf, lubridate, foreign

🌐 Public Demo

A public demo of MalariaScan can be accessed online throught the following link: https://www.malariascanapp-demo.online/


▶️ How to Run Locally

1. Clone repository

git clone https://github.com/mairamorenoc/MalariaScan.git
cd malariascan

2. Add required data

Create a data/ folder and include:

  • Shapefiles
  • Malarias cases datasets
  • SaTScan .prm configuration file

⚠️ Data is not included in this repository due to size constraints.

3. Build Docker image

docker build -t malariascan .

4. Run container

docker run -p 3838:3838 malariascan

Access the app at: http://localhost:3838


🧱 System Architecture

De-identified Malaria Cases Data → R Processing → SaTScan™ → Shiny App → Interactive Dashboard

  • Main Components
    • Data layer: Surveillance systems (Brazil's SIVEP-Malária)
    • Data Processing: R (data cleaning & preparation)
    • Statistical Analysis: SaTScan™ (scan statistics)
    • Data Visualization: Shiny, Leaflet, Highcharter
    • Deployment: Docker

📊 Statistical Methodology

The MalariaScan platform integrates prospective spatiotemporal scan statistics to detect and monitor clusters of malaria cases in near real-time.

🔍 Scan Statistics Approach

Cluster detection is performed using the space-time scan statistic implemented in SaTScan™, applying a cylindrical scanning window:

  • Base: geographic area
  • Height: time interval

This approach enables the identification of spatiotemporal clusters, capturing both the location and timing of potential increases in malaria cases.

⚙️ Model Specification

The analysis uses the Space-Time Permutation Model, which is particularly suitable for surveillance contexts where:

  • Only case data are available
  • No reliable population-at-risk data are required
  • Data may come from multiple surveillance systems

Instead of relying on expected counts derived from population data, the model:

  • Adjusts for purely spatial variation
  • Adjusts for purely temporal variation
  • Detects unexpected space-time interactions

📡 Prospective Surveillance

MalariaScan operates in prospective analysis mode, meaning:

  • The system continuously evaluates incoming data
  • Only active or emerging clusters are reported
  • Clusters are detected as they occur, not retrospectively

This makes the platform suitable for real-time epidemiological surveillance and early warning systems.

📈 Outputs Generated

The system identifies and reports:

  • Geographic location of clusters
  • Time interval of occurrence
  • Observed vs expected distribution patterns
  • Relative concentration of cases
  • Statistical significance (p-value)

🐳 Docker Notes

  • Includes full R + Shiny environment
  • Designed for reproducibility
  • SaTScan must be available inside the container

💡 Future Improvements

  • Production deployment
  • Performance optimization for large datasets
  • Alert system for detected clusters
  • Expansion to other diseases

🤝 Acknowledgments

  • Fundação Oswaldo Cruz (Fiocruz)
  • Observatório de Clima e Saúde (Icict/Fiocruz)
  • French National Research Institute for Sustainable Development (IRD)
  • Conselho Nacional de Desenvolvimento Científico e Tecnológico - Brazil (CNPq)

📚 References

Key works supporting this project include:

  • Kulldorff, Martin, et al. "A space–time permutation scan statistic for disease outbreak detection." PLoS medicine 2.3 (2005): e59.
  • Saldanha, Raphael, et al. "Contributing to elimination of cross-border malaria through a standardized solution for case surveillance, data sharing, and data interpretation: development of a cross-border monitoring system." JMIR public health and surveillance 6.3 (2020): e15409.

📩 Contact

Maira Alejandra Moreno
GitHub
[email protected]

About

Interactive web app for real-time detection and visualization of malaria clusters in cross-border regions, using R Shiny, SaTScan, and Docker.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors