buzsakilab / buzcode

Code for internal lab sharing - polishing has started but is by no means complete
http://www.buzsakilab.com/
GNU General Public License v3.0
118 stars 128 forks source link

Score: Active vs Quiet Wake. #299

Open dlevenstein opened 5 years ago

dlevenstein commented 5 years ago

This has been on the potential to do list for a while and I'm thinking about implementing it.... First pass would be to use the theta threshold from REM to divide active/quiet wake. Anyone with thoughts?

dlevenstein commented 5 years ago

Bottom right plot shows the occupancy heat map for the non-NREM time..... notice that the wake cloud is continuous, but could be potentially divided by the same threshold that separates out REM.

I could add this in as an option to try out and see how it goes?

@brendonw1 ?

screenshot - 02282019 - 03 18 22 pm

AntonioFR8 commented 5 years ago

Theta/delta power ratio plus movement from accelerometer or tracking will be good enough to separate both states

On Feb 28, 2019, at 3:21 PM, Dan Levenstein notifications@github.com wrote:

This has been on the potential to do list for a while and I'm thinking about implementing it.... First pass would be to use the theta threshold from REM to divide active/quiet wake. Anyone with thoughts?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/buzsakilab/buzcode/issues/299, or mute the thread https://github.com/notifications/unsubscribe-auth/AM8oQ3pCN6hASEsUZ68XAcrZHECWQ81Dks5vSDpdgaJpZM4bXqQK.

dlevenstein commented 5 years ago

The theta used by SleepScoreMaster is (5-10Hz)/(2-20Hz). ("narrowband theta" above, we found that to be more reliable than theta/delta, because it's isolated narrowband theta on both sides, Gervasoni did something similar)

SSM doesn't use accelerometer because it's not available in all recordings, but the EMG signal is pretty good (see above, bottom right panel). It's not cleanly bimodal, but it looks like the threshold from REM could be used.

dlevenstein commented 5 years ago

The only frustrating thing is the small v high EMG mode, which tends to be associated with microarousals, but is not present in all recordings

AntonioFR8 commented 5 years ago

Yes, it looks good. Perhaps is worthy to add an option to read out the accelerometer signals and most of the recordings we do now have it. If you implement it in the SSM I will test it in a session in which I already classify active / quiete wake

On Feb 28, 2019, at 3:28 PM, Dan Levenstein notifications@github.com wrote:

The only frustrating thing is the small v high EMG mode, which tends to be associated with microarousals, but is not present in all recordings

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/buzsakilab/buzcode/issues/299#issuecomment-468425781, or mute the thread https://github.com/notifications/unsubscribe-auth/AM8oQ8cokw50Ru1k6RCHIaNYCxmL_RGiks5vSDvkgaJpZM4bXqQK.

brendonw1 commented 5 years ago

Sure! Wanna call it state 2 ("drowsy")?... between 1:Wake and 3:NREM

Thanks

On Thu, Feb 28, 2019 at 3:32 PM AntonioFR notifications@github.com wrote:

Yes, it looks good. Perhaps is worthy to add an option to read out the accelerometer signals and most of the recordings we do now have it. If you implement it in the SSM I will test it in a session in which I already classify active / quiete wake

On Feb 28, 2019, at 3:28 PM, Dan Levenstein notifications@github.com wrote:

The only frustrating thing is the small v high EMG mode, which tends to be associated with microarousals, but is not present in all recordings

— You are receiving this because you commented. Reply to this email directly, view it on GitHub < https://github.com/buzsakilab/buzcode/issues/299#issuecomment-468425781>, or mute the thread < https://github.com/notifications/unsubscribe-auth/AM8oQ8cokw50Ru1k6RCHIaNYCxmL_RGiks5vSDvkgaJpZM4bXqQK .

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/buzsakilab/buzcode/issues/299#issuecomment-468427203, or mute the thread https://github.com/notifications/unsubscribe-auth/ADXrTccS983f-9Q8pgtgCz0PnLl-KihNks5vSDzngaJpZM4bXqQK .

dlevenstein commented 5 years ago

Definitely state 2, though I think in the StateScore output I'd make it QWake or QuietWake or something like that? Not sure I'd like to commit to the animal being drowsy.

Plan is to make it a checkable box in TheStateEditor and input option in SleepScoreMaster (default: false, for now)

dlevenstein commented 5 years ago

Re: accelerometer - at this point, the SSM is well optimized for the LFP-derived EMG signal and it works well. I'd rather not go through the process of optimizing it for another optional signal which will have different statistics (for example, may not be so cleanly bimodal (middle left panel above) but may have a heavy tail). We think the EMG likely reflects muscle tone in stabilization muscles as well as movement, so it's very good for REM/NREM/MA segregation in a way that the accelerometer may or may not be.

brendonw1 commented 5 years ago

Sorry I didn't mean to call it drowsy... I agree I wouldn't... was just specifying what it has been called as a name. I think QuietWake would be good

dlevenstein commented 5 years ago

👍 Number 2 it is!

Maybe one of these days we’ll get our intermediate sleep detection and fill our all 5 numbers in TheStateEditor

On Feb 28, 2019, at 8:27 PM, Brendon Watson notifications@github.com wrote:

Sorry I didn't mean to call it drowsy... I agree I wouldn't... was just specifying what it has been called as a name. I think QuietWake would be good

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/buzsakilab/buzcode/issues/299#issuecomment-468506233, or mute the thread https://github.com/notifications/unsubscribe-auth/AG7dmHXp7kPs1tUBW4ySqTcnFOCQuaGYks5vSIIHgaJpZM4bXqQK.

brendonw1 commented 5 years ago

Did I ever tell you - actually Karim Benchenane and i talked about IS and I think we score it differently. Basically he calls it REM and we call it part of nonREM. Interesting. In his sleep staging paper/biorxiv he gets some different results than us and he was thinking it resulted from that difference about when you say REM starts

On Thu, Feb 28, 2019 at 8:28 PM Dan Levenstein notifications@github.com wrote:

👍 Number 2 it is!

Maybe one of these days we’ll get our intermediate sleep detection and fill our all 5 numbers in TheStateEditor

On Feb 28, 2019, at 8:27 PM, Brendon Watson notifications@github.com wrote:

Sorry I didn't mean to call it drowsy... I agree I wouldn't... was just specifying what it has been called as a name. I think QuietWake would be good

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub < https://github.com/buzsakilab/buzcode/issues/299#issuecomment-468506233>, or mute the thread < https://github.com/notifications/unsubscribe-auth/AG7dmHXp7kPs1tUBW4ySqTcnFOCQuaGYks5vSIIHgaJpZM4bXqQK .

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/buzsakilab/buzcode/issues/299#issuecomment-468506412, or mute the thread https://github.com/notifications/unsubscribe-auth/ADXrTeYfYePzjTCCQQ_1BTH2YzQvqW4rks5vSII9gaJpZM4bXqQK .

dlevenstein commented 4 years ago

Manu has gotten this to work - we'll work together to integrate into SleepScoreMaster