Press "Enter" to skip to content

Category: Visualization

Using Shiny on Python

David Saipe crosses the streams:

As someone who has zero experience using Shiny in R, the recent announcement that the framework had been made available to Python users inspired an opportunity for me to learn a new concept from a different perspective to most of my colleagues. I have been tasked with writing a Python related blog post, and having spent the past few weeks carrying out an analysis of Jumping Rivers’ Twitter data (@jumping_uk), creating a dashboard to display some of my findings and then writing about it seemed like a nice way to cap off my 6-week summer placement at Jumping Rivers.

This post will take you through some of the source code for the dashboard I created, whilst I provide a bit of context for the Twitter project itself. For a more bare-bones tutorial on using Shiny for Python, you can check out another recent Jumping Rivers blog post here. I suggest reading this first.

Read on to see how you can get started with Shiny on Python and what David thinks about the experience.

Comments closed

Useful Add-On Packages for Shiny

Mandy Norrbo has a list:

There are a growing number of Shiny users across the world, and with many users comes an increasing number of open-source “add-on” packages that extend the functionality of Shiny, both in terms of the front end and the back end of an app.

This blog will highlight 5 UI add-on packages that can massively improve your user experience and also just add a bit of flair to your app. Each package will have an associated example app (some more inspired than others) that I’ve created where you can actually see the UI component in action. All code for example apps can be found on our GitHub.

Click through for the list, as well as examples of how they work.

Comments closed

Improving Power BI Q&A with Synonyms

Patrick LeBlanc pulls out the thesaurus:

Most struggle with getting Q&A to be effective in Power BI. Usually this comes down to either model naming or synonyms. Patrick shows you how you can update these and also a nice feature to let you share them with others.

I’ve found the Power BI Q&A component to be a bit tetchy, even with synonyms, when you’re asking for non-trivial slices of the data. Still, what Patrick shows does help a lot.

Comments closed

Power BI Line Chart: Summarized or Split

Prathy Kamasani gives us options:

A colleague of mine came to me with an interesting use case, “ Switch between a summarized value or selected value with multiple legends”. For example, I have five countries and their GDP values. When the end user goes to the report, the user would like to see the average GDP of all countries, but when the user selects single or multiple countries on the slicers, the line chart should show only selected values.

Click through for the guide.

Comments closed

Storytelling from a Dashboard

Amy Esselman hits on a tricky problem with dashboards:

As powerful and as useful as dashboards are, they’re optimized for the exploration of data, not the communication of specific insights. Once we’ve used our dashboards to uncover something worth sharing, we’ll usually be better served by making a separate presentation, designed to bring the findings to light and get others to act upon the information.

The path from dashboard to story might not always be intuitive. This article will use a dashboard from a recent storytelling with data engagement to illustrate how to transform dashboard insights into an action-inspiring story. 

This is especially important if you’re a developer who understand the value of storytelling but doesn’t quite know how to support it while showing arbitrary data.

Comments closed

Variable Definition and Programmatic ggplot2

Sebastian Sauer takes us through an interesting scenario.

No lede here because it’s almost 100% code and headers. A quick description of this is that we can see ways to parse columns in an R DataFrame and plot visuals without hard-coding the column name in our plot definition, using a variable instead.

And I had to rewrite the synopsis above because I used the data science term “variable” until hitting a wall when describing the programming term “variable.”

Comments closed

Debouncing RMarkdown Input

Thomas Williams waits for the keystroke:

This R Markdown snippet demonstrates “debouncing”: waiting until a user stops changing an input, before updating dependent charts and tables. Debouncing is often used in web sites to prevent the user interface “jumping” as data is being entered, especially when the update takes a noticeable amount of time – for instance calling an API or database, or doing a calculation.

Read on to see an abridged example, as well as a link to the full version.

Comments closed

Storytelling and the Brain

Kristyna Hughes recaps a presentation:

To turn our millions of dollars worth of data into actionable insights, we need to tell a story with it. Why a story? Storytelling has been and is a vital way humans understand and share the world around them. If numbers were as interesting and memorable as stories, our classic works of art would be the Pythagorean theorem instead of the Iliad and Odyssey. Listening to a story engages multiple parts of the brain, which is why listening to your great aunt’s story for hours is exhausting, but also why stories are more memorable. Here are the parts of the brain engaged when you hear a story:

There’s a lot to digest in this post, including ways to convert storytelling into data-driven insights.

Comments closed

English and Japanese Vowels

John Cook plots vowels:

Vowel sounds can be visualized in a two-dimensional space according to tongue position. The vertical axis is runs from open down to closed, and the horizontal runs from front to back. See a linguistics textbook for far more detail.

English has five vowel letters, but a lot more than five vowel sounds. Scholars argue about how many vowel sounds English and other languages have because there’s room for disagreement on how much two sounds can differ and still be considered variations on the same sound. The IPA Handbook [1] lists 11 vowel sounds in American English, not counting diphthongs.

Click through for comparative charts and some bonus expertise in the comments.

Comments closed

Using Google Fonts on RMarkdown Pages

Thomas Williams has a change of font:

Setting a different font is a minor tweak to an R Markdown file that might help it fit better with a corporate or company look. Google Fonts is an industry-accepted method to reference fonts on web pages and can be used with R Markdown rendered by Shiny. There’s no need to download anything while developing the R Markdown file in RStudio, or viewing it in a web browser from a Shiny server.

I’ve recently used this technique to integrate the “Atkinson Hyperlegible” font, a font with “…greater legibility and readability for low vision readers…” from https://brailleinstitute.org/freefont. Since Shiny themes already specify a font, the steps below show how to override that with the Google Font, demo’d with the spacelab Shiny theme.

Click through to see how you can use this font, as well as others, in Shiny apps.

Comments closed