Skip to content

Commit

Permalink
Merge pull request #12 from UI-Research/dev
Browse files Browse the repository at this point in the history
Page Layout + Styles Update
  • Loading branch information
malcalakovalski authored Apr 24, 2024
2 parents a68767e + 1447bbd commit e6ff3ec
Show file tree
Hide file tree
Showing 6 changed files with 138 additions and 228 deletions.
38 changes: 16 additions & 22 deletions _quarto.yaml
Original file line number Diff line number Diff line change
@@ -1,49 +1,43 @@
project:
type: website
output-dir: _site
execute-dir: project
render:
- index.qmd
- glossary.qmd
- scripts/index.qmd
- scripts/glossary.qmd
website:
title: ""
page-navigation: true
navbar:
search: true
pinned: true
tools:
- icon: github
menu:
- text: Source Code
url: https://github.com/UI-Research/rochester-dashboard
- text: Report a Bug
url: https://github.com/UI-Research/rochester-dashboard/issues
left:
- text: "Federal Recovery Funds Dashboard"
href: index.qmd
- href: glossary.qmd
href: scripts/index.qmd
- href: scripts/glossary.qmd
sidebar:
style: "floating"
background: light
collapse-level: 1
contents:
- scripts/index.qmd
format:
html:
# include-in-header: header.html
css: style.css
# theme:
# - styles.scss
# mainfont: montserrat
page-layout: full
theme:
- styles.scss
mainfont: montserrat
embed-resources: true
code-fold: false
code-link: true
code-line-numbers: true
df-print: default
toc: false
toc: true
toc-title: Contents
toc-depth: 3
toc-location: left
highlight-style: github
smooth-scroll: true
grid:
sidebar-width: 250px
body-width: 800px
margin-width: 250px
gutter-width: 1.5em
execute:
freeze: auto
echo: false
Expand Down
24 changes: 12 additions & 12 deletions renv.lock
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,7 @@
},
"gtable": {
"Package": "gtable",
"Version": "0.3.4",
"Version": "0.3.5",
"Source": "Repository",
"Repository": "RSPM",
"Requirements": [
Expand All @@ -755,7 +755,7 @@
"lifecycle",
"rlang"
],
"Hash": "b29cf3031f49b04ab9c852c912547eef"
"Hash": "e18861963cbc65a27736e02b3cd3c4a0"
},
"haven": {
"Package": "haven",
Expand Down Expand Up @@ -805,14 +805,14 @@
},
"htmltools": {
"Package": "htmltools",
"Version": "0.5.7.9000",
"Version": "0.5.8.9000",
"Source": "GitHub",
"RemoteType": "github",
"RemoteHost": "api.github.com",
"RemoteRepo": "htmltools",
"RemoteUsername": "rstudio",
"RemoteRef": "HEAD",
"RemoteSha": "30d13a16c4bfb84b435e9aa772501f39cf9b6f0e",
"RemoteRepo": "htmltools",
"RemoteRef": "main",
"RemoteSha": "038ef7be3b02a9248f122b745ad7830cc429d437",
"Requirements": [
"R",
"base64enc",
Expand All @@ -822,7 +822,7 @@
"rlang",
"utils"
],
"Hash": "aaa564dc7ed9ac12ebf5d6fcf4a9dc86"
"Hash": "46560a1c802adc01f9feb8e968d73db1"
},
"httr": {
"Package": "httr",
Expand Down Expand Up @@ -1053,14 +1053,14 @@
},
"munsell": {
"Package": "munsell",
"Version": "0.5.0",
"Version": "0.5.1",
"Source": "Repository",
"Repository": "RSPM",
"Requirements": [
"colorspace",
"methods"
],
"Hash": "6dfe8bf774944bd5595785e3229d8771"
"Hash": "4fd8900853b746af55b81fda99da7695"
},
"nlme": {
"Package": "nlme",
Expand Down Expand Up @@ -1455,9 +1455,9 @@
},
"sf": {
"Package": "sf",
"Version": "1.0-16",
"Version": "1.0-17",
"Source": "Repository",
"Repository": "RSPM",
"Repository": "https://r-spatial.r-universe.dev",
"Requirements": [
"DBI",
"R",
Expand All @@ -1474,7 +1474,7 @@
"units",
"utils"
],
"Hash": "ad57b543f7c3fca05213ba78ff63df9b"
"Hash": "8b62cc43018a2ce8e7abefb7835633d7"
},
"snakecase": {
"Package": "snakecase",
Expand Down
File renamed without changes.
63 changes: 32 additions & 31 deletions index.qmd → scripts/index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ fig-height: 6
librarian::shelf(
tidyverse,
here,
urbnthemes,
UrbanInstitute/urbnthemes,
gt,
tidycensus,
mapview,
Expand Down Expand Up @@ -67,13 +67,13 @@ racf_pal <-
<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Merriweather" />


![](www/images/act-logo.png){width=800 fig-align="center"}
![](../www/images/act-logo.png){width=800 fig-align="center"}

<center>

<h1> Rochester Region Federal Funds Dashboard </h1>
# Rochester Region Federal Funds Dashboard {toc-text="Introduction"}

<h4> How the Rochester Region Is Spending Federal Recovery Dollars </h4>
#### How the Rochester Region Is Spending Federal Recovery Dollars

**This dashboard is a draft undergoing active development. It should not be shared or used for analysis.**

Expand Down Expand Up @@ -200,7 +200,7 @@ building blocks of an inclusive recovery and equitable growth, shown below.

[![Source: Adapted from Poethig et al 2018 in collaboration with community
stakeholders across the
country](www/images/building-blocks.png){fig-align="center"}](https://www.urban.org/research/publication/inclusive-recovery-us-cities)
country](../www/images/building-blocks.png){fig-align="center"}](https://www.urban.org/research/publication/inclusive-recovery-us-cities)

The dashboard is laid out as follows:

Expand Down Expand Up @@ -309,11 +309,11 @@ pct_allocated_inclusive_recovery |>
)
```

## These Data in Action
### These Data in Action

These number have real effects on people’s lives. For example, [insert GI recipient’s name], seen below, received funding through the City of Rochester’s Guaranteed income pilot. This means that she received $X each month over [time period]. This helped her XYZ.

![Source: XYZ](www/images/example-data-story.png)
![Source: XYZ](../www/images/example-data-story.png)

Out of the 65% of funds allocated to programs that align with the five building
blocks of an inclusive recovery, the most funding has been allocated to
Expand Down Expand Up @@ -374,11 +374,11 @@ data_reordered %>%
```


## How might Rochester invest more in some of these building blocks?
### How might Rochester invest more in some of these building blocks?

Other places have found ways to use federal funds to invest in stabilizing housing, building wealth, and creating jobs. For instance, the City of Boston is using ARPA funds to transform publicly-owned land into green, mixed income communities. One project in Chinatown, shown below, will include 83 affordable rental units and 36 affordable homeownership units. The property is a short walk to two train stops and is located in a walkable and bikeable neighborhood. The project was developed after extensive community engagement with nearby neighbors and will also be energy efficient and follow the City of Boston’s Carbon Free, Climate Resilient, and Healthy Community goals.

![Source: XYZ](www/images/example-data-story2.jpg)
![Source: XYZ](../www/images/example-data-story2.jpg)


## What policy areas are being funded?
Expand Down Expand Up @@ -417,7 +417,7 @@ bottom3 <-
str_to_lower()
```

::: panel-tabset
::: {.panel-tabset .nav-pills}
## Allocated

```{r}
Expand Down Expand Up @@ -492,15 +492,15 @@ data %>%
```
:::

## What subtopics are funded within each policy area?
### What subtopics are funded within each policy area?

The figure below provides a more detailed breakdown of allocations to each
policy area. Each policy area tab breaks down the allocations into subtopics.
For example, most of the money allocated to community and economic development
has gone to workforce development.

::: panel-tabset
### Community and Economic Development
#### Community and Economic Development

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -528,7 +528,7 @@ data %>%
labs(x = NULL, y = "Total allocation")
```

### Infrastructure
#### Infrastructure

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -556,7 +556,7 @@ data %>%
labs(x = NULL, y = "Total allocation")
```

### Housing
#### Housing

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -584,7 +584,7 @@ data %>%
labs(x = NULL, y = "Total allocation")
```

### Public Safety
#### Public Safety

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -612,7 +612,7 @@ data %>%
labs(x = NULL, y = "Total allocation")
```

### Social Services
#### Social Services

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -640,7 +640,7 @@ data %>%
labs(x = NULL, y = "Total allocation")
```

### Public Health
#### Public Health

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -668,7 +668,7 @@ data %>%
labs(x = NULL, y = "Total allocation")
```

### Operations
#### Operations

```{r}
#| fig-cap: !expr source
Expand Down Expand Up @@ -697,7 +697,7 @@ data %>%
```
:::

## What does this look like in action?
### What does this look like in action?

PLACEHOLDER TEXT

Expand Down Expand Up @@ -760,7 +760,7 @@ pct_spent |>
)
```

## How does funding align with the Rochester Area Community Foundation's priorities?
### How does funding align with the Rochester Area Community Foundation's priorities?

```{r racf-funding-pct}
#| label: racf-funding-pct
Expand Down Expand Up @@ -880,7 +880,7 @@ data %>%
labs(x = NULL, y = "Total Allocation")
```

## An example: RENEW
### An example: RENEW

PLACEHOLDER TEXT

Expand Down Expand Up @@ -944,12 +944,14 @@ spending <-
genesee_spending <-
spending %>% filter(str_detect(`Street`, "873|Genesee"))
Sys.setenv(PROJ_LIB = "")
project_locations <-
read_csv("data/data-raw/addresses-geocoded.csv") %>%
janitor::clean_names() %>%
filter(longitude != 0) %>%
sf::st_as_sf(coords = c("longitude", "latitude"), crs = 4326) %>%
st_transform(st_crs(4326)) %>%
filter(longitude != 0) |>
st_as_sf(coords = c("longitude", "latitude"),
crs = 4326) |>
st_transform(crs = 4326) %>%
filter(type == "arpa_spending_status") %>%
distinct(match_addr, .keep_all = TRUE) %>%
left_join(spending, by = c("f_address" = "Street")) %>%
Expand All @@ -959,7 +961,8 @@ project_locations <-
`ARPA Funding` = if_else(str_detect(match_addr, "873|Genesee"), genesee_spending$`ARPA Funding`, `ARPA Funding`),
`Arpa funding numeric` = if_else(str_detect(match_addr, "873|Genesee"), genesee_spending$`Arpa funding numeric`, `Arpa funding numeric`)
) %>%
drop_na(`Project name`)
drop_na(`Project name`) |>
mutate(type = if_else(type == "arpa_spending_status", "City of Rochester Capital Projects", type))
```

```{r}
Expand Down Expand Up @@ -1011,9 +1014,7 @@ my_label <- glue::glue("<strong>{project_locations$`Project name`}</strong> ({pr
map(htmltools::HTML)
project_location_map <-
mapview(
project_locations %>%
mutate(type = if_else(type == "arpa_spending_status", "City of Rochester Capital Projects", type)),
mapview(project_locations,
zcol = "type", cex = "Arpa funding numeric", col.regions = "grey",
popup = my_popup,
label = my_label,
Expand Down Expand Up @@ -1156,11 +1157,11 @@ hispanic_map + project_location_map

<br>

## What does this look like?
### What does this look like?

HINGE EXAMPLE PLACEHOLDER TEXT

![Source: XYZ](www/images/example-data-story3.png)
![Source: XYZ](../www/images/example-data-story3.png)

## Explore All Programs Funded {#programs-table}

Expand All @@ -1177,7 +1178,7 @@ table.
Data current as of: `r last_update_date`

```{r}
#|label: "programs-table"
#| label: "programs-table"
data %>%
# Should subtopic be included?
select(
Expand Down
Loading

0 comments on commit e6ff3ec

Please sign in to comment.