We have released Beta1 for Origin2021 and Python support is one of the key feature that we are planning for this version.
Please visit this page to request a beta
https://www.originlab.com/doc/python/originpro
1. we have wrapped PyOrigin into a new package called originpro, much better documented and works from a higher level. As a result far fewer lines of code will be needed to do something with Origin using Python.
2. We improved Code Builder, so you can run code by F5 key and you can now also debug your python code.
3. Python package installation is now part of Code Builder, in addition, you can also directly run pip command from Script Window.
Check out this link to view the new sample codes:
https://www.originlab.com/doc/python/originpro/Python-Examples-using-originpro
Here is an example to show how to export a graph to png:
import originpro as op
import os
#from Learning Center folder
op.open(op.path('c')+ r'Graphing\Trellis Plots - Box Charts.opju')
gg=op.find_graph(0)
f=gg.save_fig(op.path()+'my_py_test.png',width=500)
if len(f):
os.startfile(f)
CP