Posted by
Straub, Volko A. (Dr.) on
Jan 25, 2018; 4:28am
URL: http://imagej.273.s1.nabble.com/Macro-Help-tp5019946p5019947.html
Dear macastronomer,
Did you have a look at the macro section of the ImageJ documentation (<
https://imagej.nih.gov/ij/docs/guide/146-14.html>
https://imagej.nih.gov/ij/developer/macro/macros.html[
https://imagej.nih.gov/ij/developer/macro/images/shortcut.jpg]<
https://imagej.nih.gov/ij/developer/macro/macros.html>
Macro Language - National Institutes of Health<
https://imagej.nih.gov/ij/developer/macro/macros.html>
imagej.nih.gov
A macro is a simple program that automates a series of ImageJ commands. The easiest way to create a macro is to record a series of commands using the command recorder ...
) that describes the available macro commands? It also gives some very simple examples, links to a large list of more specific sample macros and refers to the Macro Recorder, which is a good starting point to find out about how to translate manual analysis steps into macro commands.
On the following page (
https://imagej.nih.gov/ij/docs/guide/146-14.html) you can find links to various tutorials on writing ImageJ macros that provide more in depth introductions.
Hope you find the information that you need to get you started.
Volko
ImageJ User Guide - IJ 1.46r | Macros<
https://imagej.nih.gov/ij/docs/guide/146-14.html>
imagej.nih.gov
There are more than 300 example macros, on the ImageJ Web site. To try one, open it in a browser window and drag it directly to the Main ImageJ window ...
ImageJ User Guide - IJ 1.46r | Macros<
https://imagej.nih.gov/ij/docs/guide/146-14.html>
imagej.nih.gov
There are more than 300 example macros, on the ImageJ Web site. To try one, open it in a browser window and drag it directly to the Main ImageJ window ...
[
https://imagej.nih.gov/ij/developer/macro/images/shortcut.jpg]<
https://imagej.nih.gov/ij/developer/macro/macros.html>
Macro Language - National Institutes of Health<
https://imagej.nih.gov/ij/developer/macro/macros.html>
imagej.nih.gov
A macro is a simple program that automates a series of ImageJ commands. The easiest way to create a macro is to record a series of commands using the command recorder ...
________________________________
From: macastronomer <
[hidden email]>
Sent: 24 January 2018 22:35:55
To:
[hidden email]
Subject: Macro Help
I need to learn to write Macros, but I'm not even sure where to start with
this task. I'm familiar with some C++ and some Python, but not enough that I
know where to begin. I'm pretty good at understanding code that is already
written.
Here is the task I have, and an image to help clarify. Autodetecting the
membrane width will not work, which is why we need to multiple lines drawn
manually. The following are the script steps that would be needed:
Open an image, set the scale off of a micron bar.
Ask for the measurement frequency in distance.
Ask for a freehand line (in image it is the yellow line) down the center of
the membrane.
Ask for a freehand line on one side of the membrane (first cyan line).
Ask for a second freehand line on the other side of the membrane (second
cyan line).
Points should be created down the yellow line at the above given distance
until the end of the line is reached.
Straight line segments created between each point.
Then a perpendicular line drawn (the Red line) bisecting each line segment,
extending only to the cyan lines.
The length of each red line returned in the results (measurement) window.
Ask to make another measurement or end.
Burn lines into image and save.
<
http://imagej.1557.x6.nabble.com/file/t381898/measure.png>
--
Sent from:
http://imagej.1557.x6.nabble.com/--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html