We are thrilled to announce a new release of the GoFigr Python client. This upgrade includes several major new features — read on below to learn more!
Upgrading
To upgrade, simply run pip --upgrade
. You should see a message confirming that version 0.17.0
has been installed.
$ pip install --upgrade gofigr
Installing collected packages: gofigr
Successfully installed gofigr-0.17.0
Jupyter widgets
GoFigr will now display a helpful widget underneath each figure, which lets you download the image or copy it to clipboard in a single click.
You have several styles of widgets to choose from. See the documentation for more details: https://gofigr.io/docs/gofigr-python/0.17.0/customization.html#widgets
Please note that due to web browser restrictions, the copy functionality only works if your Jupyter instance is served over HTTPS or on localhost
(port forwarding to localhost does the trick, too).

History capture
When you publish a figure, GoFigr will now automatically save the full Jupyter execution history. This includes all the code executed in your Jupyter session to date, in the order in which it was executed. You can view the captured history under the “Code” tab in the UI.

Easily load and edit published figures with pickle
GoFigr now stores pickle data for your figures, meaning that you can load them in Python later and make edits with ease. Simply use the load_pickled_figure
function, passing in the API ID of the specific revision (which you can look up in the Web UI):
fig = load_pickled_figure("b0fc47f0-9baf-46db-b7e7-dce2467d30f1")
fig.gca().set_title("My updated title")
fig.gca().set_xlabel("Timestamp")
# Publish a new revision with an updated title
publish(fig)
py3Dmol support
Last but not least, GoFigr now includes experimental support for py3Dmol. Simply call viewer.show()
(with autopublish enabled) or call publish(viewer)
to publish your molecule.
To set the figure title, assign the title
property on the viewer. See below for an example.
Finally, GoFigr relies on selenium to generate PNG images of your molecules, so make sure you have a recent version of Chrome or Chromium installed on the same server as Jupyter. Firefox should work as well, but has not been tested. As always, please reach out to support@gofigr.io if you run into issues.

You can find the full changelog on GitHub: https://github.com/GoFigr/gofigr-python/blob/main/CHANGELOG.rst
Happy analysis!