주요 콘텐츠

Molecule Viewer

R2026b

Display and manipulate 3-D molecule structure

Since R2026b

Description

The Molecule Viewer app lets you display and manipulate 3-D molecular structures using an embedded version of the Mol* viewer [1].

You can:

  • Import structural information directly from the Protein Data Bank (PDB) database or other supported files (PDB, mmCIF, MOL, SDF, XYZ, MOL2, GRO).

  • Select different visualization and color schemes to display a molecule, such as cartoon, ball-and-stick, spacefill, ribbon, surface, or line representations.

  • Interactively rotate, zoom, and pan the 3-D molecular structure.

  • Select and highlight specific atoms, residues, or chains. For details, see https://molstar.org/viewer-docs/.

Molecule Viewer app

Open the Molecule Viewer App

  • MATLAB® Toolstrip: On the Apps tab, under Computational Biology, click the app icon.

  • MATLAB command prompt: Enter molviewer.

Examples

expand all

View 3-D molecular structures in Molecule Viewer by using the corresponding PDB information.

Open the H5N1 influenza virus hemagglutinin molecule in Molecule Viewer by specifying the PDB URL.

molviewer("https://files.rcsb.org/download/2FK0.pdb");

View another molecule by specifying its corresponding PDB identifier. A new instance of Molecular Viewer opens.

molviewer("2DHB");

Use the getpdb function to retrieve protein structure data from the PDB database and create a structure. Then view the protein molecule.

pdbstruct = getpdb('1vqx');
molviewer(pdbstruct);

Programmatic Use

molviewer opens the Molecule Viewer app.

molviewer(file) reads the structural information from file and shows the 3-D molecular structure in the Molecule Viewer app.

The file input argument can be a character vector or string scalar specifying one of the following:

  • File name of a file on the MATLAB search path or in the MATLAB current folder

  • Path and file name

  • URL pointing to a file (URL must begin with a protocol such as http://, ftp://, or file://)

The referenced file is a molecule model file, such as a Protein Data Bank (PDB)-formatted file (ASCII text file). Valid file types include:

  • PDB

  • mmCIF

  • MOL (MDL)

  • SDF

  • XYZ

  • MOL2

  • GRO

molviewer(pdbID) retrieves the structural data for a protein from the PDB database using its pdbID and shows the 3-D molecular structure in Molecule Viewer.

pdbID can be a unique identifier for a protein structure record in the PDB database specified as a character vector or string scalar.

Each structure in the PDB database is represented by a four-character alphanumeric identifier. For example, 4hhb is the identifier for hemoglobin.

molviewer(pdbStruct) reads the data from pdbStruct, a structure containing a field for each PDB record, and displays the 3-D molecular structure in Molecule Viewer.

You can use getpdb or pdbread function to get such a PDB structure.

References

[1] Sehnal, David, et al. “Mol* Viewer: Modern Web App for 3D Visualization and Analysis of Large Biomolecular Structures.” Nucleic Acids Research, vol. 49, no. W1, July 2021, pp. W431–37. DOI.org (Crossref), https://doi.org/10.1093/nar/gkab314.

Version History

Introduced in R2026b