Season | Result | UNC Score | Opp Score | Ref 1 | Ref 2 | Ref 3 | Spread | Location |
---|---|---|---|---|---|---|---|---|
2019 | L | 73 | 74 | Roger Ayers | Jamie Luckie | Clarence Armstrong | 3.5 | neutral |
2019 | W | 79 | 70 | Roger Ayers | Ted Valentine | Bill Covington Jr. | -4.5 | home |
2019 | W | 88 | 72 | Mike Eades | Brian Dorsey | Ron Groover | 9.5 | away |
2018 | W | 74 | 69 | Mike Eades | Ted Valentine | Bert Smith | 4 | neutral |
2018 | L | 64 | 74 | Roger Ayers | Mike Eades | Raymond Styons | 7.5 | away |
2018 | W | 82 | 78 | Jeff Clark | Jamie Luckie | Ron Groover | -1.5 | home |
2017 | L | 83 | 93 | Bria |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a script to guess _how_ the NET is computed | |
# Credit for almost all of this work goes to bchare: https://github.com/bchare/ncaabball | |
# This is an attempt to transform his Python code into R | |
# ----------------------------------------------------------- | |
# Gamelogs are loaded from the following repo: | |
# This fetches data from cbbdata/torvik and saves a daily csv | |
# Job runs around 7 am ET each day to fetch data | |
gamelogs <- readr::read_csv( | |
"https://raw.githubusercontent.com/gallochris/evdev-byc/refs/heads/main/data/cbb_daily_gamelog.csv" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# First, use hoopR to grab the kenpom data for continuity and experience | |
meta_metrics <- hoopR::kp_height(min_year = 2024, max_year = 2024) | |
# now load the seed data and filter out teams that already lost | |
seeds <- | |
readr::read_csv( | |
"https://gist.githubusercontent.com/gallochris/86fc2a21dd4b30e3dd9ea79516594f05/raw/1e2dfa7eae2d196f5dee9ecf5fe95e5f76ba827d/ncaat_seeds.csv" | |
) |> | |
dplyr::select(seed = Seed, | |
team = Team, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# use bigballR to fetch schedule | |
schedule <- | |
bigballR::get_team_schedule(season = "2023-24", team.name = "North Carolina") | |
# grab miami home game pbp | |
unc_miami_pbp <- bigballR::get_play_by_play(schedule$Game_ID[28]) | |
# add index to determine first half and second half | |
um_index <- which(unc_miami_pbp$Half_Status == 2)[1] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Attempt to recreate or riff on the plot from the Tufte book | |
# https://opticalacumen.blogspot.com/2014/07/data-visualization-in-1919.html | |
# Fetch the player minutes data by game over past three seasons | |
hubert <- | |
cbbdata::cbd_torvik_game_factors(team = "North Carolina") |> | |
dplyr::filter(year > 2021) |> | |
dplyr::arrange(date) |> | |
dplyr::mutate(off_ppp = format(round(off_ppp / 100, 2), nsmall = 2), | |
def_ppp = format(round(def_ppp / 100, 2), nsmall = 2)) |> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
game_date | game_id | team | opponent | location | result | points_scored | points_allowed | diff | year | ||
---|---|---|---|---|---|---|---|---|---|---|---|
1 | 20190112 | 2826 | North Carolina | Louisville | Home | L | 83 | 62 | 21 | 2019 | |
2 | 20190115 | 3021 | North Carolina | Notre Dame | Home | W | 75 | 69 | 6 | 2019 | |
3 | 20190121 | 3312 | North Carolina | Virginia Tech | Home | W | 103 | 82 | 21 | 2019 | |
4 | 20190205 | 3986 | North Carolina | N.C. State | Home | W | 113 | 96 | 17 | 2019 | |
5 | 20190209 | 4125 | North Carolina | Miami FL | Home | W | 88 | 85 | 3 | 2019 | |
6 | 20190211 | 4288 | North Carolina | Virginia | Home | L | 69 | 61 | 8 | 2019 | |
7 | 20190223 | 4795 | North Carolina | Florida St. | Home | W | 77 | 59 | 18 | 2019 | |
8 | 20190226 | 4958 | North Carolina | Syracuse | Home | W | 93 | 85 | 8 | 2019 | |
9 | 20190309 | 5420 | North Carolina | Duke | Home | W | 79 | 70 | 9 | 2019 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(rvest) | |
library(dplyr) | |
library(janitor) | |
library(stringr) | |
# load data | |
url <- | |
'https://www.sports-reference.com/cfb/play-index/sgl_finder.cgi?request=1&match=game&year_min=2019&year_max=2021&school_id=north-carolina&c1stat=points&c1comp=gt&c1val=1&c2stat=opp_points&c2comp=gt&c2val=1&c3comp=gt&c4comp=gt&order_by=date_game#results' | |
mack_raw <- url %>% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(gt) | |
# make the data - https://www.wynnbet.com/theplaybook/posts/wynnbet-releases-odds-for-upcoming-men-s-college-basketball-season-01ffk34jmvek | |
odds <- tibble::tribble( | |
~team, ~win, ~nt, ~ff, | |
"Gonzaga", 33.5, 11.1, 33.3, | |
"UCLA", 31, 7.7, 25.0, | |
"Michigan", 27, 7.7, 25.0, | |
"Memphis", 32, 6.3, 20.0, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(gt) | |
# make the data | |
injury <- tibble::tribble( | |
~Opp,~Anthony,~Keeling,~Robinson,~Black,~Brooks,~Bacot,~Pierce,~Platek,~Francis,~Harris,~Manley, | |
"Notre Dame",37,21,0,33,39,23,20,26,0,0,0, | |
"at UNC-Wilmington",34,23,0,32,33,3,32,27,0,0,0, | |
"Gardner-Webb",33,30,0,34,30,23,21,23,0,0,0, | |
"Elon",36,25,0,27,33,26,23,18,0,0,0, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
G | W | Product | |
---|---|---|---|
1 | 1 | 2004 | |
2 | 2 | 2004 | |
3 | 3 | 2004 | |
4 | 4 | 2004 | |
5 | 5 | 2004 | |
6 | 6 | 2004 | |
7 | 6 | 2004 | |
8 | 7 | 2004 | |
9 | 8 | 2004 |
NewerOlder