-
Notifications
You must be signed in to change notification settings - Fork 3
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
question on findWheelMoves3 #6
Comments
Hm, I think @k1o0 would have to comment on the details here, this has been too long ago for me to remember. However I wanted to just comment that you'd have to be very careful in interpreting wheel offsets, since mice can often spin the wheel and let go, letting it spin for a while after they stopped moving their limbs. You might be better off in general looking at video of the mice if you're interested in this. |
I see, that makes sense. I will figure out an alternative confirmatory measure using the videos. But yes, if @k1o0 could comment on the details, it would help a lot. Thank you! |
Btw is there a publication that I could cite for this? |
It was used in Steinmetz 2019 -
https://www.nature.com/articles/s41586-019-1787-x - and I believe there's a
supplemental figure panel showing how well the algorithm worked on the
wheel traces - so that would probably be best. Thanks -
…On Thu, Jan 26, 2023 at 9:28 PM G. Duygu Yilmaz ***@***.***> wrote:
Btw is there a publication that I could cite for this?
—
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABZ5IP3RLVVA3AYLHRDCBA3WUNMG7ANCNFSM6AAAAAAUG7QU3A>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Hi,
I'm using this script to extract movements from my wheel data, first of, thanks a lot for putting it here! I wanted to get precise movement offsets so I attempted to adapt what you've done in onsets:
`offsetSamps = find(isMoving(1:end-1) & ~isMoving(2:end));
wheelToepOffsetsDev = zeros(length(offsetSamps), tThreshSamps);
c = 0; cwt = 0;
while
isempty(onsetSamps), itpltz] = intersect( i2proc(1:end-1), offsetSamps );i2proc = (1:p.batchSize) + c;
[icomm] = intersect( i2proc(1:end-1), offsetSamps );
[
i2proc(i2proc > length(t)) = [];
if ~isempty(icomm)
w2e = hankel(pos(i2proc), nan(1,tThreshSamps));
w2e = abs(bsxfun(@minus, w2e, w2e(:,1)));
wheelToepOnsetsDev(cwt + (1:length(icomm)), :) = w2e(itpltz, :);
cwt = cwt + length(icomm);
end
c = c + p.batchSize;
if i2proc(end) >= onsetSamps(end), break, end
end
warning('on', 'MATLAB:hankel:AntiDiagonalConflict')
hasOffset = wheelToepOffsetsDev > p.posThreshOffset;
[a, b] = find(~fliplr(hasOffset));
offsetLags = tThreshSamps+accumarray(a(:), b(:), [], @min);
offsetSamps = offsetSamps + offsetLags;
offsets = t(offsetSamps);
`
This gives me lots of 'MATLAB:hankel:AntiDiagonalConflict' warnings. As it might show, I don't know much math, so I don't know how ok it is to ignore it. I'd appreciate any help
Thanks in advance!
The text was updated successfully, but these errors were encountered: