john-judge / PhotoLib

Builds a camera/electrode management DLL to expose to Python applications
1 stars 0 forks source link

add Time Course feature #21

Open john-judge opened 3 years ago

john-judge commented 3 years ago

Feature

Time Course will be a right-hand column full tab that plots aggregated data over multiple files.

Layout: A plot viewer above controls. The plot x-axis is record #. Controls includes a listing of all .npy files in the current save directory; each can be selected or deselected. When selected, a file's aggregated data is plotted as a point in the plot.

Each slice's set of points in the plot is plotted with a different color. Each location in each slice group has a different line style. A legend is included.

The possible aggregations include: MaxAmp/SD, MaxAmp, Latency, RLI, MeanAmp/SD, MeanAmp. Aggregations are performed over the selected measure window and always over all trials for each record.

Each time course is pixel or region specific.

Implementation

This feature could just use the existing TraceViewer like current PhotoZ does? Or we can just inherit from TraceViewer and borrow a lot of features, but base the plots on TimeCourse objects rather than Trace objects.

john-judge commented 3 years ago

@ksscheuer I'm hoping to improve over PhotoZ's current Time Course, which just overlays the measured value for each file in the Trace Window (which is a bit non-intuitive with the lack of x-axis labeling). Any thoughts?

Keeping in mind the first use will probably be LTP experiments -- interested in whether pattern separation can be observed in mossy cells in DG, especially given the context of Yihe's latest paper on MC-MC synapses.

ksscheuer commented 3 years ago

Oh god, I'm so sorry for the late reply. I've been willfully ignoring email for the last week trying to do analysis. I actually don't mind the current way time course is set up, but maybe that's just because Meyer first showed it to me and explained it at the same time (rather than leaving me to figure it out on my own). Can you expand on how the lack of x-axis labelling might be confusing? If I remember correctly, time course essentially gives you a graph more or less like the one below (except that it would only contain red points or only contain blue points, not both at once) without the labels for time on the x-axis. Is that right? image

john-judge commented 3 years ago

No worries. This was more of an fyi since I know you don't really plan to use time courses

Yes, the plot you showed would be like the time courses we would create.

When time course is swapped back and forth with trace, the x-axis is shared and is is on the order of ms for one and seconds for the other. Not terrible, but it would be nice to show units like in the plot you attached. It's also not very transparent on which zda files it is plotting.

This is a proof-of-concept (screen capture):

https://user-images.githubusercontent.com/40705003/131745807-244bd066-618a-48f9-bead-37c1d4015a60.mp4

On Mon, Sep 6, 2021, 11:55 AM ksscheuer @.***> wrote:

Oh god, I'm so sorry for the late reply. I've been willfully ignoring email for the last week trying to do analysis. I actually don't mind the current way time course is set up, but maybe that's just because Meyer first showed it to me and explained it at the same time (rather than leaving me to figure it out on my own). Can you expand on how the lack of x-axis labelling might be confusing? If I remember correctly, time course essentially gives you a graph more or less like the one below (except that it would only contain red points or only contain blue points, not both at once) without the labels for time on the x-axis. Is that right? [image: image] https://user-images.githubusercontent.com/71110456/132246754-d1d54e4c-129f-4a94-b8a4-d4840f298eb8.png

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/john-judge/PhotoLib/issues/21#issuecomment-913770351, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJWRX27RAWBC7PHTQEUT7TTUATW6JANCNFSM5DAX4JKQ .

ksscheuer commented 3 years ago

I didn't realize that the x-axis switched between msec and sec. That's not great. Your proof-of-concept is more intuitive. Clearly showing (and allowing more choice over) the specific files displayed is also a nice improvement.