cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Register to attend Discovery Summit 2025 Online: Early Users Edition, Sept. 24-25.
  • New JMP features coming to desktops everywhere this September. Sign up to learn more at jmp.com/launch.
Choose Language Hide Translation Bar
Evan_Carr
Community Manager Community Manager
Going further with Python in JMP 19

JMP’s latest release builds on the Python integration support that was introduced in JMP 18 by focusing on a fundamental part of the workflow: data access. By expanding data table operations and Python-JSL interoperability, accessing data becomes simple and convenient.

 

Prefer video? Watch it here.

 

Data Table operations

The jmp.from_dataframe() function provides an efficient way to convert external data frames into JMP data tables. The data frame protocol provides the mechanism to convert between data frames in memory. All data frame objects that provide support for the data frame interchange protocol can convert between data frames in memory. Notable examples are pandas, polars, and ibis.

The example below shows a transformation of a pandas data frame into a JMP data table.

Picture11.png

Likewise, it is equally easy to transform JMP data tables into another supported data frame library type. For example, from JMP to pandas:

Picture12.png

In JMP 18, jmp.DataTable only provided full support to Numeric and Character columns. Now, all JMP Column Data Types are supported from Python. Additional objects provide support for Expression and Row State.

The jmp.DataTable object adds a row_states property to allow setting the table’s row states from Python. It simplifies the ability to copy the set of row states to a column or set the tables row states from a column.

Picture13.png

A table’s column format is now accessible using col.format with a string or tuple, depending on the use case. JMP 19 properly marshals between JMP’s date-time representation and Python’s date-time representation: JMP dates in the data table, Python date-time objects from Python code.

Picture14.png

Similarly, Python Get()/Python Send() now supports seamless transfer of date-time values between Python and JSL.

In addition to the ability to format columns, Columns can add formulas as well, using col.formula with jmp.Expressions.

Picture15.png

JMP 19 also allows the ability to set jmp.Images as Expression Column values.

Other unhighlighted data table operations can be found using the Scripting Index under the Python category.

Python-JSL interoperability

Many workflows still require JSL support to perform specific tasks in JMP. To enhance cross-language workflow, support for adding, reading, and modifying JSL variables from Python has been added. Currently, it is supported only through the Global and Here namespaces. The example below shows Python setting the JSL variable ‘e’ from Python, then using JSL to set the here::pi variable and print the globals ::e variable set from Python, and then finally printing from Python the here::pi variable set from JSL.

Picture16.png

R integration

JMP 19 introduces an initial support for R through Python using rpy2. JMP provides a new module, jmpex, to support extensions. R is the only extension that jmpex currently supports. This support consists of a Python API similar to the JSL R API. The package jmpex is an interface layer between JMP and rpy2, which, in turn, depends on R. A user-installed version of R must already be present on the system, and the R_HOME environment variable must be set to the R location. These must be present before jmpex is installed or R Init() is called for the first time due to jmpex package requirements.

JSL support for R has been restored in JMP 19 by utilizing the jmpex package internally.

The example below illustrates the new Python API to R supplied by jmpex.

Picture17.png

General changes

A switch from Python 3.11 in JMP 18 to Python 3.13 in JMP 19 provides security updates throughout JMP 19’s life cycle. JMP 19 also provides a convenient way to reset the shared Python environment through jmp.reset(). There are also improvements to jmputils:

  • jmputils.__version__
  • jmputils.is_installed(‘package’)
  • jmputils.packages()
  • jmputils.package_version(‘package’)

To better support scripted installation of packages, jmputils.jpip() now returns the Python subprocess.CompletedProcess object. See Python documentation for information regarding the CompletedProcess object.

Deprecations

  • Python Init()
  • Python Term()
  • Python Control() Removed.
  • Python Get Graphics() Removed.
  • R Term()
  • R Get Graphics() Deprecated, has no effect.
  • R Control( Echo (bool) ) Parameters Async( ), and Interrupt( )

What’s next?

JMP 18 was all about building a new foundation to support a native Python workflow within JMP.  That foundation began by fixing the most challenging issues of JMP and Python integration.

JMP 19 continues to build on that foundation, focusing on refinement and providing significant additional data table support. Our desire is to provide the same capability to work with a data table from Python as is available in JSL. All column types are now supported from Python. Column formatting and row states are accessible and modifiable from Python scripts.

Finishing out the column type support allowed the support of the portable data frame protocol. Easy conversion between portable data frames, including pandas and a jmp.DataTable object, has been restored, which preserves working in-memory, without resorting to a CSV copy in the file system.

Additionally, the focus has been on productivity improvements, cleaning up the behavior of our objects so they behave as a Python programmer would expect. Lastly, the new release closes out some issues that were missed in JMP 18 or ran out of development time before release.

The future of the Python integration is strong. Within JMP we are building on top of our own Python capabilities: the restoration of SAS connectivity, restoration of JSL R support, a new Python API for R, and data connectors that are all built on top of the Python integration.

Looking forward is always speculative, but there are a few things that we are researching for possible inclusion in future releases:

  • Continued improvements to script editor support.
  • JMP support for Python virtual environments.
  • Additional improvement to package handling support, including:
    • Configuration options to connect to corporate or internal repositories.
    • Simplified ways of building validated and locked down site packages by a site administrator.
  • Support for raising dialogs and windows from Python that allow graphics and reports to be built from Python.

Your suggestions are highly appreciated, as we want to focus on the areas that will most improve your workflow.

 

Blog co-authored by @Paul_Nelson

Last Modified: Sep 12, 2025 12:01 AM