# Samuel Bharti · full site text > Computational biologist building tools that make omics data easier to explore, trust, and share. PhD candidate at UAB, recently a Shiny SWE intern at Posit. Source: https://www.samuelbharti.com/. Generated 2026-08-26. This file concatenates the site's content for language models; links are absolute. ## Profile - Name: Samuel Bharti - Status: PhD candidate @ UAB · previously Posit (Shiny), Genentech (human genetics) - Site: https://www.samuelbharti.com/ - Email: samuelbharti.io@gmail.com - GitHub: https://github.com/samuelbharti - LinkedIn: https://www.linkedin.com/in/samuelbharti/ - Bluesky: https://bsky.app/profile/samuelbharti.com - Now (current focus): https://www.samuelbharti.com/now - NF1 research: https://www.samuelbharti.com/nf1 ## Work ### genescout *app · agents · evidence review · gene prioritization* An agentic evidence-review workbench. Give it a candidate list and a disease context, get back a plausibility-ranked, cited shortlist. Research use only. Links: [Live app](https://samuelbharti-io-genescout.share.connect.posit.cloud/) · [Demo video](https://www.youtube.com/watch?v=gaB0loPWeOk) · [GitHub](https://github.com/samuelbharti/genescout) · [DOI](https://doi.org/10.5281/zenodo.21352389) Page: https://www.samuelbharti.com/work/genescout ### tahoe-explorer *app · single-cell · perturbation · duckdb* Filter and subset Tahoe-100M perturbation metadata, 100.6 million rows, and leave with a reproducible pull recipe. Summaries push down to DuckDB. Links: [GitHub](https://github.com/samuelbharti/tahoe-explorer) · [DOI](https://doi.org/10.5281/zenodo.21950641) Page: https://www.samuelbharti.com/work/tahoe-explorer ### Plotomics Live *app · visualization · webgl · shinyreact · spatial* Twenty-six pages of GPU-accelerated visualization through shinyreact, in 476 lines of R, one of which is the UI. Precomputed .f32 blobs go straight to the GPU. Links: [GitHub](https://github.com/samuelbharti/plotomics-live) · [DOI](https://doi.org/10.5281/zenodo.21950647) Page: https://www.samuelbharti.com/work/plotomics-live ### variant-reviewer *app · variants · annotation · clinical genetics* One gene, one variant, one page. Eighteen cards fan out asynchronously across public APIs, with a 3D structure viewer and a ClinVar typeahead. Links: [GitHub](https://github.com/samuelbharti/variant-reviewer) · [DOI](https://doi.org/10.5281/zenodo.21950635) Page: https://www.samuelbharti.com/work/variant-reviewer ### plotomics *package · TypeScript · R · Python* 17 components · volcano · embedding · heatmap · igv · network · oncoplot · spatial · and ten more Seventeen GPU-accelerated visualizations from one TypeScript core, wrapped three ways: npm for React, htmlwidgets for R, anywidget for Python. The same core drops into all three unchanged. Links: [GitHub](https://github.com/samuelbharti/plotomics) · [Docs](https://www.samuelbharti.com/plotomics/) · [R-universe](https://samuelbharti.r-universe.dev/plotomics) · [npm](https://www.npmjs.com/package/plotomics) · [PyPI](https://pypi.org/project/plotomics/) · [DOI](https://doi.org/10.5281/zenodo.21926306) Page: https://www.samuelbharti.com/work/plotomics ### biobouncer *package · R · Python · TypeScript* 50 sources · 4 modes: pattern · cache · remote · existence A gate for biological inputs. Validate gene symbols, ontology terms, variant formats and accessions through one API, offline or live. R and Python share a conformance corpus, so the two cannot disagree. Links: [GitHub](https://github.com/samuelbharti/biobouncer) · [R-universe](https://samuelbharti.r-universe.dev/biobouncer) · [PyPI](https://pypi.org/project/biobouncer/) · [Demo video](https://www.youtube.com/watch?v=9UDEfIb7s0s) · [DOI](https://doi.org/10.5281/zenodo.21346522) Page: https://www.samuelbharti.com/work/biobouncer ### bioclients *package · R* 29 services · Ensembl · UniProt · gnomAD · Open Targets · AlphaFold One client per biological database, each split into a request half and a pure parser half that needs no network to test. Transport and caching are left to biohttp. Links: [GitHub](https://github.com/samuelbharti/bioclients) · [R-universe](https://samuelbharti.r-universe.dev/bioclients) · [Docs](https://www.samuelbharti.com/bioclients/) Page: https://www.samuelbharti.com/work/bioclients ### biohttp *package · R* circuit breaker · retry · throttle · success-only cache · batch Normalized HTTP transport. Calls return a result value rather than raising, so transport failure, a bad status code and an unreadable body stay distinct outcomes. Circuit breaking, retry and caching are defaults. Links: [GitHub](https://github.com/samuelbharti/biohttp) · [R-universe](https://samuelbharti.r-universe.dev/biohttp) · [Docs](https://www.samuelbharti.com/biohttp/) Page: https://www.samuelbharti.com/work/biohttp ### recount-explorer *app · rna-seq · recount3 · shiny* Shiny app to browse, analyze, and export recount3 RNA-seq studies: 18,998 datasets, quality checks, and PCA. Links: [GitHub](https://github.com/samuelbharti/recount-explorer) Page: https://www.samuelbharti.com/work/recount-explorer ### R Shiny Template *template · R* Reusable, public starter kit for quickly building reproducible bioinformatics and data apps in R Shiny. Links: [Read the post](/posts/r-shiny-template/) Page: https://www.samuelbharti.com/work/r-shiny-template ### R for Beginners *teaching · quarto · slides · carpentries* Interactive R lessons with paired slide decks, built on the Gapminder dataset for workshops and self-paced learning. Adapted from Software Carpentry's R novice course. Links: [Lessons](https://samuelbharti.github.io/r-for-beginners/) · [GitHub](https://github.com/samuelbharti/r-for-beginners) · [DOI](https://doi.org/10.5281/zenodo.19744262) Page: https://www.samuelbharti.com/work/r-for-beginners ### AWS R Shiny Deployment Workshop *teaching · aws · docker · workshop* Workshop on deploying a Dockerized R Shiny bioinformatics app on an AWS EC2 instance, using sMAP as the example. Hosted with STEM-Away. Links: [GitHub](https://github.com/samuelbharti/AWS_workshop_stemaway) · [Read the post](/posts/aws-r-shiny-deploy/) Page: https://www.samuelbharti.com/work/aws-r-shiny-deployment-workshop ### peacock *package · R · Python* Streamlines project initialization and workflow management. Links: [GitHub](https://github.com/samuelbharti/peacock) · [R-universe](https://samuelbharti.r-universe.dev/peacock) · [Docs](https://www.samuelbharti.com/peacock/) Page: https://www.samuelbharti.com/work/peacock ### GlucoKinaseDB *database · php · mysql · javascript · html/css* Manually curated database of 1,700+ glucokinase modulators with bioactivity and chemical data, in-browser 3D structure visualization, and API endpoints. Links: [Visit site](https://glucokinasedb.in/) · [Publication](https://doi.org/10.1016/j.compbiolchem.2023.107818) Page: https://www.samuelbharti.com/work/glucokinasedb ### PepEngine *database · php · mysql · javascript · html/css* Manually curated structural database of synthetic peptides containing the non-standard amino acids α,β-dehydrophenylalanine (ΔF) and α-aminoisobutyric acid (Aib). Links: [Visit site](https://pepengine.in/) · [Publication](https://doi.org/10.1007/s10989-022-10362-9) Page: https://www.samuelbharti.com/work/pepengine ### gene-list-builder *app · gene-disease · target discovery · provenance* Resolve a disease name to an EFO/MONDO term, query seven gene-disease sources in parallel, and dedupe to one row per gene. Re-ranks live as you tune the source weights. Links: [GitHub](https://github.com/samuelbharti/gene-list-builder) · [DOI](https://doi.org/10.5281/zenodo.21950640) Page: https://www.samuelbharti.com/work/gene-list-builder ### draft-reviewer *app · shiny · markdown · reviews* Local Shiny app for reviewing Markdown drafts in the browser: paragraph-anchored comments that survive edits, reviews saved as plain YAML, and an optional bring-your-own-key AI assistant. No server, no database, everything is a file. Links: [GitHub](https://github.com/samuelbharti/draft-reviewer) Page: https://www.samuelbharti.com/work/draft-reviewer ### Multi-Omics Locus Viewer (MOLV) *app · shiny · multi-omics · gwas* Shiny application and R package I built for the Human Genetics team at Genentech for locus-first, integrative visualization across 11,000+ GWAS, eQTL, pQTL, single-cell, and ATAC-seq datasets in Alzheimer's disease. Page: https://www.samuelbharti.com/work/multi-omics-locus-viewer-molv ### RAPTOR *app · python · agentic ai · ontologies* Record-based Abstraction of Phenotypes, Terms, Ontologies, and Disease Relations. An agentic AI system that pulls phenotypes, genes, diseases, and ontology-linked concepts out of unstructured patient records. Page: https://www.samuelbharti.com/work/raptor ### Pediatric Thyroid Cancer (PTC) Explorer *app · shiny · exome · rna-seq* Interactive genomics and clinical-analysis app for whole-exome and bulk RNA-seq pediatric thyroid cancer data. Page: https://www.samuelbharti.com/work/pediatric-thyroid-cancer-ptc-explorer ### Statistical Enrichment Analysis of Samples (SEAS) *app · shiny · clinotypes · cohorts* Online tool to characterize sample subsets (cohorts) and find enriched clinotypes, handy for balancing case/control cohorts and profiling samples in cross-sectional studies. Links: [Visit site](https://aimed-lab.github.io/SEAS/) · [Publication](https://doi.org/10.3389/fdata.2021.725276) · [Publication 2](https://doi.org/10.3389/fdata.2021.804141) Page: https://www.samuelbharti.com/work/statistical-enrichment-analysis-of-samples-seas ### NF1 scRNA-seq Integration App *app · shiny · single-cell · nf-core* Shiny app that brings nf-core outputs together with Seurat, pseudobulk, and CellChat for end-to-end single-cell and single-nuclei RNA-seq exploration in one place. Page: https://www.samuelbharti.com/work/nf1-scrna-seq-integration-app ### NF1 Rat Exome Data Explorer *app · shiny · exome · nf-core* Interactive explorer that combines nf-core whole-exome outputs with variant tools and AI-assisted analysis for NF1-associated tumor models. Page: https://www.samuelbharti.com/work/nf1-rat-exome-data-explorer ### sMAP (Standard Microarray Analysis Pipeline) *app · shiny · microarray · education* R Shiny educational app that walks users through an interactive transcriptomics pipeline with quality control, statistics, and biomarker discovery. Links: [Visit site](https://bi-stem-away.github.io/sMAP/) · [Publication](https://doi.org/10.1101/2022.05.27.492984) Page: https://www.samuelbharti.com/work/smap-standard-microarray-analysis-pipeline ### VIRdb 2.0 *database · php · mysql · javascript · html/css* Vitiligo research database with differentially expressed genes, curated protein targets, natural compounds, and co-expression network visualizations. Links: [Visit site](https://vitiligoinfores.com/) · [Publication](https://doi.org/10.12688/f1000research.25713.2) Page: https://www.samuelbharti.com/work/virdb-2-0 ### PAGER 3.0 & PAGER Web App *app · shiny · php · javascript · d3 · html/css* Pathways, Annotated-lists and Gene-signatures Electronic Repository, with an R Shiny web app for pathway and gene-set enrichment and network interpretation. Links: [PAGER](http://discovery.informatics.uab.edu/PAGER/) · [GitHub](https://github.com/aimed-uab/PAGER-Web-APP) · [Publication](https://doi.org/10.3389/fgene.2022.820361) Page: https://www.samuelbharti.com/work/pager-3-0-and-pager-web-app ### BioDivPortal *app · shiny · leaflet · geospatial* R Shiny app that maps and visualizes species occurrences across Poland, using Leaflet for geospatial mapping and dygraphs for time-series exploration. Page: https://www.samuelbharti.com/work/biodivportal ### ondemand-html-renderer *app · chrome extension · javascript · hpc* Chrome extension that restores HTML report viewing in OnDemand v2+. It detects report output and opens it in a clean preview tab instead of the broken in-app rendering. Links: [GitHub](https://github.com/samuelbharti/OnDemand-html-renderer) Page: https://www.samuelbharti.com/work/ondemand-html-renderer ## Research ### Publications - Siddharth Yadav, Samuel Bharti, Puniti Mathur (2023). GlucoKinaseDB: A comprehensive, curated resource of glucokinase modulators for clinical and molecular research. Computational Biology and Chemistry https://doi.org/10.1016/j.compbiolchem.2023.107818 - Samuel Bharti, Nikita Krishnan, Arian Veyssi, Maryam Momeni, Sneha Raj (2022). sMAP: An interactive microarray data analysis tool for early-stage researchers. bioRxiv https://doi.org/10.1101/2022.05.27.492984 - Zongliang Yue, Radomir Slominski, Samuel Bharti and Jake Y Chen (2022). PAGER Web APP: An Interactive, Online Gene Set and Network Interpretation Tool for Functional Genomics. Frontiers in Genetics https://doi.org/10.3389/fgene.2022.820361 - Siddharth Yadav, Samuel Bharti, Priyansh Srivastava & Puniti Mathur (2022). PepEngine: A Manually Curated Structural Database of Peptides Containing α, β- Dehydrophenylalanine (ΔPhe) and α-Amino Isobutyric Acid (Aib). International Journal of Peptide Research and Therapeutics. https://doi.org/10.1007/s10989-022-10362-9 - Nguyen, T. M., Bharti, S., Yue, Z., Willey, C. D., & Chen, J. Y. (2021). Statistical Enrichment Analysis of Samples: A General-Purpose Tool to Annotate Metadata Neighborhoods of Biological Samples. Frontiers in Big Data, 4, 725276. https://doi.org/10.3389/fdata.2021.725276 - Nguyen, T. M., Bharti, S., Yue, Z., Willey, C. D., & Chen, J. Y. (2021). Corrigendum: Statistical Enrichment Analysis of Samples: A General-Purpose Tool to Annotate Metadata Neighborhoods of Biological Samples. Frontiers in Big Data, 4, 804141. https://doi.org/10.3389/fdata.2021.804141 - Bharti, S., Sengupta, A., Chugh, P., & Narad, P. (2020). PluriMetNet: A dynamic electronic model decrypting the metabolic variations in human embryonic stem cells (hESCs) at fluctuating oxygen concentrations. Journal of Biomolecular Structure and Dynamics, 1-9. https://doi.org/10.1080/07391102.2020.1860822 - Srivastava, P., Talwar, M., Yadav, A., Choudhary, A., Mohanty, S., Bharti, S., Narad, P., & Sengupta, A. (2021). VIRdb 2.0: Interactive analysis of comorbidity conditions associated with vitiligo pathogenesis using co-expression network-based approach. F1000Research, 9, 1055. https://doi.org/10.12688/f1000research.25713.2 - Bharti, S., Narad, P., Chugh, P., Choudhury, A., Bhatnagar, S., & Sengupta, A. (2020). Multi-parametric disease dynamics study and analysis of the COVID-19 epidemic and implementation of population-wide intrusions: The Indian perspective. MedRxiv, 2020.06.02.20120360. https://doi.org/10.1101/2020.06.02.20120360 ### Presentations - Application of a Multi-Omics Approach in NF1-Deficient Tumors and Controls can Highlight Novel Associations and Therapeutic Targets. CCTS Translational Training Symposium, Biloxi, MS (Sep 2023). - Exploratory Analysis of Cancer Clinical Samples using the new Web-based SEAS Software. O'Neal Research Retreat, UAB (Oct 2022). - Exploratory Analysis of Cancer Clinical Samples using the new Web-based SEAS Software. CCTS Translational Training Symposium, Mobile, AL (Sep 2022). - PluriMetNet: A dynamic electronic model deciphering the metabolic profiling of human embryonic stem cells (hESCs) and its applications. RECOMB 2020, Italy (Jun 2020). ### Profiles - ORCID: https://orcid.org/0000-0003-4190-7058 - ResearchGate: https://www.researchgate.net/profile/Samuel-Bharti - Google Scholar: https://scholar.google.co.in/citations?user=GT1IKEoAAAAJ&hl=en ## Experience ### Work - **Software Engineering Intern**, Posit (May to Aug 2026): On the Shiny team in Posit's Open Source group. Built more than ten apps and four packages across R, Python, and JavaScript, mostly for computational biology and bioinformatics, and contributed to Shiny and shinyreact. - **Human Genetics gRED Intern**, Genentech, South San Francisco (Jun to Aug 2025): Built a Shiny platform and R package for locus-centered visualization across 11,000+ GWAS, eQTL, pQTL, single-cell, and ATAC-seq datasets in Alzheimer's disease. Worked with scientists and engineers to fit it into secure internal systems and presented it to the Human Genetics department. - **Graduate Research Assistant**, Center for Genomics and Data Science, UAB (Aug 2022 to present): Single-nuclei and multi-omics analysis of NF1-associated tumor models to find testable hypotheses for drug repurposing. Caught and validated sample contamination in 3′ datasets with 10x Genomics, and built and deployed 5+ Shiny apps on UAB infrastructure for visualization, sample tracking, and multi-omics exploration. - **Business Development Fellow**, Bill L. Harbert Institute for Innovation & Entrepreneurship (HIIE), UAB (Dec 2023 to present): Assessed the commercial potential of 12 UAB technologies and prepared licensing materials. Automated internal workflows with Power Automate and the Microsoft Graph API. - **Chief Technical Officer**, FundU Games Pvt. Ltd., Delhi (2021 to 2022): Led an 8-person team building a FinTech product with React, Node.js, R Shiny, MongoDB, and Docker. Ran the AWS setup and helped secure initial funding. - **Bioinformatics Engineer**, STEM-Away (Jun 2021 to Aug 2022): Mentored international student teams and developed bioinformatics course materials and app templates. ### Education - **Ph.D., Biomedical Engineering & Bioinformatics**, University of Alabama at Birmingham (undefined) - **Certificate, Translation of Biomedical Innovation to Clinical Practice**, University of Alabama at Birmingham (undefined) ### Teaching - **Certified Instructor**: The Carpentries (2024 to present). Taught workshops on R, Git, Bash, and Python at UAB's Biological Data Science Core. - **President**: Informatics Club, UAB (2023 to 2025). Grew computational training across departments through workshops, peer-learning sessions, and professional-development seminars. - **Mentor**: STEM-Away. Gave a talk and live demo on containerized bioinformatics and deploying R Shiny apps on AWS. ### Honors - Google Cloud Research Credit Award, Google (2026) - Elected Member, Tau Beta Pi Engineering Honor Society, UAB (2025) - Student Member, American Association for Cancer Research (AACR) (2024 to present) - Blazer Graduate Research Fellowship, UAB (2022 to 2023) - Professional Development & Travel Awards, UAB CCTS & UAB GSG (2022 to 2024) ## Skills - **Programming & scripting:** R, Python, Bash, SQL, TypeScript, JavaScript, PHP, Git/GitHub - **Data products & publishing:** R Shiny, Quarto, Streamlit, Jupyter, ggplot2, Plotly, D3, Leaflet, interactive reporting - **Bioinformatics & multi-omics:** single-cell & spatial transcriptomics, bulk RNA-seq, variant & clinical analysis, multi-omics integration, quality control, Seurat, DESeq2, CellChat, Bioconductor, nf-core / Nextflow - **Workflows & infrastructure:** reproducible workflows, modular development, workflow automation, Docker, REST APIs, Posit publishing, AWS, GCP, HPC / SLURM - **Agentic AI & ML:** agent systems, tool calling, MCP, A2A, Google ADK, OpenAI APIs, LangChain, LLM apps, Neo4j knowledge graphs, machine learning, network analysis ### Certifications - Certified Instructor, The Carpentries (2024 to present) - EMBL-EBI: Cancer Genomics and Transcriptomics (32 hours, May 2025) - EMBL-EBI: Single-cell RNA-seq Analysis with Python (35 hours, Feb 2025) - NVIDIA: Fundamentals of Deep Learning https://courses.nvidia.com/certificates/7b5d4994cec04eaeb6cdf3fe41192807/ ## Writing ### R Shiny Template v2.0 *2026-05-02 · R Shiny, Packages* · https://www.samuelbharti.com/posts/r-shiny-template-v2-0/ A reproducible and container-ready R Shiny template with renv, Docker, and Zenodo citation support. TLDR; Version 2.0 adds reproducibility, container support, and citation metadata to the original R Shiny template. The goal is to make it easier to start new apps with a structure that stays clean as the project grows. ## What's New in v2.0 The template now includes: 1. **renv for reproducibility** - Lock package versions and restore the same R environment on another machine. 2. **Docker support** - Build and run the app in a container for more consistent deployment. 3. **Zenodo citation metadata** - Include `CITATION.cff` and `CITATION.md` so the project is easier to cite. 4. **Development helper** - Use `dev/init-renv.R` to initialize `renv` and create `renv.lock`. ## Why Use a Modern Shiny Template? If you've ever started a Shiny app from scratch, you know how quickly the code can become hard to manage. A template gives you a clean starting point and keeps the app organized into separate pieces as it grows. This version is built to be: 1. **Reproducible** - `renv` locks package versions. 2. **Containerized** - Docker keeps development and deployment closer together. 3. **Maintainable** - Modules and page-level UI files keep the codebase tidy. 4. **Citable** - Zenodo metadata makes the project easier to reference in research. ## The Structure of the Template ``` text . ├── global.R ├── ui.R ├── server.R ├── R/ ├── modules/ ├── userInterface/ ├── data/ ├── dev/ │ └── init-renv.R ├── www/ ├── docs/ ├── Dockerfile ├── renv.lock ├── CITATION.cff ├── CITATION.md ├── .gitattributes ├── .dockerignore └── .Rbuildignore ``` ## Key Components ### 1. Global separation: `ui.R`, `server.R`, and `global.R` Instead of putting everything into one `app.R` file, the template separates the app into smaller files. That makes the project easier to read, debug, and extend. ### 2. Modularization: the `modules/` folder Each module keeps its UI and server logic together, which makes pieces of the app reusable across projects. ### 3. Automation: the `R/` folder Files in `R/` are sourced automatically, which is a simple place for utility functions and shared helpers. ### 4. Development space: the `dev/` folder The `dev/init-renv.R` script helps initialize `renv`, install recommended packages, and create `renv.lock` for a new project. ### 5. User interface files: the `userInterface/` folder Split page-level UI into separate files so the main `ui.R` file stays manageable. ### 6. Static assets: the `www/` folder Use `www/` for CSS, JavaScript, and images. Shiny serves these files automatically. ### 7. Data management: the `data/` folder Keep datasets separate from code so the app stays easier to maintain. ### 8. Reproducibility: `renv.lock` When `renv.lock` is present, other users can restore the same package versions with `renv::restore()`. ### 9. Docker support The `Dockerfile` is set up to work with `renv`, so the app can be built and run consistently in a container. ### 10. Citation metadata The repository includes `CITATION.cff` and `CITATION.md`, and the Zenodo badge links to the release DOI for version 2.0. ## How to Use the Template 1. Click **Use this template** on the repository page. 2. Clone your new repo. 3. Run `source("dev/init-renv.R")` to initialize `renv`. 4. Add UI files to `userInterface/`, modules to `modules/`, helpers to `R/`, and data to `data/`. 5. Update `CITATION.cff` and `CITATION.md` if you publish a Zenodo release. 6. Build the app with Docker when you are ready to deploy. ## How to Cite This Template [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.19968600.svg)](https://doi.org/10.5281/zenodo.19968600) If you use this template or a derivative in your research or project, please cite it: **APA:** ``` text Bharti, S. (2026). RShiny Template (version 2.0) [Software]. Zenodo. https://doi.org/10.5281/zenodo.19968600 ``` **BibTeX:** ``` bibtex @software{rshiny_template_2026, author = {Bharti, Samuel}, title = {RShiny Template}, version = {2.0}, date = {2026-05-02}, doi = {10.5281/zenodo.19968600}, url = {https://doi.org/10.5281/zenodo.19968600} } ``` By using this template, I hope developing Shiny apps becomes a smoother process and that your work is easier to reproduce and cite. **Happy coding!** --- ### R Shiny Template *2024-09-25 · R Shiny, Packages* · https://www.samuelbharti.com/posts/r-shiny-template/ Here's why you need a template for your next R Shiny app. TLDR; Are you ready to dive into Shiny app development but looking for a clean, scalable foundation to start with? I've created an R Shiny template on GitHub designed to make it easier to develop complex applications, especially in computational biology and bioinformatics. This blog post will walk you through the structure of the template and explain why it's a great starting point for your next Shiny project. ## Why Use a Shiny Template? If you've ever built a Shiny app from scratch, you know how quickly things can get messy as your app grows. A well-structured template can save you a lot of time and headaches. Modularizing your code helps with scaling, makes debugging easier, and encourages cleaner, more maintainable projects. ## The Structure of the Template Here's what you'll find inside the template repository: ``` R/ data/ dev/ modules/ userInterface/ www/ .Renviron .gitignore Dockerfile global.R server.R ui.R ``` ## Key Components ### 1. **Global Separation: `ui.R`, `server.R`, and `global.R`** Instead of the typical `app.R` file that bundles everything together, this template separates the user interface (`ui.R`), server logic (`server.R`), and global settings (`global.R`). This makes it more scalable, especially for large applications with multiple pages or components. Why is this better? Well, separating these files allows you to quickly pinpoint and debug specific sections of your app without scrolling through a huge chunk of code. This also enables easier collaboration if you're working in a team, as different members can focus on different parts of the app. ### 2. **Modularization: The `modules/` Folder** Modularizing your app is the best way to keep things organized as your app grows. Each module acts as a self-contained block of functionality that can be easily reused or modified. By putting the code for each Shiny module into its own file and then sourcing it in `server.R`, you can keep your app's logic clean and modular. For example, if you have a plotting module, you can isolate all the related code in one file. This makes debugging and updating a breeze since you only have to focus on that one module without impacting other parts of the app. ### 3. **Automation: The `R/` Folder** Any file placed inside the `R/` folder is automatically sourced when the app runs, saving you the hassle of manually sourcing each file. This folder is perfect for utility functions, custom R scripts, or any global variables that the app relies on. ### 4. **Development Space: The `dev/` Folder** The `dev/` folder is your sandbox for testing out new features or snippets of code. During development, you can use this space to isolate and experiment with different blocks of code without affecting the rest of the app. When you're ready to deploy, this folder is excluded via `.gitignore`. ### 5. **User Interface Files: The `userInterface/` Folder** It's easy to end up with a huge, unmanageable `ui.R` file, especially for complex applications with multiple pages or tabs. To avoid that, this template lets you split up your UI code by components or pages, which can be stored in the `userInterface/` folder. Then, you can call these components inside `ui.R`, keeping your UI modular and easier to debug. ### 6. **Static Assets: The `www/` Folder** This folder stores static files like CSS, JavaScript, and images, which your Shiny app can access. It helps keep your app visually appealing while offering space to customize with your own design, animations, or external libraries. ### 7. **Data Management: The `data/` Folder** This folder is where you store any datasets that your app uses. Keeping data separate from your codebase helps maintain clarity and lets you easily update the data without modifying your core code. ### 8. **Environment Variables: The `.Renviron` File** Sensitive information, like API keys or database credentials, should never be hardcoded in your scripts. This template uses the `.Renviron` file to securely store keys and load them into your environment when the app starts, keeping your secrets safe and your codebase clean. ### 9. **Docker Support** This template comes with a `Dockerfile`, enabling easy deployment and making sure your app works consistently across different environments. Dockerization is an important part of modern software development, ensuring your app can be deployed anywhere without issues related to dependencies or versioning. ## Benefits of a Modular, Scalable Approach 1. **Easier Debugging:** When your code is modularized, you can isolate issues faster. Instead of scrolling through a massive `server.R` or `ui.R` file, you can head straight to the module that's causing trouble. 2. **Reusable Code:** Once you build a module, you can reuse it across multiple apps. This is especially useful for common components like input forms or data visualizations. 3. **Cleaner Project Structure:** A clean, organized folder structure makes your project easier to understand and maintain. Whether you're working alone or in a team, a well-structured app is easier to expand and troubleshoot. 4. **Scalability:** As your app grows, the separation of concerns (UI, server, global settings) and the use of modules will keep your app manageable. No need to refactor everything as you scale up! ## How to Use the Template 1. **Use this Template:** Get started by clicking on "Use this template" button on the [repository page](https://github.com/samuelbharti/RShiny_template) and create a new repository. 2. **Clone the Repo:** Clone your newly created repository from GitHub. 3. **Add Your Code:** Begin by adding your UI components to the `userInterface/` folder, your server logic to `modules/`, and any global settings or datasets to their respective folders. 4. **Dockerize and Deploy:** Once you're done developing, use the included `Dockerfile` to package and deploy your app to any environment. ## Contributions and Feedback I'm always open to contributions, feedback, or feature requests! If you have any ideas to improve the template or run into issues, feel free to open an issue or a pull request on GitHub. By using this template, I hope you'll find that developing Shiny apps becomes a smoother, more enjoyable process. Happy coding! --- ### Introduction to GlucoKinaseDB *2023-05-10 · Bioinformatics* · https://www.samuelbharti.com/posts/intro-to-gkdb/ A Centralized Resource for Diabetes Drug Target Information Glucokinase (GK) is a glucose sensor in the liver and pancreas, central to regulating blood sugar. That makes it an important drug target, particularly for type 2 diabetes. The catch is that information about GK modulators (activators, inhibitors, and compounds that disrupt GK's interaction with its regulatory protein, GKRP) is scattered across scientific literature, patents, and chemical databases. So our research team built GlucoKinaseDB (GKDB): a manually curated database dedicated to glucokinase modulators. ## What GKDB Offers - Centralized, Curated Data: GKDB houses structural and bioactivity information for over 1700 experimentally validated GK modulators, including GK activators (GKAs), GK inhibitors (GKIs), and GK-GKRP disruptors, gathered from publications, patents, and chemical repositories. - User-Friendly Interface & Tools: We designed GKDB with the researcher in mind: - Advanced search options for finding specific compounds. Interactive tables for easy data sorting and viewing. - In-browser 3D visualization of molecular structures. - Downloadable data (structures, bioactivity, descriptors) in multiple formats. - Direct links to original references and major external databases (e.g., PubChem, ChEMBL). - An API for computational access to the data. ![An example of a modulator page on GlucoKinaseDB](./gkdb-peptide-page.png) ## Broadening the Scope: Applications of GKDB While GKDB's primary aim is to accelerate research on GK-targeted diabetes therapies, its curated dataset supports a wider range of applications: - **Drug Discovery & Design:** Aids in developing pharmacophore models and QSAR/QSPR studies to understand structure-activity relationships. - **Computational Biology & Machine Learning:** Provides high-quality, structured data suitable for training predictive models related to drug efficacy or properties. - **Drug Repurposing:** Consolidating data on known modulators can help identify compounds with potential for new therapeutic uses. - **Targeting Specific Mechanisms:** The inclusion of GK-GKRP disruptor data supports research into more targeted therapies, potentially hepatocyte-specific activation to avoid side effects like hypoglycemia associated with some GKAs. - **Experimental Research Support:** Provides easy access to information on compounds like GKAs used in laboratory studies investigating glucose sensing and hormone release. ## Explore GKDB - **Visit the database:** - **Access data via the API:** - **Read our publication:** Yadav, Bharti, Mathur (2023). *Comp Biol Chem*. ## Our Collaborative Effort & My Role Creating GKDB was a collaborative project, integrating expertise in biochemistry, data curation, and software development. While the team curated the data and provided biological insights, my specific contribution focused on the technical development. I designed and built the web platform using PHP, HTML, CSS, and JavaScript, set up and managed the MySQL database, and integrated essential interactive tools like 3Dmol.js for visualization and DataTables for structuring information. A key feature I implemented was the PHP-based API, enabling programmatic access for researchers using tools like Python or R. We hope GKDB is useful to anyone working on glucokinase, at the bench or in silico. ## References Moede, T., Leibiger, B., Vaca Sanchez, P. *et al.* Glucokinase intrinsically regulates glucose sensing and glucagon secretion in pancreatic alpha cells. *Sci Rep* **10**, 20145 (2020). Choi JM, Seo MH, Kyeong HH, Kim E, Kim HS. Molecular basis for the role of glucokinase regulatory protein as the allosteric switch for glucokinase. *Proc Natl Acad Sci U S A*. 2013;110(25):10171-10176. doi:[10.1073/pnas.1300457110](https://doi.org/10.1073/pnas.1300457110) --- ### Introduction to SEAS *2022-11-06 · Bioinformatics, R Shiny* · https://www.samuelbharti.com/posts/intro-to-seas/ Understanding your sample subsets: an introduction to SEAS Have you ever examined a specific group of samples, such as patients with a particular treatment response or cells exhibiting unique behaviors, and wondered what clinical or experimental details make them distinct? Identifying which characteristics are truly enriched or over-represented in that subset compared to the entire dataset can be surprisingly complex. This challenge is common when working with high-dimensional biomedical data. That's where SEAS (Statistical Enrichment Analysis of Samples) comes into play. SEAS is an interactive online tool designed for this purpose: to help you explore the clinical attributes (or "clinotypes," such as age group, treatment status, or survival days) within your sample cohort and identify which ones are significantly over-represented compared to your overall dataset. It is useful whether you're balancing case-control groups for a study or just trying to understand a specific sample subset better. Existing tools often struggled to integrate different data types or to identify similar samples automatically. ![A graphical summarization of SEAS for TCGA-GBM case study.](./SEAS_illustration_highRes.png) ## What SEAS Does - Identifies statistically enriched clinical features (clinotypes) in a user-defined sample subset. - Works with both categorical (e.g., gender, treatment type) and numerical data (e.g., age, survival time). - Provides visualizations to explore clinical features (like density plots, survival plots) and sample relationships (embedding plots). - Can help quantify and visualize similarities between patients or samples. - Supports automatic clustering to help identify meaningful subcohorts. ## My Role I developed SEAS as my undergraduate thesis project. My work involved building the tool itself and implementing various interactive components, including visualizations for exploring clinical data distribution, survival analysis, and sample embeddings, along with methods for interactive cohort selection. ## How You Can Use It 1. Upload your clinical metadata table. 2. Upload your sample embedding (generated from gene expression or similar matrices). 3. Explore relationships among sample clinotypes (features). 4. Define your sample subset of interest (you can select manually, or SEAS can help identify clusters). 5. SEAS performs Clinical Feature Enrichment Analysis (CFEA) and reports the features significantly enriched in your subset, complete with statistical measures. ![A workflow diagram of SEAS.](./SEAS_workflow_latest.png) ## Check it Out - Try the live SEAS tool here: - Find more info and documentation here: ## References Nguyen, T. M., Bharti, S., Yue, Z., Willey, C. D., & Chen, J. Y. (2021). Statistical Enrichment Analysis of Samples: A General-Purpose Tool to Annotate Metadata Neighborhoods of Biological Samples. *Frontiers in big data*, *4*, 725276. Nguyen, T. M., Bharti, S., Yue, Z., Willey, C. D., & Chen, J. Y. (2021). Corrigendum: Statistical Enrichment Analysis of Samples: A General-Purpose Tool to Annotate Metadata Neighborhoods of Biological Samples. *Frontiers in big data*, *4*, 804141. --- ### Introduction to PepEngine *2022-04-12 · Bioinformatics* · https://www.samuelbharti.com/posts/intro-to-pepengine/ A database of synthetic peptides with the non-standard amino acids Synthetic peptides are versatile molecules, used in everything from drug development to materials science. Some of the most interesting ones incorporate non-standard amino acids, like α,β-Dehydrophenylalanine (ΔPhe or ΔF) and α-Aminoisobutyric acid (Aib). These unusual building blocks strongly influence peptide structure, often inducing stable helical conformations or specific turns. Understanding those 3D structures matters for designing new peptides with desired functions, but consolidated structural information for peptides containing ΔF and Aib is hard to find. To address this, our team developed PepEngine, a specialized, manually curated database focused exclusively on the structural details of synthetic peptides containing ΔF and Aib. ## What PepEngine Provides - Focused Structural Data: Contains detailed structural information (including 3D coordinates) for synthetic peptides incorporating ΔF and/or Aib. - Manual Curation: Data is carefully gathered and verified from scientific literature, ensuring quality and relevance. - Interactive Exploration: In-browser 3D visualization of peptide structures using 3Dmol.js. - Organized data presentation using interactive tables (DataTables). - Easy access to source publication details. - Downloadable structural files (e.g., PDB format) for offline analysis and modeling. ![Pepengine browse page](./pepengine-browse-data.png) ## Explore the Structures - Visit the PepEngine database: - Read our publication: Yadav, Bharti, Srivastava & Mathur (2022). Int J Pept Res Ther. We hope PepEngine makes working with these peptides a little easier. ## Our Collaborative Effort & My Role PepEngine was a team effort across peptide chemistry, structural biology, and bioinformatics. While the team focused on identifying relevant peptides and curating the structural data from literature, my role centered on the technical implementation of the database and web interface. I developed the platform using HTML, PHP, CSS, and JavaScript, managed the underlying MySQL database, and integrated the key visualization components like 3Dmol.js and the interactive DataTable library to ensure the structural data was easily accessible and explorable. --- ### Enrichment analysis and annotation using PAGER *2022-04-06 · Bioinformatics, R Shiny* · https://www.samuelbharti.com/posts/intro-to-pager/ A database of annotations to enrich gene lists or identify cell types. High-throughput experiments, such as RNA-seq and microarray studies, often produce extensive lists of genes. Identifying the genes is the easy part; the real challenge is interpreting what they mean together. Which pathways are they associated with? What biological processes or cell types do they represent? Manually searching databases for this is slow. To make that interpretation faster, our research group developed PAGER (Pathways, Annotated lists, and Gene-sets Electronic Repository). PAGER serves as a knowledge base containing thousands of "PAGs": curated sets of genes that represent pathways, annotated lists from publications, protein complexes, cancer signatures, and more. It allows researchers to conduct enrichment analysis by asking: "Are any specific PAGs overrepresented in my gene list?" This analysis surfaces the biological themes hidden in the data. PAGER is useful for pathway analysis and for annotating cell types in single-cell datasets. ## Improving Accessibility: The PAGER Web App The PAGER database and analysis methods are the core; we wanted running the analyses to be simpler and more interactive. That led to the PAGER Web App, an R Shiny application with a graphical interface to: - Upload user-defined gene lists. - Perform PAGER enrichment analysis using various settings. - Explore results through interactive tables and visualizations. - Work with pre-loaded case studies for learning or comparison. ## Why Use PAGER (via the Web App)? PAGER, especially through the web app, gets you from a raw gene list to interpretable biology quickly: relevant pathways, gene signatures, or potential cell type markers, without the manual database crawl. ## Explore PAGER - Access the main PAGER database & tool: - Find the PAGER Web App code on GitHub: - Read our publication on the Web App: Yue, Slominski, Bharti, Chen (2022). Frontiers in Genetics. We hope these tools help researchers interpret their functional genomics data. ## Our Team's Work & My Contributions The PAGER ecosystem is a lab-wide effort. My contributions focused on the user experience and data visualization: On the main PAGER platform: I worked on adding interactive summary visualizations for the analysis results, implementing bar plots and scatter plots using the Plotly library, and incorporating network visualizations using D3.js to help users explore the relationships within larger gene sets. For the PAGER Web App: I was involved in developing the R Shiny application itself, building the interface that allows users to run PAGER analyses more coherently and interactively without needing extensive programming knowledge. --- ### Microarray analysis for non-coders using sMAP *2022-02-20 · Bioinformatics, R Shiny* · https://www.samuelbharti.com/posts/intro-to-smap/ An R Shiny application enabling researchers to analyze microarray datasets. RNA sequencing now dominates transcriptomics, but microarrays were its backbone for years, and a huge amount of valuable data was generated with them. They still have their uses. Analyzing that data, legacy or new, usually takes bioinformatics expertise and coding skills that many bench scientists, students, and researchers do not have. How can we make these analyses more accessible? That question led to sMAP (Standard Microarray Analysis Pipeline), an educational project developed during my internship with STEM-Away. The goal was to build an interactive R Shiny tool that guides people without coding experience through a complete microarray analysis workflow: loading raw data files, exploring differentially expressed genes, and visualizing results. ## Building sMAP: A Global Collaboration sMAP was built by a team of more than 40 international participants: high school students, university students, and junior professionals. Together we brainstormed, designed, coded, and tested the application. The project was as much about giving everyone real, hands-on software development experience as it was about the tool itself. ## My Role in Our Team Effort My role was to steer the technical development of the R Shiny application. This involved guiding the group in translating standard microarray analysis steps (like data normalization, quality control, differential expression analysis using limma, and various plotting methods) into an intuitive web interface. It also meant coordinating the diverse contributions from team members across different time zones and ensuring we collectively moved towards our shared goal. ## Why sMAP Mattered (and Still Does Conceptually) Tools like sMAP aim to lower the barrier to entry for biological data analysis. By wrapping complex command-line procedures in a graphical interface, the project sought to: - Empower Non-Coders: Enable researchers and students to analyze microarray data confidently without needing to write R code. - Educate: Act as an interactive guide, helping users understand the workflow and principles behind microarray analysis. - Promote Accessibility: Make essential bioinformatics techniques more readily available to the broader life sciences community working with this important data type. ![Overview of the sMAP interface and pipeline steps](./smap-overview.png) ## Project Resources While the hosted instance of the app might not be active anymore, the project remains a good example of collaborative tool-building: - Learn more about the project: - Explore the code on GitHub: - Read our preprint: Bharti, Krishnan, Veyssi, Momeni, Raj (2022). bioRxiv. sMAP taught me a lot about teamwork, and about how much demand there is for tools that make complex analysis accessible. --- ### Deploy your Shiny App on AWS *2021-11-21 · R Shiny, Tutorials* · https://www.samuelbharti.com/posts/aws-r-shiny-deploy/ Learn how to deploy your R shiny app on AWS instance. TLDR; --- ### Introduction to Vitiligo Information Resource (VIRdb 2.0) *2021-10-06 · Bioinformatics* · https://www.samuelbharti.com/posts/intro-to-virdb/ A database for vitiligo biomarkers and its comorbidities. Vitiligo is a complex skin disorder characterized by the loss of pigment-producing cells. Understanding the mechanisms behind this condition requires synthesizing information from various sources, including gene expression changes, relevant protein targets, potential therapeutic compounds, and the intricate networks that connect them. Researchers often find this data scattered, making it challenging to gain a holistic view and expedite discoveries. Additionally, understanding the interactions between vitiligo and other health conditions (comorbidities) adds another layer of complexity. To address these challenges, our research team developed VIRdb 2.0, an interactive resource that integrates diverse datasets relevant to vitiligo pathogenesis in one place. ![Animated tour of the VIRdb 2.0 data contents](/posts/intro-to-virdb/virdb2-contents.gif) ## What VIRdb 2.0 Offered - **Integrated Data:** Brought together information on differentially expressed genes (DEGs) in vitiligo, curated protein targets, and natural compounds with potential relevance. - **Network Analysis:** Featured gene-gene and protein-protein network visualizations derived from our analyses, helping researchers explore biological interactions. - **Comorbidity Focus:** Specifically designed to support the interactive analysis of conditions often associated with vitiligo, using co-expression network approaches. - **Interactive Exploration:** Allowed users to dynamically explore the data tables and network graphs. ![Animated overview of the VIRdb 2.0 interface](/posts/intro-to-virdb/virdb2-overview.gif) ## Why VIRdb 2.0 Was Created The goal was to give researchers: - A centralized hub for diverse vitiligo-related data. - An easier way to spot potential therapeutic targets and pathways. - Interactive exploration of the biological networks and comorbidities associated with vitiligo. ## Accessing VIRdb 2.0 Resources - **Database Link:** - **Read our publication:** Srivastava, Talwar, Yadav, Choudhary, Mohanty, Bharti, Narad, & Sengupta (2021). *F1000Research*. Although the live database may currently be unavailable, the publication details the findings and approach. ## A Collaborative Development & My Role VIRdb 2.0 was a team effort across vitiligo biology, bioinformatics analysis, data curation, and web development. While the team worked on data generation, analysis, and curation, my contribution focused on visualization, particularly the interactive network graphs. I used D3.js to build dynamic, explorable views of the gene and protein interaction networks identified by our team's analysis. ---