DEV Community

Cover image for Visualization in Jupyter
HongKee Moon
HongKee Moon

Posted on • Edited on

4 1

Visualization in Jupyter

Recently, I tried to load techan.js (http://techanjs.org/) in a Jupyter notebook javascript kernel. However, it failed to load since techan.js is made in commonJS format. Jupyter javascript kernel inherently uses requirejs(https://requirejs.org/) which support es6 based modules.

One of good PRs is https://github.com/andredumas/techan.js/pull/220 which converts the current commonJS system to ES6 module system. Therefore, I cloned it and changed some codes in order to be compatible with requirejs.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

The output of the above cell is the cover image.

In addition, I noted how to embed amcharts(https://www.amcharts.com/) which is quite useful for visualization in Jupyter notebook as well.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

The output of the amChart cell in Jupyter:

AMChart in Jupyter

Please, enjoy the visualization in javascript inside Jupyter notebook.

Also, let me know if you need any helps to embed nice modules in Jupyter notebook.

Image of Datadog

Master Mobile Monitoring for iOS Apps

Monitor your app’s health with real-time insights into crash-free rates, start times, and more. Optimize performance and prevent user churn by addressing critical issues like app hangs, and ANRs. Learn how to keep your iOS app running smoothly across all devices by downloading this eBook.

Get The eBook

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay