What are the pros and cons of Dash by Plotly vs Jupyter Dashboards?

40,729

Disclaimer: I wrote Dash :)

I'd recommend just trying both of them. Dash takes about 30 minutes to run through the tutorial.

I'd also recommend checking out:

  • The Dash announcement letter. This is a comprehensive introduction to Dash including examples, architecture, and a discussion about licensing (MIT).
  • Live examples of Dash Apps in the Dash App Gallery

There are some high-level features of Dash (these are covered in the announcement letter in more detail)

  • Dash Apps require very little boilerplate to get started - a simple "hello world" Dash app that dynamically displays a graph based off of a dropdown's value weighs in under 50 lines of code.
  • Dash Apps are generated entirely from Python, even the HTML and JS
  • Dash Apps bind interactive components (dropdowns, graphs, sliders, text inputs) with your own Python code through reactive Dash "callbacks".
  • Dash Apps are "reactive" which means that it's easy to reason about complicated UIs with multiple inputs, multiple outputs, and inputs that depend on other inputs.
  • Dash Apps are inherently multi-user apps as the "state" of the app is entirely in the client: multiple users can view apps and have independent sessions.
  • Since Dash has a traditional stateless backend, it's easy to scale apps to serve hundreds or thousands of users by scaling up the number of worker processes. Requests are sent to whichever worker is available, enabling a small number of workers to service a larger number of sessions.
  • Dash uses React.js to render components and includes a plugin system for creating your own Dash components with React.
  • Dash's Graph component is interactive, allowing Dash app authors to write applications that respond to hovering, clicking, or selecting points on the graph.

I also found the Plotly documentation quite unclear on what exactly is Open Source and whether the data gets uploaded to them or if the plotting can be done offline?

It sounds like this is referring to the plotly.py graphing library. This is a separate library than Dash. Both libraries use the MIT licensed plotly.js library for creating charts. plotly.js doesn't send any data to the plotly server - it's completely client-side.

The plotly.py library includes methods to send the data to your online plotly account for hosting, sharing, and editing the charts but it's completely opt-in. Again, plotly.py is a separate library than Dash. plotly.py is for interactive graphing, Dash is for creating interactive applications (which can include charts).

In particular in a multi-user deployment? There are clearly two modes for the underlying Plotly library but what mode does Dash operate in?

  • Dash is MIT licensed. You can run Dash on your own servers or on your machine.
  • Dash uses a Flask server, so you can deploy Dash apps in the same way that you would deploy Flask apps
  • Plotly licenses Dash Enterprise, a platform that can be installed on your own infrastructure. Dash Enterprise is a "PaaS" that makes it easy to deploy apps on your own servers, SSO/LDAP authentication, additional design capabilities, additional app capabilities, and more.
Share:
40,729

Related videos on Youtube

rsutormin
Author by

rsutormin

Updated on February 26, 2020

Comments

  • rsutormin
    rsutormin about 4 years

    Dash by Plotly looks like a great way for a Python developer to create interactive web apps without having to learn Javascript and Front End Web development. Another great project with similar aims and scope is Jupyter Dashboards.

    What are the pros and cons of each?

    In particular in a multi-user deployment? I also found the Plotly documentation quite unclear on what exactly is Open Source and whether the data gets uploaded to them or if the plotting can be done offline? There are clearly two modes for the underlying Plotly library but what mode does Dash operate in?

    • Chris P
      Chris P almost 7 years
      This comment is comparing plotly.py with matplotlib. The question by the OP is concerning Dash with Jupyter Dashboards: Dash is for creating interactive web-apps, plotly.py is for graphing. They are separate libraries with separate purposes! Dash uses plotly.js for it's core Graph component but matplotlib could also be used through the dash_html_components.Img component.
  • volodymyr
    volodymyr almost 7 years
    Both projects are completely free and OS. In fact, all code is on github and you can contribute - they very much accept pull-requests. I am not affiliated with plotly, but I have lot's of respect for what they are doing for community. From your answer one may assume that plotly dash is not free, which is wrong. They do offer consultancy, but lots of people would happy to take your money for Jupyter consulting
  • Shawn S
    Shawn S almost 7 years
    Thats good to know. I saw something about pricing for plotty dashboards maybe it was hosting or something, I dont know. I'll give it another look as using notebooks for dashboards is kind of like a square peg in a round hole. Thank you.
  • Nikolay Fominyh
    Nikolay Fominyh about 5 years
    Great, Chris... What about cons of your product? Do you see them?
  • Toby
    Toby almost 5 years
    Dash Apps require very little boilerplate to get started - a simple "hello world" Dash app is under 50 lines of code. So, to me, 49 lines of boilerplate per 1 line of code seems quite a lot of boilerplate.
  • Chris P
    Chris P about 4 years
    Updated - It's not just printing "Hello World", it's really creating and running a web application that renders a graph based dynamically from a dropdown.