Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>NMTRANNew to Visual Studio Code? Get it now.
NMTRAN

NMTRAN

Viktor Rognås

|
658 installs
| (1) | Free
| Sponsor
Language extension for NMTRAN (NONMEM) files
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

NMTRAN (NONMEM) Language Extension for VSCode NMTRAN Logo

GitHub Workflow Status Visual Studio Marketplace Downloads GitHub License

[!NOTE] This extension is currently in active development. While stable for daily use, expect occasional breaking changes. Please report any issues to help improve the extension.

Comprehensive language support for NMTRAN (NONMEM Translator) files in Visual Studio Code. Provides intelligent features for pharmacometric modeling with NONMEM control streams.

What is NMTRAN?

NMTRAN is the control language for NONMEM, the gold standard software for population pharmacokinetic/pharmacodynamic (PopPK/PD) modeling in pharmaceutical research. NMTRAN files (.mod, .ctl) define models for analyzing time-varying dose-concentration and exposure-response relationships.

Installation

The NMTRAN extension is available for VSCode and VSCode-based editors, including Positron.

Install via Extensions View:

  • Open your code editor
  • Make sure you have the latest version of the editor (requirement VSCode v1.102.0+)
  • Open the Extensions View
  • Search for NMTRAN or nonmem
  • Click "Install" on the NMTRAN extension by vrognas

[!TIP] For an enhanced NMTRAN development experience, consider installing ErrorLens. It makes diagnostics stand out more prominently, highlighting the entire line wherever a diagnostic is generated and printing the message inline. Perfect for spotting NMTRAN validation errors at a glance.

Quick start

Once installed, open any NMTRAN file (.mod, .ctl) to automatically activate the extension:

Try these features:

  • Hover over THETA/ETA/EPS to see definitions; control records to see explanations.
  • Right-click on THETA(1) → "Peek" → "Peek References"
  • Notice real-time error highlighting for invalid syntax

Features

🧠 Language intelligence

  • Real-time diagnostics: Validation of control records, parameter sequences, and NMTRAN syntax
  • Intelligent hover: Explanations for control records, parameters, and NONMEM functions
  • Go to Definition: Navigate from parameter usage (THETA(1)) to declaration ($THETA)
  • Find All References: Locate all usages of parameters throughout your model

Hover peek demo

✨ Code enhancement

  • Syntax highlighting: Rich tokenization following TextMate conventions
  • Code folding: Collapse control records for better file navigation
  • Smart formatting: Configurable indentation and code organization
  • Comment toggling: Quick comment/uncomment with standard VSCode commands

Syntax highlighting demo

📝 Code snippets

Comprehensive snippet library for rapid model development:

Snippet demo

Available snippets:

  • Subroutines: ADVAN/TRANS combinations for PK modeling
  • Data handling: $DATA record templates with common options
  • Error models: Additive, proportional, and combined residual error models
  • Tables: Xpose-friendly $TABLE configurations
  • Mixture models: 2-way and 3-way mixture model templates
  • Special modeling:
    • Logit-normal IIV for bounded parameters
    • Baseline models (B1--B4) Dansirikul et al., 2008
    • BQL handling (M3 method) Beal, 2001

Supported file types

The extension activates for these NONMEM-related file extensions:

  • Control streams: .mod, .ctl, .modt
  • Output files: .lst, .ext, .cov, .cor, .coi, .cnv
  • Special files: .phi, .scm, .grd, .shk, .shm, .smt, .rmt, .phm

Community & support

  • Documentation: NMTRAN Reference
  • Issues & Feature Requests: GitHub Issues
  • Discussions: GitHub Discussions
  • Contributing: See CONTRIBUTING.md
  • Sponsor: Buy me a coffee ☕

Contributing

Whether you're fixing bugs, adding features, or improving documentation, your help makes this extension better for the pharmacometrics community.

  • 🐛 Bug reports: GitHub Issues
  • 💡 Feature requests: GitHub Discussions
  • 🔧 Pull requests: See CONTRIBUTING.md for guidelines
  • 📖 Documentation: Help improve our docs and examples

License

MIT License - feel free to use this extension in your research and commercial projects.


Enjoy enhanced NMTRAN development! 🧬💊

Made with ❤️ for the pharmacometrics community

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft