We use cookies and other tools to enhance your experience on our website and to analyze our web traffic.
For more information about these cookies and the data collected, please refer to our Privacy Policy.

Correct respiratory event in XML (NSRR)

2 posts
Was this reply useful? Learn more...
 
[-]
shaoweizhang +0 points · over 6 years ago

Dear all, I would like to get the detailed time point of some respiratory events (e.g. start and duration of Apnea and Hypopnea), but i found, the number of all Hypopneas and Apneas in XML flie can not correspond to variable like ahi_a0h3a in "shhs1-dataset-0.11.0.csv". Does anyone know which is correct, and is the time-annotation in XML correct?

Thanks for your help!

442 posts
bio
Was this reply useful? Learn more...
 
[-]
mrueschman +0 points · over 6 years ago

Thanks for checking out some of the SHHS data.

What do you mean by "the number of all [events in XML file] can not correspond to variable like ahi_a0h3a"?

Generally (in the vast majority of cases), the counts used in the AHI numerator (# of events / total sleep time) should match the count of events in the XML files. SHHS is our oldest data and we have seen some cases of scoring data that may have been corrupted over time. We hope to better document these cases over time.

Another thing to look out for in the SHHS data are respiratory events scored in wake epochs, which would not have counted toward the AHI variable in the dataset.

2 posts
Was this reply useful? Learn more...
 
[-]
shaoweizhang +0 points · over 6 years ago

Thanks very much for your reply. Sorry, i didn’t make myself clear. For example, in .xml file “ shhs2-200081-nsrr.xml ” the count of Hypopnea is 58 and the count of Apnea is 5 during sleep, should i use the sum (63)/sleep time to calculate AHI, or just use the hypopnea with ≥3 percent oxygen desaturation (ahi_a0h3a=2.6327944573). But in .xml file, part of hypopnea’s oxygen desaturation might be lost? And the occurrence of “SpO2 desaturation” is always 30 seconds later than hypopnea’s? (see the pictures as attached) Do you know how to calculate the AHI with the annotations in .xml file? Or is there a better way to get the specific time point of hypopnea (used to calculate ahi_a0h3a) ? Look forward to your reply.

442 posts
bio
Was this reply useful? Learn more...
 
[-]
mrueschman +0 points · over 6 years ago

Using the sum of events from the XML divided by the total sleep time (SLPPRDP) is the correct way to calculate an AHI. Some issues have crept into the SHHS scoring annotation data over time due to the data's age and bugs when converting with newer versions of the Compumedics software. This can make the XML data difficult to understand at times.

The Known Issues on the Polysomnography Introduction describe some of the problems you might encounter when working with the XMLs. The main issues I can see for your purposes are the oxygen desaturation linking/missingness (as you noted) and the respiratory events scored in wake (which would not count toward the AHI). To identify events scored in wake versus sleep you would need to also merge and align the staging annotations that are listed near the end of the XML files.

I hope this helps!