Igor Pro for Direct (shell or batch) Control
jjweimer
I have recently become aware of the utility of python in LaTeX. I plan to generate problem sets (e.g. homework for courses) using it. The beauty as I see is the ability to set up a problem, define its inputs and equation(s), and generate the answer all in a "publication-ready" format. As I explored the options, I also saw where this is being touted as a great way to create a self-contained journal publication, one that provides both the background and the analysis tools, all within a "click and create" approach.
I started to wonder. Would it ever be possible to run Igor Pro from a (shell or batch) command line call? The equivalent of \usepackage{pythontex} in LaTeX might be \usepackage{IgorProtex}, with the subsequent calls to invoke Igor Pro with data input values, collect the return, and have it included properly. Of course, the link to call Igor Pro from python or other "script" languages would fall naturally out of this interface.
Perhaps this is already somewhat possible when Igor Pro is running a background daemon with "watch folders". Even that would be an interesting first step.
But ... Am I dreaming too big or dreaming alone on this?
DisplayHelpTopic "Calling Igor from Scripts"
John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
May 30, 2017 at 10:37 am - Permalink
Thanks! That is a good starting point. I can see now how I might set up something like this in a (macOS) shell script ...
<IGOR> -X -Q "Analyze New Data"
<IGOR> -X "Quit/N"
I'd just have to take care of the I/O of data in and results out through Igor Pro code.
The next step might be when such script calls would NOT open the entire UI of the application (is this called something like running in a "faceless mode"???).
--
J. J. Weimer
Chemistry / Chemical & Materials Engineering, UAH
May 30, 2017 at 11:35 am - Permalink
For interacting with Igor Pro from the outside world I'm using https://github.com/AllenInstitute/ZeroMQ-XOP. This allows to call user defined Igor functions and return their results from over the network and other programming languages.
July 20, 2017 at 02:30 am - Permalink
IDK if it will do the trick, but this help topic is worth reading for windows installations:
displayhelptopic "Igor Command Line"
.And more precisely the following statement in the mentioned helptopic:
The /Automation flag keeps Igor windows hidden
best,
_sk
July 24, 2017 at 04:52 am - Permalink
July 25, 2017 at 02:46 am - Permalink
In reply to by jjweimer
Hi,
I tried these commands in the terminal of Mac. However, after the first command
<IGOR> ".../myexperiment.pxp" // activate (open) my experiment
The terminal could not run the following commands.
Does anyone have a suggestion about what's going on there?
February 1, 2021 at 08:23 am - Permalink