Directionality Plugin ROI

@tinevez I’m collecting a 2 hour time-series of cells exposed to an electric field that for the purposes of the time series below extends linearly right and left throughout the field of view. Using the orientation map of the Directionality Plugin I think I’m seeing directionality in the filopodia (the long extensions of cell processes that extend and retract in time.) However, if I look at directionality of the whole image, this gets lost. Is it possible to select a single cell in time to look for directionality using this plugin?

So when I use the Directionality plugin I catch individual cells that always extend a long process in the “blue” or “green” direction. However in the analysis of the whole image this gets lost.

I think you should detect and track each one first, then make an moving roi or slice each one as a standard image stack.


Thank you @yxdragon! Are you able to advise more specifically about this, about how to detect and track each cell within a field of view and make an ROI an individual stack without starting from scratch and re-imaging individual cells?

I think you can use ilastik to detect individual cell, and it can track.

then export the tracking file, and write some code to save them as one-cell sequence.

1 Like

Hello @Kristy_Wendt

I would do as @yxdragon recommends: first track individual cells then apply Directionality on small cropped images centered on the cell.

If you do not want to leave Fiji for tracking, you can use TrackMate:
Normally it is made to track bright blobs over dark background, however we had some successes with phase contrast images like yours, because of the dark ring around cells, that matches the ring of the LoG detector.

Also, TrackMate as an action that can extract the movie of a track centered on the cell directly, saving you the need to program it. I reckon it is called Extract track stack.


Thank you @tinevez! I’m working on troubleshooting beginner’s problems in tracking in both TrackMate and Ilastik at the moment. The Directionality color map is really neat and will work well for demonstrating directionality of particular cells in a field of view. Then I will try the cropped image technique. Ilastik is not working out of the box for me in Fiji to track cells and I’m having some problems interpreting the csv data in TrackMate, but for now I think I just need to spend more time on them. I was using the DoG filter because I think that’s what was in the trainer wiki, but I’ll try the LoG . .

(After trying LoG)

At pixel 10 and threshold 5, I get nice segmentation recognition in TrackMate for my image. And then I do get some nice images of my tracks. So you are saying to extract the movie of the track that I made with “Extract track stack” and then use that movie in the directionality plugin. I will try.

1 Like

I isolated this cell

and got this plot using OrientationJ
Would this be useful to you?
A correlation of this plot with your B field direction plot , or just an overlay, would be interesting.

//Simple orientation analysis

run("Plots...", "width=600 height=340 font=14 draw_ticks minimum=0 maximum=0 interpolate");
waitForUser("Isolate a single cell and crop the stack\nMake sure the stack is 8,16 or 32 bit\nThen Click OK");
otitle = getTitle();
run("Duplicate...", "duplicate");
rename("Background Removed");
run("Subtract Background...", "rolling=50 stack");

run("OrientationJ Distribution");
waitForUser("Set up OrientationJ Distribution\ne.g. No Table\ne.g. 30% Min. Energy\ne.g. 30% Min. Coherency\n\ne.g. Select Energy\ne.g. Gradient = Fourier\n RUN IT\nclose it\nTensor = 6\nThen click OK");


run("OrientationJ Distribution", "tensor=6.0 gradient=2 energy=on radian=off histogram=on table=on min-coherency=30.0 min-energy=30.0 ");
Table.rename("OJ-Distribution-1", "Results");

run("Images to Stack", "name=Histogram Stack title=OJ use");
run("Synchronize Windows");

//waitForUser("Click Synchronize All in the Synchronize Windows Dialog\nYou may need to click the horizontal bar to get the wheel to work\nThen Click OK");
run("View 100%");
getLocationAndSize(gx, gy, gwidth, gheight);
getLocationAndSize(ox, oy, owidth, oheight);
setLocation(gx-owidth, gy);

run("OrientationJ Dominant Direction");
Table.rename("Dominant Direction of "+otitle, "Results");

for (i=0; i <= 59; i++) {
ang = getResult("Orientation [Degrees]",i);
getDimensions(ow, oh, channels, slices, frames);
//ang = -30

waitForUser("Click Synchronize All in the Synchronize Windows Dialog\nYou may need to click the horizontal bar to get the wheel to work\nThen Click OK");


1 Like