This is the PWP toolbox.
It reproduces most of the content of Figure 1 of the scientific publication .
The toolbox runs under Matlab R2017a with the Signal Processing Toolbox and consists of two main scripts:
for the hypersampling via analytic phase projection of the EPI data from the public data base as described in reference . This script reads EPI and pulse data and outputs a file with the hypersampled data.
It also produces, for validation purposes, maximum intensity projections (MIPs) of pulse amplitudes, pulse waveforms, and two videos: Rocking MIPs and a movie that shows the pulse wave traversing the brain vasculature. Such a movie is also shown as supplementary information in .
for tracking an artery, showing selected waveforms, and producing the PWP (pulse wave profile). This script reads the file from the first script and produces figures. Figures can be saved to files out of their respective figure windows.
The toolbox also contains three helper scripts (truemean.m, truestd.m, coherence_fct3.m) to perform simple statistics and compute the coherence.
The purpose of publishing this toolbox is threefold:
- To ensure scientific reproducibility of reference 
- To provide the detailed methods for the generation of pulse wave profiles from MRI data, for which there was no space in 
- To enable researchers to use MRI pulse wave profiles in their own research
If the toolbox is used to reproduce Figure 1 of reference , it is necessary to download the original MRI data from the "studyforrest" server, as referenced in . This data is not provided here. Using the toolbox on data requires the adjustment of directory structures and file names to match the given environment.
Depending on the specific installation, the toolbox also requires additional scripts to read data and write movies. These are not provided here. The specific scripts for reading data used in the toolbox are load_*.m and save_*.m and are from “Tools for NIfTI and ANALYZE image” (https://www.mathworks.com/matlabcentral/fileexchange/8797-tools-for-nifti-and-analyze-image?s_tid=FX_rc2_behav).
The script to write gif movies is gif_add_frame.m (https://www.mathworks.com/matlabcentral/fileexchange/21407-gif_add_frame).
If the toolbox is used for own research, please cite reference  and mention that the PWP toolbox has been used. Using this toolbox for own research requires adjusting several parameters and directories/file names in the scripts. This task should be straightforward.
If you detect an error, have a suggestion how to improve things, or just want to provide feedback, please contact me. Please understand that I cannot answer questions pertaining to specific installation problems of the toolbox or error messages in Matlab unless they point to errors in the code provided.
 Voss HU, Dyke JP, Ballon DJ. Pulse wave profiles of cerebral arteries obtained with MRI. Proceedings of the International Society for Magnetic Resonance in Medicine 2019.
 Voss HU. Hypersampling of pseudo-periodic signals by analytic phase projection. Computers in Biology and Medicine 2018; 98: 159-167.
If the toolbox is used for own research, please cite reference  and mention that the PWP toolbox has been used.  Voss HU, Dyke JP, Ballon DJ. Pulse wave profiles of cerebral arteries obtained with MRI. Proceedings of the International Society for Magnetic Resonance in Medicine 2019.
Improved description, cleaned scripts
Create scripts with code, output, and formatted text in a single executable document.