Skip to content

Commit

Permalink
Merge pull request #3 from posit-dev/dashboard-updates-3
Browse files Browse the repository at this point in the history
Dashboard slide updates + add bio
  • Loading branch information
skaltman committed Sep 18, 2024
2 parents f9f83b2 + 8b8c9df commit c0a2915
Show file tree
Hide file tree
Showing 22 changed files with 53 additions and 46 deletions.
15 changes: 8 additions & 7 deletions 1-hello-dashboards/1-hello-dashboards.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@
title: "Hello, dashboards!"
subtitle: "Small Data SF"
author:
- name: Sara Altman and Isabella Velásquez
- name: Sara Altman
affiliations:
- name: Posit, PBC
- name: Isabella Velásquez
affiliations:
- name: Posit, PBC
date: "2024-09-23"
# TODO: FIX LINK
footer: "[pos.it/quarto-dashboards-24](https://pos.it/quarto-dashboards-24)"
footer: "[pos.it/small-data-sf-quarto-workshop](https://pos.it/small-data-sf-quarto-workshop)"
logo: "../images/slides-logo.png"
format:
revealjs:
Expand Down Expand Up @@ -61,15 +63,14 @@ quarto --version

## {.no-line background-image="images/dashboards/stock-explorer.png" background-size="contain"}

## 🍰 Olympic Games dashboard - Python
## 🍰 Olympic Games dashboard

