Skip to content

Commit

Permalink
Fix incorrect param name (#9)
Browse files Browse the repository at this point in the history
* Fix incorrect param name

* Try to reduce query size

* Change year calls in rest of doc

* Adjust joins

* Test query size

* Fix ratio figure
  • Loading branch information
wagnerlmichael authored Mar 20, 2024
1 parent de392fb commit 3c0172c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions vignettes/example-ratio-study.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ In general, there are four important statistics produced in sales ratio studies,
| **COD** | 5 - 15 | How often properties with the *same* sale price receive the same predicted market value. Lower CODs indicate more fairness between similarly priced properties. |
| **PRD** | .98 - 1.03 | How often properties with *different* sale prices receive the proportionately different predicted market values. Lower PRDs indicate more fairness between low and high-priced properties. |
| **PRB** | -.05 - .05 | PRB is a different approach to measuring fairness across homes with different sale prices. |
| **Median Ratio** | .095 - 1.05 | The median ratio measures whether the most common ratios accurately reflect sale prices. |
| **Median Ratio** | .95 - 1.05 | The median ratio measures whether the most common ratios accurately reflect sale prices. |
| MKI | .95 - 1.05 | Measures the difference in inequality between assessed valuations and sale prices. |
| Sales Chasing (E.4) | $\le$ 5% | Measures the degree to which the statistics above are *true* reflections of the quality of assessments. |

Expand Down Expand Up @@ -68,7 +68,7 @@ library(stringr)
assessments <- read_json(
paste0(
"https://datacatalog.cookcountyil.gov/resource/uzyt-m557.json?",
"$where=starts_with(class,'2')&year=2020&$limit=100000"
"$where=starts_with(class,'2')&tax_year=2020&$limit=100000"
),
simplifyVector = TRUE
)
Expand Down Expand Up @@ -149,10 +149,10 @@ library(knitr)
# values AND sales
combined <- inner_join(
assessments %>%
select(pin, year, township_name, mailed_tot, certified_tot, board_tot),
select(pin, tax_year, township_name, mailed_tot, certified_tot, board_tot),
sales %>%
select(pin, year, sale_price, is_multisale),
by = c("pin", "year")
by = c("pin", "tax_year" = "year")
) %>%
filter(township_name %in% c("New Trier", "Palatine"))
Expand Down

0 comments on commit 3c0172c

Please sign in to comment.