Skip to content
Switch branches/tags
This branch is 138 commits ahead of benlyyan:master.
Fetch upstream

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Musical Gestures Toolbox for Matlab


The Musical Gestures Toolbox (MGT) is a Matlab toolbox for analysing music-related body motion, using sets of audio, video and motion capture data as source material.

It was primarily developed for music research, with a particular focus on studying the motion of musicians and dancers. But it can be used for any type of motion-related analysis based on video recordings.


The Musical Gestures Toolbox contains a set of functions for the analysis and visualization of video, audio, and mocap data. There are four categories of functions:

  • Data input and edit functions
  • Data preprocessing functions
  • Visualization functions
  • Middle and higher level feature extraction functions


Please refer to the wiki pages for more information about installing and usage. Much of the same information is also available in the material for the software carpentry workshop Quantitative Video analysis for Qualitative Research.


  1. Many of the basic things work with a standard Matlab install, but to use all features you will also need these extra Matlab packages:

    • Computer Vision System Toolbox
    • Image Processing Toolbox
  2. Some of the functions build on code from these third-party toolboxes:


The toolbox builds on the Musical Gestures Toolbox for Max, which has been developed by alexarje since 2004, and parts of it is currently embedded in the Jamoma project.

A large chunk of the code was written by benlyyan as part of his M.Sc. thesis at the University of Oslo.

There is now also a Musical Gestures Toolbox for Python with more or less the same functionality.

The software is maintained by the fourMs lab at RITMO Centre for Interdisciplinary Studies in Rhythm, Time and Motion at the University of Oslo.


If you use this toolbox for research purposes, please reference this publication:

  • Jensenius, Alexander Refsum (2018). The Musical Gestures Toolbox for Matlab. Proceedings of the 19th International Society for Music Information Retrieval Conference, Late Breaking Demos Session. Paris, France.

Many examples of the use of the toolbox can be found in this master's thesis:


Main developers: Alexander Refsum Jensenius, Bo Shou, and Habibur Rahman.


This software is open source, and is shared with The GNU General Public License v3.0.