GMX-ANGLE(1)

✨ gmx-angle ✨

okay bestie, buckle up, it's the gmx angle page and we're gonna make it make sense πŸ’– this one lives in the GROMACS manual, it's manual page gmx-angle (section 1), and honestly? it's a whole vibe. angles, dihedrals, correlation functions, the works. let's go πŸ¦‹


🌸 SYNOPSIS 🌸

gmx angle [-f [<.xtc/.trr/...>]] [-n [<.ndx>]] [-od [<.xvg>]]
          [-ov [<.xvg>]] [-of [<.xvg>]] [-ot [<.xvg>]] [-oh [<.xvg>]]
          [-oc [<.xvg>]] [-or [<.trr>]] [-b <time>] [-e <time>]
          [-dt <time>] [-[no]w] [-xvg <enum>] [-type <enum>]
          [-[no]all] [-binwidth <real>] [-[no]periodic]
          [-[no]chandler] [-[no]avercorr] [-acflen <int>]
          [-[no]normalize] [-P <enum>] [-fitfn <enum>]
          [-beginfit <real>] [-endfit <real>]

πŸ‘‘ DESCRIPTION πŸ‘‘

so gmx angle computes the angle distribution for a bunch of angles or dihedrals. that's the whole job, and it does it beautifully.

with the -ov option, you can plot the average angle of a group of angles as a function of time, like a little glow-up montage over your trajectory πŸ“ˆ. and with the -all option? the first graph is the average, and the rest are the individual angles β€” everyone gets their moment πŸ’….

with the -of option, gmx angle also calculates the fraction of trans dihedrals (only for ryckaert-bellemans dihedrals, okurrr) as a function of time. honestly this is probably only fun for a select few πŸ™ˆ but hey, niche hobbies are valid. an output file is only generated if -type ryckaert-bellemans is specified. periodt.

with option -oc, a dihedral correlation function is calculated. it's giving self-care for your rotamers ✨.

ok so this is the part you actually need to hear: the index file must contain atom triplets for angles or atom quadruplets for dihedrals. if this is not the case, the program will crash πŸ˜­πŸ’€ not a soft little oopsie, an actual crash. respect the triplets and quadruplets bestie.

with option -or, a trajectory file is dumped containing cos and sin of selected dihedral angles. and then? you can feed that straight into a principal components analysis using gmx covar. chef's kiss, no cap πŸ”₯.

option -ot plots when transitions occur between dihedral rotamers of multiplicity 3, and -oh records a histogram of the times between such transitions. this assumes the input trajectory frames are equally spaced in time, so like, don't lie to it about your timesteps. output files are only generated if -type dihedral is specified.


πŸ’… OPTIONS πŸ’…

πŸŽ€ Options to specify input files:

  • -f [<.xtc/.trr/...>] (traj.xtc) β€” Trajectory: xtc trr cpt gro g96 pdb tng h5md
  • -n [<.ndx>] (angle.ndx) β€” Index file

πŸŽ€ Options to specify output files:

  • -od [<.xvg>] (angdist.xvg) β€” xvgr/xmgr file
  • -ov [<.xvg>] (angaver.xvg) (Optional) β€” xvgr/xmgr file
  • -of [<.xvg>] (dihfrac.xvg) (Optional) β€” xvgr/xmgr file
  • -ot [<.xvg>] (dihtrans.xvg) (Optional) β€” xvgr/xmgr file
  • -oh [<.xvg>] (trhisto.xvg) (Optional) β€” xvgr/xmgr file
  • -oc [<.xvg>] (dihcorr.xvg) (Optional) β€” xvgr/xmgr file
  • -or [<.trr>] (traj.trr) (Optional) β€” Trajectory in portable xdr format

πŸŽ€ Other options:

  • -b <time> (0) β€” Time of first frame to read from trajectory (default unit ps)
  • -e <time> (0) β€” Time of last frame to read from trajectory (default unit ps)
  • -dt <time> (0) β€” Only use frame when t MOD dt = first time (default unit ps)
  • -[no]w (no) β€” View output .xvg, .xpm, .eps and .pdb files
  • -xvg <enum> (xmgrace) β€” xvg plot formatting: xmgrace, xmgr, none
  • -type <enum> (angle) β€” Type of angle to analyse: angle, dihedral, improper, ryckaert-bellemans
  • -[no]all (no) β€” Plot all angles separately in the averages file, in the order of appearance in the index file.
  • -binwidth <real> (1) β€” binwidth (degrees) for calculating the distribution
  • -[no]periodic (yes) β€” Print dihedral angles modulo 360 degrees
  • -[no]chandler (no) β€” Use Chandler correlation function (N[trans] = 1, N[gauche] = 0) rather than cosine correlation function. Trans is defined as phi < -60 or phi > 60.
  • -[no]avercorr (no) β€” Average the correlation functions for the individual angles/dihedrals
  • -acflen <int> (-1) β€” Length of the ACF, default is half the number of frames
  • -[no]normalize (yes) β€” Normalize ACF
  • -P <enum> (0) β€” Order of Legendre polynomial for ACF (0 indicates none): 0, 1, 2, 3
  • -fitfn <enum> (none) β€” Fit function: none, exp, aexp, exp_exp, exp5, exp7, exp9
  • -beginfit <real> (0) β€” Time where to begin the exponential fit of the correlation function
  • -endfit <real> (-1) β€” Time where to end the exponential fit of the correlation function, -1 is until the end

πŸ’€ KNOWN ISSUES πŸ’€

  • Counting transitions only works for dihedrals with multiplicity 3

(yes, only multiplicity 3. it's a whole thing. we don't make the rules 😭)


🌈 SEE ALSO 🌈

More information about GROMACS is available at <http://www.gromacs.org/>. 🫢


2026, GROMACS development team


and that's the tea, bestie 🧚 ok bye, go analyse some angles, you absolute icon πŸ‘‘

this was the gmx-angle page from GROMACS, version 2026.4, dated Oct 02, 2026. slay πŸ’œ

πŸ“¦ where this page comes from