vas-reader

Version 1.1.01 (2.36 MB) by Koeun Lim
Open source MATLAB scripts for importing VAS questionnaires and read VAS scores
0 Downloads
Updated 16 Apr 2024

vas-reader

[Release authorization statement] This code is released on behalf of BIOTRONIK Neuro, Clinical Technology and Advanced Concepts Department.

System requirements:

  • python 3.8 or above
    : type pyenv in MATLAB command to check if your MATLAB is configured for python & see python version information.
    Configure Your System to Use Python
  • python package pdf2image
    : type !pip install pdf2image in MATLAB command window
  • MATLAB image processing toolbox
  • Target Shooting Font (in resources folder)
    : To make a new compatible font available to MATLAB, install the font in Windows by opening the folder Start->Control Panel->Fonts and selecting File->Install New Font. Then restart MATLAB and the font will be available for use.

Followings are provided in the repository:

  • 1 main script : readVAS
  • 3 function mfiles for processing VAS scans
    • normalize_img.m : image pre-processing
    • auto_readVASscores.m : automatically detects VAS scales and markings
    • semi_auto_readVASscores.m : adds user-interface to manually mark VAS scales and patient markings when automatic detection fails
  • 1 function python script
    • convert_pdf_to_img.py : converts pdf scan to jpg
  • VAS_template.pdf & VAS_template.jpg : use VAS_template.pdf for data collection. JPEG format is used for the algorithm.
    alt text
  • 3 samples (VAS_sample_01~03.pdf) to test the algorithm.

How to use:

(1) Scan marked VAS questionnaire (Template pdf) in grayscale or color and save in pdf format.
(2) Change directory to the cloned local repository, then run readVAS in the command window.
(3) Select a VAS pdf scan to read when prompted.

If the script can automatically read the scales,
(4) A prompt window will appear if the detected marking is correct or not. Click OK if the markings are correct.
If detected markings are incorrect,
(5) Another prompt window will appear to select the incorrect marking(s) or incorrect edge(s). Multiple selection is possible.

If the script cannot automatically read the scales,
(4) Whole scan will appear for the user to mark the edges of the scales first (left-right, top-down),
(5) then mark the patient markings (top-down) with mouse clicks.

(6) Annotated output image file will be saved in the same directory as the original scan.

Example input and output:

Input: VAS_sample_01.pdf
alt text
Output: VAS_sample_01_output.png
alt text

Cite As

Koeun Lim (2024). vas-reader (https://github.com/koeunlim-nro/vas-reader/releases/tag/v1.1.01), GitHub. Retrieved .

MATLAB Release Compatibility
Created with R2021b
Compatible with R2021b and later releases
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.1.01

See release notes for this release on GitHub: https://github.com/koeunlim-nro/vas-reader/releases/tag/v1.1.01

To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.