I have a python script running. I want to call *.jsl script in my running python script and want to make use of it's output in python. May I know how can I do that?
-
What's a jmp script? (The tag you're using seems to apply entirely to the ASM instruction...) (And whatever it is, you probably want to look at the subprocess module). – Wooble Jul 29 '13 at 18:30
3 Answers
You should take a look at the JMP automation guide.
You can automate JMP from Python using the win32com
interface, which is unfortunately quite buggy and incomplete. I've written a custom library of code to work around these issues, largely because my job requires me to work with JMP extensively and its built-in jsl programming language is awful at many things.

- 76,929
- 13
- 76
- 124
Make sure jmp.exe is available in your system environment so that if you type "jmp.exe" in the command line, it would launch jmp. Then have your *.jsl ready. use python procees to run this command "jmp.exe *.jsl" and that would open jmp and run the *.jsl script and then you can import whatever you generate from jmp back in to python.

- 1
- 2
I'm on a Mac, and this works
import os
os.system('open /Applications/JMP\ Pro\ 13.app/Contents/MacOS/JMP /path/filename.jsl')
there is a space between the path/executable and the path/name.
In your JSL make sure the first line only has //!
This will make the script auto-run when its opened.
Also, use quit();
as the last line, that way the instance of JMP that is opened gets closed.
Reference this link on using os: How can I launch an instance of an application using Python?

- 1
- 1