Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

parameter coord_electrode #2

Open
Junji110 opened this issue May 4, 2015 · 2 comments
Open

parameter coord_electrode #2

Junji110 opened this issue May 4, 2015 · 2 comments
Assignees

Comments

@Junji110
Copy link
Contributor

Junji110 commented May 4, 2015

It seems that all CSD estimation methods assume equal spacing of recording depths and hence what they actually need for calculation is the interval between the depths (i.e. local variable h_val).
Then, isn't it simplar to give as an argument only the interval, rather than the coordinates of all the recording depths?
I also spotted a bug in SplineiCSD() related to this point, i.e., if you give coord_electrode so that the first element of this array is not just below zero (e.g, coord_electrode = (1000E-6, 1100E-6, ...)), the class returns a wrong result (and I cannot manage to fix this bug).

@espenhgn
Copy link
Owner

espenhgn commented May 4, 2015

Yes, you're right the spacing between contacts are clumsily dealt with. I don't remember why I did it that way.

In principle though, the inverse methods should be able to handle irregular contact intervals and assume that the assumed sources are centered on each contact. In case of the delta method it should be straight forward, but for the step method we may consider a fixed thickness of the sources perhaps, or that they can be given as an array. This could be extended to have source diameter depending on depth as well.

For the spline method, I'm not sure if I understand why Klas opted to do the spline interpolation the way he did. Wouldn't the most natural way be to spatially upsample the LFP signal using spline interpolation and simply assume sources as in the step method?

This bug you see, I think the codes assumes that the most superficial contact is at a depth of zero in order to deal with the cond_top value. I think it the code should work regardless though. I will try and look into it.

@espenhgn
Copy link
Owner

espenhgn commented May 4, 2015

Just spotted another thing; the csd estimate with spline row 1 in the output array is always zero. This can't be right.

@espenhgn espenhgn self-assigned this May 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants