Tutorial: Gait Profile Score and Movement Analysis Profile Pipeline
|Language:||English • français • italiano • português • español|
The gait profile score was originally published in the following paper:
Baker, R., McGinley, J.L., Schwartz, M.H., Beynon, S., Rozumalski, A., Graham, H.K., Tirosh, O. (2009). The gait profile score and movement analysis profile. Gait Posture, 30(3), 265–269. 
Another paper was published in 2012 was published to further clarify the equations used for the gait profile score:
Baker, R., McGinley, J. L., Schwartz, M., Thomason, P., Rodda, J., & Graham, H. K. (2012). The minimal clinically important difference for the Gait Profile Score. Gait Posture, 35(4), 612-615. 
Richard Baker further discusses the GPS and it's application on his blog, a link to this page can be found here.
The Gait Profile Score (GPS) is an clinical index that can be used to describe overall gait pathology. The GPS is the mean value of a number of discreet values obtained from kinematic variables measured during gait. "[...] the RMS difference between the patient's data and the average from the reference dataset taken over all relevant kinematic variables, for the entire gait cycle.[...]" 
These kinematic variables are:
- Pelvic Tilt*
- Pelvic Obliquity*
- Pelvic Rotation*
- Hip Flexion/Extension
- Hip Abduction/Adduction
- Hip Rotation
- Knee Flexion/extension
- Ankle Dorsiflexion/Plantarfexion
- Foot Progression
The GPS score can be computed for the left and/or the right side. It can also be computed as a overall index for both sides. *Since the pelvic movement is not specific to a any side, the authors recommend only including it when computing the GPS for the left side (as a convention). This means that for the left side, a total of 9 variables are used to compute the GPS, instead of only 6 for the right side. The overall GPS for both sides would therefore include all 9 variables.
Each kinematic variable should be normalized to the gait cycle. Data should be sampled every 2% of the gait cycle, so each signal should be normalized to 51 points.
These equations also match the equations Richard Baker made available in an Excel sheet which may be used to calculate the GPS .
The Global Variable Scores (GVS) is defined as:
The GVS is the root mean square difference between a specific time normalized gait variable (x) and the mean data from the reference population calculated across the gait cycle (x ref).
If normalizing to every 2% of the gait cycle, T is equal to 51.
The Gait Profile Score (GPS) is defined as:
The GPS is the root mean square average of the GVS variables.
If using 15 kinematic variables , N is equal to 15.
These equations can also be downloaded as a PDF here.
To calculate the GPS, a control database must be created (.vnd file) and a subject's CMO file must be created.
This tutorial describes step by step how to create a .vnd file and then create the GPS for a subject.
This tutorial uses the 15 kinematic variables used in Richard Baker's first paper; pelvic tilt, pelvic obliquity and pelvic rotation and hip flexion, hip abduction, hip internal rotation, knee flexion, ankle dorsiflexion and foot progression. 
Since the pelvis is common to the left and right sides, only the left side is used to calculate the pelvic angles (so the pelvis is only analyzed from left foot strike to left foot strike (LHS+LHS). 
The tutorial also calculates the GVS at every 2% of the gait cycle, so the signal is normalized to 51 points .
Step 1. Create Model
To calculate the GPS using the specified kinematic variables , you must have a model with at least 7 segments in your model:
- A Pelvis
- Left/Right Thigh Segments
- Left/Right Shank Segments
- Left/Right Foot Segments
In addition to these segments, I also created Left/Right Virtual Feet segments and a virtual lab segment:
- 1. In order to calculate more meaningful ankle joint angles, I created a virtual foot using this method. The virtual feet are called Right/Left Virtual Foot (R/LMF).
- 2. Since my subject is walking in the +/- direction of the lab, I also created a dynamic virtual lab which changes direction based on the subject's direction of progression. The virtual lab is called Virtual Lab Pelvis. I then calculated the pelvis angle and foot progression angles relative to the virtual lab segment.
Step 2. Define Joint Angles
To calculate the kinematic variables , nine signals must be created. The signal name is user defined, but this tutorial uses the following names:
Since the Recalc pipeline is stored in the Report template (.rgt), a report template which stores these signal definitions was created. This report template can be downloaded here.
NOTE: It is recommend that the left and right sides have the same convention for +/-.
Create Normal Database
The GPS requires some reference data to compare against. For this tutorial, the subject's data is compared against a control database. Instructions to create a normal database can be found in the GPS Normal Database Tutorial. This tutorial describes how to easily create the normal data script and how to save the control data as a .vnd file.
The script used to create the normal data can be found here.
To complete this tutorial, sample control data can be downloaded from here. Please note this "control database" was created from subject - so you should NOT use this as actual data.
Calculate GPS for a subject
1. Prepare Subject CMO
Make sure the subject's CMO has the same model template used for the control subjects and the same signals are defined (using the report template).
Gait events must also be created in the CMO file.
An example of a properly prepared CMO file can be downloaded here.
2. Create Subject Normalized Signals
The normalized signals should be the same for the control and test subject. By the same, we mean the signals should be normalized to the same number of points (ex. 51 ) between the same events (ex. LHS+LHS).
- A. Set the active file to ALL_FILES
- B. Run the NormalizeSubjectData.v3s script
NOTE: The same script was used to normalize the subject's data as for the control database. The only change was that the result folder was changed from GPS_CONTROL to GPS_SUBJECT in Notepad++ and then the new script was saved.
3. Calculate GPS Signals
- A. Run the CalculateGPS_2015_06_02.v3s (show below)
- B. When prompted select the control database, an example database can be downloaded here
This script requires the subject data to be stored in the P2D::GPS_SUBJECT folder and the control data to be stored in the P2D::GPS_CONTROL folders. The names for the associated signals should be the same, for example the left dorsiflexion angle should be the LAnkleAngle_X_LHS_LHS in both the subject and control folders.
The script will use ALL signals in the GPS_SUBJECT folder for the calculations. The 2009 paper  used 15 kinematic variables, if you would like to do the same, only 15 signals should exist in your GPS_SUBJECT folder.
As long as your normalized signals are stored in the GPS_SUBJECT and GPS_CONTROL folders, and the signal names are consistent between both folders, you can use this script with signals that use a different naming convention or as many kinematic variables as you would like.
!===================================================== ! Gait Profile Score and Movement Analysis Profile Pipeline ! Date: 2015 ! Need: A complete .cmo file with walking trials ! Normal data in .p2d format ! Purpose: Replicate the GPS and MAS as described in Baker et al., 2009, ! The Gait Profile Score and Movement ANalysis Profile, Gait and Posture, 30, ! p.265. !======================================================= File_Open ! /FILE_NAME= ! /SUFFIX= /SET_PROMPT=Open Control Database for GPS ; Select_Active_File /FILE_NAME=GLOBAL ! /QUERY= ; Set_Pipeline_Parameter_To_List_Of_Signal_Names ! Get a list of the kinematic variables which will be used to calculate the GPS ! The normalized signals should be stored in the P2D::GPS_SUBJECT folder ! - ONLY signals to be included in the GPS should be in this folder ! - The signal names from this folder be identical to the corresponding control signals ! - Control signals should be stored in the P2D::GPS_CONTROL folder /PARAMETER_NAME=SIGNAL_LIST /SIGNAL_TYPES=P2D /SIGNAL_FOLDER=GPS_SUBJECT ; Get_Pipeline_Parameter_Count ! Calculate the number of kinematic variables to be used for the GPS /PARAMETER_NAME=KIN_VARIABLES /PARAMETER_VALUE=::SIGNAL_LIST ; For_Each /ITERATION_PARAMETER_NAME=SIGNAL ! Loop over each signal in the list /ITEMS=::SIGNAL_LIST ; ! ------------------------- ! Calculate GVS ! ------------------------- Subtract_Signals ! Calculate the difference between the Subject and Control Data /SIGNAL_TYPES=P2D /SIGNAL_FOLDER=GPS_SUBJECT+GPS_CONTROL /SIGNAL_NAMES=::SIGNAL ! /COMPONENT_SEQUENCE= /RESULT_FOLDER=GVS_SIGNAL_DIFF /RESULT_NAME=&::SIGNAL& ; Metric_Root_Mean_Squared ! Calculate the GVS ! The GVS is the RMS of the difference between the Subject and Control Data /RESULT_METRIC_FOLDER=GVS /RESULT_METRIC_NAME=_RMS /APPLY_AS_SUFFIX_TO_SIGNAL_NAME=TRUE /SIGNAL_TYPES=DERIVED /SIGNAL_FOLDER=GVS_SIGNAL_DIFF /SIGNAL_NAMES=&::SIGNAL& /COMPONENT_SEQUENCE=Y /EVENT_SEQUENCE= /EXCLUDE_EVENTS= /SEQUENCE_PERCENT_START= /SEQUENCE_PERCENT_END= /GENERATE_MEAN_AND_STDDEV=FALSE ! /APPEND_TO_EXISTING_VALUES=FALSE ; ! ------------------------- ! Calculate GPS ! ------------------------- Evaluate_Expression ! Square the GVS value for each variable /EXPRESSION= ( METRIC::GVS:&:&::SIGNAL&_RMS ) ^ 2 ! /SIGNAL_TYPES= ! /SIGNAL_FOLDER=ORIGINAL ! /SIGNAL_NAMES= /RESULT_TYPES=METRIC /RESULT_FOLDERS=GPS_MATH /RESULT_NAME=&::SIGNAL&_RMS_SQR ! /APPLY_AS_SUFFIX_TO_SIGNAL_NAME=FALSE ; End_For_Each /ITERATION_PARAMETER_NAME=SIGNAL ; Set_Pipeline_Parameter ! Update the signal list to reflect the suffixes added to the original signal names /PARAMETER_NAME=SIGNAL_LIST2 /PARAMETER_VALUE=::SIGNAL_LIST ! /PARAMETER_VALUE_SEARCH_FOR= ! /PARAMETER_VALUE_REPLACE_WITH= ! /PARAMETER_VALUE_PREFIX= /PARAMETER_VALUE_APPEND=_RMS_SQR ! /MULTI_PASS=FALSE ; Add_Signals ! Sum the squared GVS for each variable /SIGNAL_TYPES=METRIC /SIGNAL_FOLDER=GPS_MATH /SIGNAL_NAMES=::SIGNAL_LIST2 ! /COMPONENT_SEQUENCE= /RESULT_FOLDER=GPS_MATH /RESULT_NAME=GPS_SUM ; Evaluate_Expression ! Calculate the GPS ! The GPS is the RMS of the kinematic variables ! Since the GVS of the kinematic variables were already squared and summed, the signal only needs to be divided by the number of variables and the square root taken /EXPRESSION= SQRT ( (1 / &::KIN_VARIABLES&) * ( METRIC::GPS_MATH::GPS_SUM ) ) ! /SIGNAL_TYPES= ! /SIGNAL_FOLDER=ORIGINAL ! /SIGNAL_NAMES= /RESULT_TYPES=METRIC /RESULT_FOLDERS=GPS /RESULT_NAME=GPS ! /APPLY_AS_SUFFIX_TO_SIGNAL_NAME=FALSE ;
- Baker, R., McGinley, J.L., Schwartz, M.H., Beynon, S., Rozumalski, A., Graham, H.K., Tirosh, O. (2009). The gait profile score and movement analysis profile. Gait Posture, 30(3), 265–269
- Baker, R., McGinley, J. L., Schwartz, M., Thomason, P., Rodda, J., & Graham, H. K. (2012). The minimal clinically important difference for the Gait Profile Score. Gait Posture, 35(4), 612-615
- Baker, R. Walking With Richard: GPS, MAP and GDI calculators; http://wwrichard.net/resources/gps-map-and-gdi-calculators/