<!-- TODO: update link-->
::: python-box
🔗 [mine.quarto.pub/olympic-games-py](https://mine.quarto.pub/olympic-games-py/)
🔗 [https://saraaltman.quarto.pub/olympic-games/](https://saraaltman.quarto.pub/olympic-games/)
:::

```{=html}
<iframe src="https://mine.quarto.pub/olympic-games-py/" title = "Olympic Games dashboard" frameborder="1" height="575" width="1200"></iframe>
<iframe src="https://saraaltman.quarto.pub/olympic-games/" title = "Olympic Games dashboard" frameborder="1" height="575" width="1200"></iframe>
```

## Notebook ➝ Dashboard
Expand Down
Binary file removed 1-hello-dashboards/images/first-dashboard-r-1.png
Binary file not shown.
Binary file removed 1-hello-dashboards/images/first-dashboard-r-2.png
Binary file not shown.
Binary file removed 1-hello-dashboards/images/first-dashboard-r-3.png
Binary file not shown.
Binary file modified 1-hello-dashboards/images/olympicdash-py-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed 1-hello-dashboards/images/olympicdash-r-1.png
Binary file not shown.
73 changes: 37 additions & 36 deletions 2-components-theming/2-components-theming.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@
title: "Dashboard components and themes"
subtitle: "Small Data SF"
author:
- name: Sara Altman and Isabella Velásquez
- name: Sara Altman
affiliations:
- name: Posit, PBC
- name: Isabella Velásquez
affiliations:
- name: Posit, PBC
date: "2024-09-23"
# TODO: fix link
footer: "[pos.it/quarto-dashboards-24](https://pos.it/quarto-dashboards-24)"
footer: "[pos.it/small-data-sf-quarto-workshop](https://pos.it/small-data-sf-quarto-workshop)"
logo: "../images/slides-logo.png"
format:
revealjs:
Expand Down Expand Up @@ -527,66 +529,67 @@ Clone the GitHub repo `posit-dev/smalldatasf-quarto-exercises` (<http://pos.it/s

Your goal is to create a dashboard that looks like the following:

![](images/olympicdash-r-2.png)
![](images/olympicdash-2.png)

## Step 1 {.smaller}

::: your-turn
- Add two pages - one for Summer Olympics and one for Winter Olympics.
- Duplicate existing dashboard content for the two types of olympic games with subsets of data from the corresponding season.

- Make the columns 65% (first) and 35% (second) of width of the dashboard.
- Divide the first column into rows of 60% (first) and 40% (second) of height of the dashboard.
- In the second row of the first column, combine markdown text about cancelled olympic games with the medals by year plot in the same cell.
:::

![](images/olympicdash-r-2-step-1.png)
![](images/olympicdash-2-step-1.png)

{{< countdown minutes=5 >}}

## Step 2 {.smaller}

::: your-turn
In the Summer Olympics page:
- Divide the second column into rows of 25% (first) and 75% (second) of height of the dashboard.
- In the first row of this second column, add value boxes for highest numbers of gold, silver, and bronze medals with appropriate color for each medal and using the `award-fill` icon.
:::

- Make the columns 65% (first) and 35% (second) of width of the dashboard.
- Divide the first column into rows of 60% (first) and 40% (second) of height of the dashboard.
- In the second row of the first column, combine markdown text about cancelled olympic games with the medals by year plot in the same cell.
::: callout-tip
Use the code (commented with `TODO for Step 2`) at the bottom of the document to help you create the value boxes. Un-comment the code and move the code chunk to the appropriate location. Then, use the resulting variables to create the value boxes.
:::

![](images/olympicdash-r-2-step-2.png)
![](images/olympicdash-2-step-2.png)

{{< countdown minutes=5 >}}
{{< countdown minutes=10 >}}

## Step 3 {.smaller}

::: your-turn
In the Summer Olympics page:

- Divide the second column into rows of 25% (first) and 75% (second) of height of the dashboard.
- In the second row of the second column, create tables (using **great_tables** for Python) of top 30 and bottom 30 total medals by team, sorted in descending order for the top 30 and ascending order for the bottom 30 total medals, and add color to the table based on data values.
- In the second row of the second column, create tables (using the **great_tables** library) of top 30 and bottom 30 total medals by team, sorted in descending order for the top 30 and ascending order for the bottom 30 total medals, and add color to the table based on data values.
- Place these tables in tabsets with descriptive text about table content in the same card/tab.
:::

![](images/olympicdash-r-2-step-3.png)

{{< countdown minutes=10 >}}

## Step 4 {.smaller}

::: your-turn
In the first row of the second column of the Summer Olympics page, add value boxes for highest numbers of gold, silver, and bronze medals with appropriate color for each medal and using the `award-fill` icon.
::: callout-tip
Use the code (commented with `TODO for Step 3`) at the bottom of the document to help you create the tables. Un-comment the code and move the code chunk to the appropriate location. Then, use `olympics_sorted_descending_top30` and `olympics_sorted_ascending_bottom30` to create the tables.
:::

![](images/olympicdash-r-2-step-4.png)
![](images/olympicdash-2-step-3.png)

{{< countdown minutes=10 >}}

## Step 5 {.smaller}
## Interactive plotting {.smaller}

::: your-turn
Duplicate dashboard content for the Winter Olympics page, share your results with your neighbor, and discuss approaches for not repeating yourself in your code.
- We've been creating static plots with `plotnine`
- But you can also add interactive plots to your dashboard, e.g., with `plotly`

::: python-box
🔗 [https://saraaltman.quarto.pub/olympicdash-plotly/](https://saraaltman.quarto.pub/olympicdash-plotly/)
:::

![](images/olympicdash-r-2-step-5.png)

{{< countdown minutes=5 >}}
##

```{=html}
<iframe src="https://saraaltman.quarto.pub/olympicdash-plotly/" title = "Olympic Games dashboard, with plotly" height="900" width="1440"></iframe>
```

# Theming

Expand Down Expand Up @@ -653,17 +656,15 @@ Quarto dashboards can be styled with one of the 25 themes from the Bootswatch pr

Your goal is to create a dashboard that looks like the following:

![](images/olympicdash-py-3.png)
![](images/olympicdash-3.png)

## Step 1 {.smaller}

::: your-turn
- Update the theme to the appropriate Bootswatch theme.
:::

::: callout-tip
Work with your neighbor if you're having difficulty finding which theme to use.
:::

![](images/olympicdash-py-3.png)
![](images/olympicdash-3.png)

{{< countdown minutes=3 >}}

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2-components-theming/images/olympicdash-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added 2-components-theming/images/olympicdash-3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed 2-components-theming/images/olympicdash-py-3.png
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed 2-components-theming/images/olympicdash-r-2.png
Binary file not shown.
Binary file removed 2-components-theming/images/olympicdash-r-3.png
Binary file not shown.
9 changes: 6 additions & 3 deletions 3-deployment/3-deployment.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@
title: "Deploy your dashboard"
subtitle: "Small Data SF"
author:
- name: Sara Altman and Isabella Velásquez
- name: Sara Altman
affiliations:
- name: Posit, PBC
- name: Isabella Velásquez
affiliations:
- name: Posit, PBC
date: "2024-09-23"
footer: "[pos.it/quarto-dashboards-24](https://pos.it/quarto-dashboards-24)"
footer: "[pos.it/small-data-sf-quarto-workshop](https://pos.it/small-data-sf-quarto-workshop)"
logo: "../images/slides-logo.png"
format:
revealjs:
Expand Down Expand Up @@ -111,7 +114,7 @@ Deploy your latest dashboard to [Posit Connect Cloud](https://connect.posit.clou
* Select your dashboard repository
* Click Publish

{{< countdown minutes=10 >}}
{{< countdown minutes=5 >}}

# Wrap up

Expand Down
2 changes: 2 additions & 0 deletions index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ Quarto is an innovative, open-source publishing system from Posit that transform

[**Isabella Velásquez**](https://ivelasq.rbind.io/) is a Senior Product Marketing Manager at Posit Software, where she develops strategic content to increase brand visibility and drive product adoption. With a background in data analysis, reporting, and visualization using tools like R, SQL, and Python, Isabella has honed her skills across multiple industries, including her previous role at the Bill & Melinda Gates Foundation. She holds an MS in Analytics and a BA in Economics and East Asian Languages and Civilizations from the University of Chicago. Isabella is also an educator, sharing her expertise in data science as an instructor and teaching assistant at the University of Tennessee, Knoxville and the University of Chicago.

[**Sara Altman**] is a Data Science Educator at Posit on the Developer Relations team. She creates technical content to help developers and data scientists achieve their goals with Posit tools. Prior to joining the Developer Relations team, she worked on [Posit Academy](https://posit.co/products/enterprise/academy/), Posit's educational platform. Before Posit, Sara taught data science and R at Stanford. She holds a MS and BS in Symbolic Systems from Stanford.

------------------------------------------------------------------------

![](https://i.creativecommons.org/l/by/4.0/88x31.png) This work is licensed under a [Creative Commons Attribution 4.0 International License](https://creativecommons.org/licenses/by/4.0/).

0 comments on commit c0a2915

Please sign in to comment.