Supplementary File 2: R Code and output - PSG Analysis

2018-08-09T17:50:33Z (GMT) by Allan J. Kember
This is a stand alone report containing the code and output of an R script, which was generated by the "Compile Report" function in RStudio (R Statistical Software package (version 3.2.4 (2016-03-10))). This code processes the polysomnography (PSG) sleep reports in full, making within-participant (paired) comparisons and between-participant (unpaired) comparisons. The sleep reports were generated by Embla Sandman Elite sleep diagnostic software (Natus Medical Incorporated, Pleasanton, USA). The data in the PSG sleep reports was collected via Pro-Tech zRIP Durabelts (Philips Respironics, Murrysville, USA) for respiration, PT1 pressure transducers (BRAEBON Medical Corporation, Kanata, Canada) for airflow and snoring, electrodes (Natus Medical Incorporated, Pleasanton, USA) for ECG/EEG/EOG/EMG, and finger-tip pulse oximetry for peripheral blood oxygen saturation (SpO2) in accordance with the American Academy of Sleep Medicine 2014 guidelines. Audio and video data were also recorded and used in order to determine body position and snoring.