Repository navigation
WIP: initialize continuous-time linear estimation in TF domain - #2641
jona-sassenhagen wants to merge 7 commits into
Conversation
|
Haha, murder your computer is right :) Just a thought - why doesn't this function allow you to provide epoch objects? Why only Raw objects? Esp doing the TFR stuff, that's going to result in a lot more RAM, no? Also, if someone uses this for TFR regression, then how would they run statistics on this? In my experience I've only seen people do permutation cluster testing, but that's not possible with this right? |
The workflow for epochs objects is completely different under the hood. It would fit much better under Tal's function,
It's not even that bad, at least not for my usage cases. I guess with high sampling rate MEG and looking at gamma, it would be heavy.
You have to understand betas as being fundamentally no different from means. They're a dependent variable; you can run cross-subject inference analyses on means or on regression coefficients, it's the same, you get a t value at the end. Personally, I use cluster-based permutation tests on the time/channel or time/channel/frequency matrices. |
Ah fair enough - I didn't dive into the code too closely, sorry if that was obvious.
It isn't too bad in my case if you represent things with smaller numbers of bits (and obviously if you cut down on the number of frequency bands for the wavelets or decimate). Maybe we should cross that bridge if we get to it :)
Yeah, that's what I was thinking. I guess I was wondering if you could get any extra information about the variability of the betas that you wouldn't get by just doing a simple mean. e.g., if you bootstrapped your coefficients you could get an idea for their variability. I guess you could roll your own estimator to do this under the hood.
So do I - I guess it's just more common in ecog to keep analyses at the subject level, rather than doing a group-level analysis for TFR responses. |
|
Hehe, looks like I was already talking about this one last year too and forgot about it...got too many github issues on my mind :) I think this is doing something similar to STRFs though not quite the same. A couple quick thoughts:
So to me it seems that doing something like STRF fitting would warrant a separate module or function. Maybe if we don't want to overlap too much with this more general OLS stuff, it could explicitly be a STRF model, rather than just an "encoding model"? What do you guys think? |
You can pass a custom solver. This thing here only gives coefficients though, so if you want MSE etc., that'd optimally reference this.
That would mean refactoring out the code that's currently in lines 284-309. Note, the XDawn module also duplicates exactly this functionality.
That would fall under stats.linear_regression.
When I was discussing this module with Alex at the code sprint, he immediately recognized it was an encoding model (which had been so far unknown to me). I wouldn't mind a new encoding module eventually ... either including this function here, or just a lot of shared code. I mean, this function basically does 3 things:
And that'd be the backbone of a full STRF/encoding model, right? |
|
Is there recommended code for TF decomposition of raw data? @Eric89GXL |
|
I don't think we have anything mne-specific for time-freq decompositions of Raw |
|
I've just used cwt_morlet in the past...I think people have held off on building TFRs for Raw objects because they have a tendency to kersplode memory. That said, I still think it'd be great to have a method / class that handles full TFR decomposition without averaging in a clever memory-efficient way. |
|
I'll put this one on ice until I've factored out building the pred matrix. |
"rERPs for time-frequency data"
Currently fairly messy. Also, will probably murder your computer.
@choldgraf