Men's college basketball — additional Python functions — Analytics: mbb_team–ncaa_box
mbb_team_season_rates
mbb_team_season_rates(seasons: 'int | list[int]', *, league: 'str' = 'mens', return_as_pandas: 'bool' = False) -> 'pl.DataFrame | pd.DataFrame'
College season team rates from possessions: ORtg/DRtg/net, tempo and the four factors, with splits.
One row per team, season and split (all, home, away, close, clutch).
Clutch is a possession in play with 5:00 or less left (starting there, or the one live at the
5:00 mark: it starts before 5:00 and ends after it; one that ends exactly at 5:00 is out) in
the 2nd half (the 4th quarter in women's basketball from 2016) or an overtime, the score
within 5 as it starts; a close game is one with a clutch possession. The full definitions
are in sportsdataverse._common.team_season_rates.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
seasons | int | list[int] | A season or list of seasons, named by the year it ends (2025 is 2024-25). | |
league | str | 'mens' | "mens" or "womens" (sportsdataverse.wbb.wbb_team_season_rates.wbb_team_season_rates). |
return_as_pandas | bool | False | Return a pandas frame instead of polars. |
Returns
One row per (season, team_id, split). team_id is the ESPN team id (Int64). games, poss / opp_poss (offensive / defensive possessions) and pts / opp_pts are the split's totals. The twelve rates are off_rtg, def_rtg, net_rtg (per 100 possessions), pace (possessions per 40 minutes), the four factors efg_pct, tov_pct, orb_pct, ft_rate and the same four against (opp_*), all fractions. The four factors are game-level (the NCAA team box) and null in the clutch split. Each rate has <m>_rank (1 = best; def_rtg, tov_pct, opp_efg_pct, opp_orb_pct and opp_ft_rate rank low first; pace ranks high first), <m>_pct (the Weibull percentile) and <m>_n (the sample: possessions for the ratings, the clock in regulation games for pace, field-goal attempts for eFG% and FT rate, the box possessions for turnover rate, rebound chances for ORB%). Ranks are within the season and split, among teams with at least half the most games (which leaves out the non-D1 opponents) whose <m>_n reaches the league's ~sportsdataverse._common.rate_gates.TEAM_MIN_N gate, and null under five teams. Empty input returns that schema with zero rows.
| col_name | type | description |
|---|---|---|
season | Int64 | Season, named by the year it ends (2025 is 2024-25). |
team_id | Int64 | ESPN team id. Non-D1 opponents have none and get no row. |
split | String | Which possessions the row covers: all; home or away (the team's home or road games; neutral-site games are in neither); close (every possession of a game that had a clutch possession); clutch (a possession in play with 5:00 or less left (starting there, or starting before 5:00 and ending after it) in the 2nd half (the 4th quarter for league='womens' from 2016) or an overtime, the score within 5 as it starts). |
games | Int64 | Games with at least one possession in the split. |
poss | Int64 | Offensive possessions in the split, counted from possession rows. |
opp_poss | Int64 | Defensive possessions in the split (the opponents' offensive possessions). |
pts | Int64 | Points scored on the team's offensive possessions in the split. |
opp_pts | Int64 | Points allowed on the team's defensive possessions in the split. |
off_rtg | Float64 | Offensive rating: points scored per 100 offensive possessions. |
def_rtg | Float64 | Defensive rating: points allowed per 100 defensive possessions. |
net_rtg | Float64 | Net rating: off_rtg minus def_rtg. |
pace | Float64 | Pace: possessions per 40 minutes, the mean of poss and opp_poss over the game clock those possessions used. |
efg_pct | Float64 | Effective field-goal percentage, (FGM + 0.5 * 3PM) / FGA, as a fraction. Game-level, from the NCAA team box; null in the clutch split. |
tov_pct | Float64 | Turnovers per offensive possession, as a fraction. Game-level, from the NCAA team box; null in the clutch split. |
orb_pct | Float64 | Offensive rebound rate: offensive rebounds over offensive-rebound chances (own OREB plus the defense's DREB), as a fraction. Game-level, from the NCAA team box; null in the clutch split. |
ft_rate | Float64 | Free-throw rate, FTA / FGA. Game-level, from the NCAA team box; null in the clutch split. |
opp_efg_pct | Float64 | Opponents' effective field-goal percentage, (FGM + 0.5 * 3PM) / FGA, as a fraction. Game-level, from the NCAA team box; null in the clutch split. |
opp_tov_pct | Float64 | Opponents' turnovers per possession (turnovers forced), as a fraction. Game-level, from the NCAA team box; null in the clutch split. |
opp_orb_pct | Float64 | Opponents' offensive rebound rate, as a fraction (one minus the team's defensive rebound rate). Game-level, from the NCAA team box; null in the clutch split. |
opp_ft_rate | Float64 | Opponents' free-throw rate, FTA / FGA. Game-level, from the NCAA team box; null in the clutch split. |
off_rtg_rank | Float64 | Rank of off_rtg within the season and split (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose off_rtg_n is at least 270 offensive possessions (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
def_rtg_rank | Float64 | Rank of def_rtg within the season and split (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose def_rtg_n is at least 460 defensive possessions (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
net_rtg_rank | Float64 | Rank of net_rtg within the season and split (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose net_rtg_n is at least 430 possessions (offense plus defense) (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
pace_rank | Float64 | Rank of pace within the season and split (the highest value ranks 1; pace has no better direction; ties average), among teams that played at least half the most games any team played in the split, whose pace_n is at least 4 games (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
efg_pct_rank | Float64 | Rank of efg_pct within the season and split (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose efg_pct_n is at least 500 field-goal attempts (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
tov_pct_rank | Float64 | Rank of tov_pct within the season and split (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose tov_pct_n is at least 450 offensive possessions (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
orb_pct_rank | Float64 | Rank of orb_pct within the season and split (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose orb_pct_n is at least 160 offensive-rebound chances (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
ft_rate_rank | Float64 | Rank of ft_rate within the season and split (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose ft_rate_n is at least 530 field-goal attempts (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_efg_pct_rank | Float64 | Rank of opp_efg_pct within the season and split (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose opp_efg_pct_n is at least 630 opponent field-goal attempts (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_tov_pct_rank | Float64 | Rank of opp_tov_pct within the season and split (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose opp_tov_pct_n is at least 340 defensive possessions (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_orb_pct_rank | Float64 | Rank of opp_orb_pct within the season and split (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose opp_orb_pct_n is at least 330 opponent offensive-rebound chances (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_ft_rate_rank | Float64 | Rank of opp_ft_rate within the season and split (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the split, whose opp_ft_rate_n is at least 450 opponent field-goal attempts (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
off_rtg_pct | Float64 | Percentile of off_rtg within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
def_rtg_pct | Float64 | Percentile of def_rtg within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
net_rtg_pct | Float64 | Percentile of net_rtg within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
pace_pct | Float64 | Percentile of pace within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
efg_pct_pct | Float64 | Percentile of efg_pct within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
tov_pct_pct | Float64 | Percentile of tov_pct within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
orb_pct_pct | Float64 | Percentile of orb_pct within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
ft_rate_pct | Float64 | Percentile of ft_rate within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_efg_pct_pct | Float64 | Percentile of opp_efg_pct within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_tov_pct_pct | Float64 | Percentile of opp_tov_pct within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_orb_pct_pct | Float64 | Percentile of opp_orb_pct within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_ft_rate_pct | Float64 | Percentile of opp_ft_rate within the season and split among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
off_rtg_n | Int64 | Sample size of off_rtg: the team's offensive possessions in the split. |
def_rtg_n | Int64 | Sample size of def_rtg: the team's defensive possessions in the split. |
net_rtg_n | Int64 | Sample size of net_rtg: the team's offensive plus defensive possessions in the split. |
pace_n | Int64 | Sample size of pace: the game clock the split's possessions used, in regulation games (48 minutes, 40 in the WNBA and college), rounded: a full game counts 1, a clutch split's five-minute windows about 0.1 each. |
efg_pct_n | Int64 | Sample size of efg_pct: the team's field-goal attempts in the split, 0 when the rate is null. |
tov_pct_n | Int64 | Sample size of tov_pct: the NCAA team box's possessions (o_poss) in the split, 0 when the rate is null. |
orb_pct_n | Int64 | Sample size of orb_pct: the team's offensive-rebound chances in the split, 0 when the rate is null. |
ft_rate_n | Int64 | Sample size of ft_rate: the team's field-goal attempts in the split, 0 when the rate is null. |
opp_efg_pct_n | Int64 | Sample size of opp_efg_pct: the opponents' field-goal attempts in the split, 0 when the rate is null. |
opp_tov_pct_n | Int64 | Sample size of opp_tov_pct: the opponents' NCAA team-box possessions in the split, 0 when the rate is null. |
opp_orb_pct_n | Int64 | Sample size of opp_orb_pct: the opponents' offensive-rebound chances in the split, 0 when the rate is null. |
opp_ft_rate_n | Int64 | Sample size of opp_ft_rate: the opponents' field-goal attempts in the split, 0 when the rate is null. |
lg_ft_pct | Float64 | League free-throw percentage in the season and split: every team's FTM over every team's FTA, so free throws can be priced without a second read. From the NCAA team box; null in the clutch split. |
plus_minus | Int64 | Point margin in the split: pts - opp_pts. |
pts_pg | Float64 | Per game: points scored divided by games (BB-G8's per-game basis). |
opp_pts_pg | Float64 | Per game: points allowed divided by games (BB-G8's per-game basis). |
plus_minus_pg | Float64 | Per game: point margin (pts - opp_pts) divided by games (BB-G8's per-game basis). |
pts_per75 | Float64 | Per 75 possessions: 0.75 * off_rtg (BB-G8's per-75 basis). |
opp_pts_per75 | Float64 | Per 75 possessions: 0.75 * def_rtg (BB-G8's per-75 basis). |
plus_minus_per75 | Float64 | Per 75 possessions: 0.75 * net_rtg (BB-G8's per-75 basis). |
pts_pg_rank | Float64 | Rank of pts_pg within the season and split (the highest value ranks 1; ties average), ranked where off_rtg is: among the teams off_rtg_rank qualifies (half the split's most games, and off_rtg_n at least off_rtg's rate_gates gate); null otherwise or with fewer than five qualifiers. Per game is not per possession, so pace reorders it against off_rtg. |
opp_pts_pg_rank | Float64 | Rank of opp_pts_pg within the season and split (the lowest value ranks 1; ties average), ranked where def_rtg is: among the teams def_rtg_rank qualifies (half the split's most games, and def_rtg_n at least def_rtg's rate_gates gate); null otherwise or with fewer than five qualifiers. Per game is not per possession, so pace reorders it against def_rtg. |
plus_minus_pg_rank | Float64 | Rank of plus_minus_pg within the season and split (the highest value ranks 1; ties average), ranked where net_rtg is: among the teams net_rtg_rank qualifies (half the split's most games, and net_rtg_n at least net_rtg's rate_gates gate); null otherwise or with fewer than five qualifiers. Per game is not per possession, so pace reorders it against net_rtg. |
pts_per75_rank | Float64 | Rank of pts_per75: off_rtg_rank, copied (scaling by 0.75 keeps the order: same gate, same ties). |
opp_pts_per75_rank | Float64 | Rank of opp_pts_per75: def_rtg_rank, copied (scaling by 0.75 keeps the order: same gate, same ties). |
plus_minus_per75_rank | Float64 | Rank of plus_minus_per75: net_rtg_rank, copied (scaling by 0.75 keeps the order: same gate, same ties). |
pts_pg_pct | Float64 | Percentile of pts_pg among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_pts_pg_pct | Float64 | Percentile of opp_pts_pg among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
plus_minus_pg_pct | Float64 | Percentile of plus_minus_pg among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
pts_per75_pct | Float64 | Percentile of pts_per75: off_rtg_pct, copied (scaling by 0.75 keeps the order). |
opp_pts_per75_pct | Float64 | Percentile of opp_pts_per75: def_rtg_pct, copied (scaling by 0.75 keeps the order). |
plus_minus_per75_pct | Float64 | Percentile of plus_minus_per75: net_rtg_pct, copied (scaling by 0.75 keeps the order). |
pts_pg_n | Int64 | Sample size of pts_pg: off_rtg_n, the rating's own sample. |
opp_pts_pg_n | Int64 | Sample size of opp_pts_pg: def_rtg_n, the rating's own sample. |
plus_minus_pg_n | Int64 | Sample size of plus_minus_pg: net_rtg_n, the rating's own sample. |
pts_per75_n | Int64 | Sample size of pts_per75: off_rtg_n, copied. |
opp_pts_per75_n | Int64 | Sample size of opp_pts_per75: def_rtg_n, copied. |
plus_minus_per75_n | Int64 | Sample size of plus_minus_per75: net_rtg_n, copied. |
Raises
| Exception | Description |
|---|---|
ValueError | If league is not "mens" or "womens". |
Example
from sportsdataverse.mbb.mbb_team_season_rates import mbb_team_season_rates
rates = mbb_team_season_rates(2025)
rates.filter(split="all").sort("net_rtg_rank").head()
mbb_team_shot_zones
mbb_team_shot_zones(seasons: 'int | list[int]', *, league: 'str' = 'mens', return_as_pandas: 'bool' = False) -> 'pl.DataFrame | pd.DataFrame'
College season shot profile by zone per team, for and allowed: rim / mid / corner 3 / above-the-break 3.
One row per team and season over every game: the team's own attempts and, with an opp_
prefix, its opponents' attempts against it (a non-D1 opponent's attempts included).
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
seasons | int | list[int] | A season or list of seasons, named by the year it ends (2025 is 2024-25). | |
league | str | 'mens' | "mens" or "womens". |
return_as_pandas | bool | False | Return a pandas frame instead of polars. |
Returns
One row per (season, team_id) (the ESPN team id, Int64) with games and the columns of mbb_player_shot_zones for the team and again with an opp_ prefix for its opponents, each rate with <m>_n, <m>_rank and <m>_pct, ranked within the season among teams whose <m>_n reaches the gate and null under five teams. <m>_rank is 1 = highest, except the allowed opp_{z}_fg_pct, where 1 is the lowest. Empty input returns that schema with zero rows.
| col_name | type | description |
|---|---|---|
season | Int64 | Season, named by the year it ends (2025 is 2024-25). |
team_id | Int64 | The team's ESPN team id (Int64). |
games | Int64 | The team's games with a field-goal attempt by or against it. |
fga | Int64 | Field-goal attempts by the team (games). |
fgm | Int64 | Field goals made by the team. |
unlocated_fga | Int64 | Attempts by the team with no real location (the WNBA's 1997-2010 hoop-centre placeholders; 0 elsewhere): counted in fga, in no zone. |
rim_fga | Int64 | Attempts by the team at the rim (within 4 ft, the shot chart's rim zone). |
rim_fgm | Int64 | Makes by the team at the rim (within 4 ft, the shot chart's rim zone). |
rim_ast | Int64 | Assisted makes by the team at the rim (within 4 ft, the shot chart's rim zone). |
mid_fga | Int64 | Attempts by the team in the mid zone (every other two: the chart's paint and mid-range). |
mid_fgm | Int64 | Makes by the team in the mid zone (every other two: the chart's paint and mid-range). |
mid_ast | Int64 | Assisted makes by the team in the mid zone (every other two: the chart's paint and mid-range). |
corner_3_fga | Int64 | Attempts by the team from the corner (a three with |x| >= 21 ft and |y| <= 9 ft, the baseline band). |
corner_3_fgm | Int64 | Makes by the team from the corner (a three with |x| >= 21 ft and |y| <= 9 ft, the baseline band). |
corner_3_ast | Int64 | Assisted makes by the team from the corner (a three with |x| >= 21 ft and |y| <= 9 ft, the baseline band). |
above_break_3_fga | Int64 | Attempts by the team from above the break (every other three). |
above_break_3_fgm | Int64 | Makes by the team from above the break (every other three). |
above_break_3_ast | Int64 | Assisted makes by the team from above the break (every other three). |
opp_fga | Int64 | Allowed: Field-goal attempts by the team's opponents (games). |
opp_fgm | Int64 | Allowed: Field goals made by the team's opponents. |
opp_unlocated_fga | Int64 | Allowed: Attempts by the team's opponents with no real location (the WNBA's 1997-2010 hoop-centre placeholders; 0 elsewhere): counted in opp_fga, in no zone. |
opp_rim_fga | Int64 | Allowed: Attempts by the team's opponents at the rim (within 4 ft, the shot chart's rim zone). |
opp_rim_fgm | Int64 | Allowed: Makes by the team's opponents at the rim (within 4 ft, the shot chart's rim zone). |
opp_rim_ast | Int64 | Allowed: Assisted makes by the team's opponents at the rim (within 4 ft, the shot chart's rim zone). |
opp_mid_fga | Int64 | Allowed: Attempts by the team's opponents in the mid zone (every other two: the chart's paint and mid-range). |
opp_mid_fgm | Int64 | Allowed: Makes by the team's opponents in the mid zone (every other two: the chart's paint and mid-range). |
opp_mid_ast | Int64 | Allowed: Assisted makes by the team's opponents in the mid zone (every other two: the chart's paint and mid-range). |
opp_corner_3_fga | Int64 | Allowed: Attempts by the team's opponents from the corner (a three with |x| >= 21 ft and |y| <= 9 ft, the baseline band). |
opp_corner_3_fgm | Int64 | Allowed: Makes by the team's opponents from the corner (a three with |x| >= 21 ft and |y| <= 9 ft, the baseline band). |
opp_corner_3_ast | Int64 | Allowed: Assisted makes by the team's opponents from the corner (a three with |x| >= 21 ft and |y| <= 9 ft, the baseline band). |
opp_above_break_3_fga | Int64 | Allowed: Attempts by the team's opponents from above the break (every other three). |
opp_above_break_3_fgm | Int64 | Allowed: Makes by the team's opponents from above the break (every other three). |
opp_above_break_3_ast | Int64 | Allowed: Assisted makes by the team's opponents from above the break (every other three). |
rim_fg_pct | Float64 | rim_fgm / rim_fga; null with no attempt. |
rim_freq | Float64 | rim_fga / (fga - unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
rim_ast_pct | Float64 | Share of rim_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
mid_fg_pct | Float64 | mid_fgm / mid_fga; null with no attempt. |
mid_freq | Float64 | mid_fga / (fga - unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
mid_ast_pct | Float64 | Share of mid_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
corner_3_fg_pct | Float64 | corner_3_fgm / corner_3_fga; null with no attempt. |
corner_3_freq | Float64 | corner_3_fga / (fga - unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
corner_3_ast_pct | Float64 | Share of corner_3_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
above_break_3_fg_pct | Float64 | above_break_3_fgm / above_break_3_fga; null with no attempt. |
above_break_3_freq | Float64 | above_break_3_fga / (fga - unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
above_break_3_ast_pct | Float64 | Share of above_break_3_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
opp_rim_fg_pct | Float64 | Allowed: opp_rim_fgm / opp_rim_fga; null with no attempt. |
opp_rim_freq | Float64 | Allowed: opp_rim_fga / (opp_fga - opp_unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
opp_rim_ast_pct | Float64 | Allowed: Share of opp_rim_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
opp_mid_fg_pct | Float64 | Allowed: opp_mid_fgm / opp_mid_fga; null with no attempt. |
opp_mid_freq | Float64 | Allowed: opp_mid_fga / (opp_fga - opp_unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
opp_mid_ast_pct | Float64 | Allowed: Share of opp_mid_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
opp_corner_3_fg_pct | Float64 | Allowed: opp_corner_3_fgm / opp_corner_3_fga; null with no attempt. |
opp_corner_3_freq | Float64 | Allowed: opp_corner_3_fga / (opp_fga - opp_unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
opp_corner_3_ast_pct | Float64 | Allowed: Share of opp_corner_3_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
opp_above_break_3_fg_pct | Float64 | Allowed: opp_above_break_3_fgm / opp_above_break_3_fga; null with no attempt. |
opp_above_break_3_freq | Float64 | Allowed: opp_above_break_3_fga / (opp_fga - opp_unlocated_fga): the zone's share of the located attempts (the four zones add up to 1); null with none. |
opp_above_break_3_ast_pct | Float64 | Allowed: Share of opp_above_break_3_fgm that were assisted, over the makes linked to a play-by-play row (whose assist is known); null with none. |
rim_fg_pct_n | Int64 | Sample size of rim_fg_pct: rim_fga. |
rim_freq_n | Int64 | Sample size of rim_freq: located attempts (fga - unlocated_fga). |
rim_ast_pct_n | Int64 | Sample size of rim_ast_pct: makes linked to a play-by-play row in the zone. |
mid_fg_pct_n | Int64 | Sample size of mid_fg_pct: mid_fga. |
mid_freq_n | Int64 | Sample size of mid_freq: located attempts (fga - unlocated_fga). |
mid_ast_pct_n | Int64 | Sample size of mid_ast_pct: makes linked to a play-by-play row in the zone. |
corner_3_fg_pct_n | Int64 | Sample size of corner_3_fg_pct: corner_3_fga. |
corner_3_freq_n | Int64 | Sample size of corner_3_freq: located attempts (fga - unlocated_fga). |
corner_3_ast_pct_n | Int64 | Sample size of corner_3_ast_pct: makes linked to a play-by-play row in the zone. |
above_break_3_fg_pct_n | Int64 | Sample size of above_break_3_fg_pct: above_break_3_fga. |
above_break_3_freq_n | Int64 | Sample size of above_break_3_freq: located attempts (fga - unlocated_fga). |
above_break_3_ast_pct_n | Int64 | Sample size of above_break_3_ast_pct: makes linked to a play-by-play row in the zone. |
opp_rim_fg_pct_n | Int64 | Sample size of opp_rim_fg_pct: opp_rim_fga. |
opp_rim_freq_n | Int64 | Sample size of opp_rim_freq: located attempts (opp_fga - opp_unlocated_fga). |
opp_rim_ast_pct_n | Int64 | Sample size of opp_rim_ast_pct: makes linked to a play-by-play row in the zone. |
opp_mid_fg_pct_n | Int64 | Sample size of opp_mid_fg_pct: opp_mid_fga. |
opp_mid_freq_n | Int64 | Sample size of opp_mid_freq: located attempts (opp_fga - opp_unlocated_fga). |
opp_mid_ast_pct_n | Int64 | Sample size of opp_mid_ast_pct: makes linked to a play-by-play row in the zone. |
opp_corner_3_fg_pct_n | Int64 | Sample size of opp_corner_3_fg_pct: opp_corner_3_fga. |
opp_corner_3_freq_n | Int64 | Sample size of opp_corner_3_freq: located attempts (opp_fga - opp_unlocated_fga). |
opp_corner_3_ast_pct_n | Int64 | Sample size of opp_corner_3_ast_pct: makes linked to a play-by-play row in the zone. |
opp_above_break_3_fg_pct_n | Int64 | Sample size of opp_above_break_3_fg_pct: opp_above_break_3_fga. |
opp_above_break_3_freq_n | Int64 | Sample size of opp_above_break_3_freq: located attempts (opp_fga - opp_unlocated_fga). |
opp_above_break_3_ast_pct_n | Int64 | Sample size of opp_above_break_3_ast_pct: makes linked to a play-by-play row in the zone. |
rim_fg_pct_rank | Float64 | Rank of rim_fg_pct within the season (the highest ranks 1; ties average), among teams whose rim_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
rim_freq_rank | Float64 | Rank of rim_freq within the season (the highest ranks 1; ties average), among teams whose rim_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
rim_ast_pct_rank | Float64 | Rank of rim_ast_pct within the season (the highest ranks 1; ties average), among teams whose rim_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
mid_fg_pct_rank | Float64 | Rank of mid_fg_pct within the season (the highest ranks 1; ties average), among teams whose mid_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
mid_freq_rank | Float64 | Rank of mid_freq within the season (the highest ranks 1; ties average), among teams whose mid_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
mid_ast_pct_rank | Float64 | Rank of mid_ast_pct within the season (the highest ranks 1; ties average), among teams whose mid_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
corner_3_fg_pct_rank | Float64 | Rank of corner_3_fg_pct within the season (the highest ranks 1; ties average), among teams whose corner_3_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
corner_3_freq_rank | Float64 | Rank of corner_3_freq within the season (the highest ranks 1; ties average), among teams whose corner_3_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
corner_3_ast_pct_rank | Float64 | Rank of corner_3_ast_pct within the season (the highest ranks 1; ties average), among teams whose corner_3_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
above_break_3_fg_pct_rank | Float64 | Rank of above_break_3_fg_pct within the season (the highest ranks 1; ties average), among teams whose above_break_3_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
above_break_3_freq_rank | Float64 | Rank of above_break_3_freq within the season (the highest ranks 1; ties average), among teams whose above_break_3_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
above_break_3_ast_pct_rank | Float64 | Rank of above_break_3_ast_pct within the season (the highest ranks 1; ties average), among teams whose above_break_3_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_rim_fg_pct_rank | Float64 | Rank of opp_rim_fg_pct within the season (the lowest ranks 1, the stingiest defense; ties average), among teams whose opp_rim_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_rim_freq_rank | Float64 | Rank of opp_rim_freq within the season (the highest ranks 1; ties average), among teams whose opp_rim_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_rim_ast_pct_rank | Float64 | Rank of opp_rim_ast_pct within the season (the highest ranks 1; ties average), among teams whose opp_rim_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_mid_fg_pct_rank | Float64 | Rank of opp_mid_fg_pct within the season (the lowest ranks 1, the stingiest defense; ties average), among teams whose opp_mid_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_mid_freq_rank | Float64 | Rank of opp_mid_freq within the season (the highest ranks 1; ties average), among teams whose opp_mid_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_mid_ast_pct_rank | Float64 | Rank of opp_mid_ast_pct within the season (the highest ranks 1; ties average), among teams whose opp_mid_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_corner_3_fg_pct_rank | Float64 | Rank of opp_corner_3_fg_pct within the season (the lowest ranks 1, the stingiest defense; ties average), among teams whose opp_corner_3_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_corner_3_freq_rank | Float64 | Rank of opp_corner_3_freq within the season (the highest ranks 1; ties average), among teams whose opp_corner_3_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_corner_3_ast_pct_rank | Float64 | Rank of opp_corner_3_ast_pct within the season (the highest ranks 1; ties average), among teams whose opp_corner_3_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_above_break_3_fg_pct_rank | Float64 | Rank of opp_above_break_3_fg_pct within the season (the lowest ranks 1, the stingiest defense; ties average), among teams whose opp_above_break_3_fg_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_above_break_3_freq_rank | Float64 | Rank of opp_above_break_3_freq within the season (the highest ranks 1; ties average), among teams whose opp_above_break_3_freq_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
opp_above_break_3_ast_pct_rank | Float64 | Rank of opp_above_break_3_ast_pct within the season (the highest ranks 1; ties average), among teams whose opp_above_break_3_ast_pct_n reaches the rate's split-half gate (TEAM_MIN_N); null under the gate, for a rate with no gate (never half signal), or with fewer than five teams ranked. |
rim_fg_pct_pct | Float64 | Percentile of rim_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
rim_freq_pct | Float64 | Percentile of rim_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
rim_ast_pct_pct | Float64 | Percentile of rim_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
mid_fg_pct_pct | Float64 | Percentile of mid_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
mid_freq_pct | Float64 | Percentile of mid_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
mid_ast_pct_pct | Float64 | Percentile of mid_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
corner_3_fg_pct_pct | Float64 | Percentile of corner_3_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
corner_3_freq_pct | Float64 | Percentile of corner_3_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
corner_3_ast_pct_pct | Float64 | Percentile of corner_3_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
above_break_3_fg_pct_pct | Float64 | Percentile of above_break_3_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
above_break_3_freq_pct | Float64 | Percentile of above_break_3_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
above_break_3_ast_pct_pct | Float64 | Percentile of above_break_3_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_rim_fg_pct_pct | Float64 | Percentile of opp_rim_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_rim_freq_pct | Float64 | Percentile of opp_rim_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_rim_ast_pct_pct | Float64 | Percentile of opp_rim_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_mid_fg_pct_pct | Float64 | Percentile of opp_mid_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_mid_freq_pct | Float64 | Percentile of opp_mid_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_mid_ast_pct_pct | Float64 | Percentile of opp_mid_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_corner_3_fg_pct_pct | Float64 | Percentile of opp_corner_3_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_corner_3_freq_pct | Float64 | Percentile of opp_corner_3_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_corner_3_ast_pct_pct | Float64 | Percentile of opp_corner_3_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_above_break_3_fg_pct_pct | Float64 | Percentile of opp_above_break_3_fg_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_above_break_3_freq_pct | Float64 | Percentile of opp_above_break_3_freq within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
opp_above_break_3_ast_pct_pct | Float64 | Percentile of opp_above_break_3_ast_pct within the season among the same ranked rows: 100 * (n + 1 - rank) / (n + 1), n the number ranked; null when the rank is null. |
Raises
| Exception | Description |
|---|---|
ValueError | If league is not "mens" or "womens" (checked before any data is loaded). |
Example
from sportsdataverse.mbb.mbb_shot_zone_profiles import mbb_team_shot_zones
teams = mbb_team_shot_zones(2025)
teams.sort("opp_corner_3_freq").select("team_id", "opp_corner_3_freq").head()
mbb_team_strength
mbb_team_strength(seasons: 'int | list[int]', *, league: 'str' = 'mens', return_as_pandas: 'bool' = False) -> 'pl.DataFrame | pd.DataFrame'
College team strength: adjusted ratings, SOS, SOV, tempo and the four factors.
One row per team and season, with two adjusted-rating methods. adj_*_rtg are the
published college ratings (load_mbb_ratings / load_wbb_ratings, a fixed point on ESPN
box scores). adj_*_rtg_ridge are the NBA / WNBA possession ridge on the stats.ncaa.org
possessions (points per 100 against an average Division I opponent on a neutral court; home
court fitted, neutral sites from ESPN, non-Division I opponents left out). SOS is the mean
opponent adj_net_rtg over the team's completed ESPN games (unrated opponents left out),
SOV the same over its wins. Bracketology and the season sims keep the fixed point.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
seasons | int | list[int] | A season or list of seasons, named by the year it ends (2025 is 2024-25). | |
league | str | 'mens' | "mens" or "womens" (sportsdataverse.wbb.wbb_team_strength.wbb_team_strength). |
return_as_pandas | bool | False | Return a pandas frame instead of polars. |
Returns
One row per (season, team_id); team_id is the ESPN team id (Int64). games, poss / opp_poss, pts / opp_pts are the season totals from the NCAA possessions; wins / losses come from ESPN's completed games. The rated metrics are adj_off_rtg, adj_def_rtg, adj_net_rtg, sos, sov, adj_off_rtg_ridge, adj_def_rtg_ridge, adj_net_rtg_ridge and the BB-D3 rates (off_rtg, def_rtg, net_rtg, pace, the four factors and the four against). Each has <m>_rank (1 = best; adj_def_rtg, adj_def_rtg_ridge, def_rtg, tov_pct and the opponent shooting, rebounding and free-throw rates rank low first; sos ranks the hardest schedule first), <m>_pct (the Weibull percentile) and <m>_n (possessions for the ratings, rated games for SOS, the clock in regulation games for pace, wins over rated opponents for SOV). Ranks are within the season, among teams with at least half the most games (which leaves out the non-D1 opponents), the BB-D3 rates' also behind their ~sportsdataverse._common.rate_gates.TEAM_MIN_N gate, and null under five teams. Empty input returns that schema with zero rows.
| col_name | type | description |
|---|---|---|
season | Int64 | Season, named by the year it ends (2025 is 2024-25). |
team_id | Int64 | ESPN team id. Non-D1 opponents have none and get no row. |
games | Int64 | Games with at least one possession in the season (from the possession release). |
wins | Int64 | Wins in the season's completed ESPN games. |
losses | Int64 | Losses in the season's completed ESPN games. |
poss | Int64 | Offensive possessions in the season, counted from possession rows. |
opp_poss | Int64 | Defensive possessions in the season (the opponents' offensive possessions). |
pts | Int64 | Points scored on the team's offensive possessions in the season. |
opp_pts | Int64 | Points allowed on the team's defensive possessions in the season. |
adj_off_rtg | Float64 | Adjusted offensive rating: points per 100 possessions against an average defense, from the published college ratings (adj_o, the mbb_team_ratings fixed point). |
adj_def_rtg | Float64 | Adjusted defensive rating: points allowed per 100 possessions against an average offense, from the published college ratings (adj_d); lower is better. |
adj_net_rtg | Float64 | Adjusted net rating: adj_off_rtg minus adj_def_rtg. |
sos | Float64 | Strength of schedule: the mean adj_net_rtg of the opponents of the team's completed games, one weight per game (an opponent met four times counts four times). Opponents with no rating are left out. |
sov | Float64 | Strength of victory: the mean adj_net_rtg of the opponents the team beat, one weight per win; null with no win. |
off_rtg | Float64 | Offensive rating: points scored per 100 offensive possessions. |
def_rtg | Float64 | Defensive rating: points allowed per 100 defensive possessions. |
net_rtg | Float64 | Net rating: off_rtg minus def_rtg. |
pace | Float64 | Pace: possessions per 40 minutes, the mean of poss and opp_poss over the game clock those possessions used. |
efg_pct | Float64 | Effective field-goal percentage, (FGM + 0.5 * 3PM) / FGA, as a fraction. Game-level, from the NCAA team box. |
tov_pct | Float64 | Turnovers per offensive possession, as a fraction. Game-level, from the NCAA team box. |
orb_pct | Float64 | Offensive rebound rate: offensive rebounds over offensive-rebound chances (own OREB plus the defense's DREB), as a fraction. Game-level, from the NCAA team box. |
ft_rate | Float64 | Free-throw rate, FTA / FGA. Game-level, from the NCAA team box. |
opp_efg_pct | Float64 | Opponents' effective field-goal percentage, (FGM + 0.5 * 3PM) / FGA, as a fraction. Game-level, from the NCAA team box. |
opp_tov_pct | Float64 | Opponents' turnovers per possession (turnovers forced), as a fraction. Game-level, from the NCAA team box. |
opp_orb_pct | Float64 | Opponents' offensive rebound rate, as a fraction (one minus the team's defensive rebound rate). Game-level, from the NCAA team box. |
opp_ft_rate | Float64 | Opponents' free-throw rate, FTA / FGA. Game-level, from the NCAA team box. |
adj_off_rtg_rank | Float64 | Rank of adj_off_rtg within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
adj_def_rtg_rank | Float64 | Rank of adj_def_rtg within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
adj_net_rtg_rank | Float64 | Rank of adj_net_rtg within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
sos_rank | Float64 | Rank of sos within the season (the highest value ranks 1; the hardest schedule ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
sov_rank | Float64 | Rank of sov within the season (the highest value ranks 1; the strongest wins rank 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
off_rtg_rank | Float64 | Rank of off_rtg within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose off_rtg_n is at least 270 offensive possessions (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
def_rtg_rank | Float64 | Rank of def_rtg within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose def_rtg_n is at least 460 defensive possessions (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
net_rtg_rank | Float64 | Rank of net_rtg within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose net_rtg_n is at least 430 possessions (offense plus defense) (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
pace_rank | Float64 | Rank of pace within the season (the highest value ranks 1; pace has no better direction; ties average), among teams that played at least half the most games any team played in the season, whose pace_n is at least 4 games (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
efg_pct_rank | Float64 | Rank of efg_pct within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose efg_pct_n is at least 500 field-goal attempts (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
tov_pct_rank | Float64 | Rank of tov_pct within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose tov_pct_n is at least 450 offensive possessions (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
orb_pct_rank | Float64 | Rank of orb_pct within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose orb_pct_n is at least 160 offensive-rebound chances (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
ft_rate_rank | Float64 | Rank of ft_rate within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose ft_rate_n is at least 530 field-goal attempts (the sample at which the rate is half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_efg_pct_rank | Float64 | Rank of opp_efg_pct within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose opp_efg_pct_n is at least 630 opponent field-goal attempts (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_tov_pct_rank | Float64 | Rank of opp_tov_pct within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose opp_tov_pct_n is at least 340 defensive possessions (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_orb_pct_rank | Float64 | Rank of opp_orb_pct within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose opp_orb_pct_n is at least 330 opponent offensive-rebound chances (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
opp_ft_rate_rank | Float64 | Rank of opp_ft_rate within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season, whose opp_ft_rate_n is at least 450 opponent field-goal attempts (the sample at which the rate was, on the fit seasons, half signal, rate_gates); null for a non-qualifier, a sample under that gate, a null rate, or fewer than five qualifiers. |
adj_off_rtg_pct | Float64 | Percentile of adj_off_rtg within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
adj_def_rtg_pct | Float64 | Percentile of adj_def_rtg within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
adj_net_rtg_pct | Float64 | Percentile of adj_net_rtg within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
sos_pct | Float64 | Percentile of sos within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
sov_pct | Float64 | Percentile of sov within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
off_rtg_pct | Float64 | Percentile of off_rtg within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
def_rtg_pct | Float64 | Percentile of def_rtg within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
net_rtg_pct | Float64 | Percentile of net_rtg within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
pace_pct | Float64 | Percentile of pace within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
efg_pct_pct | Float64 | Percentile of efg_pct within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
tov_pct_pct | Float64 | Percentile of tov_pct within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
orb_pct_pct | Float64 | Percentile of orb_pct within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
ft_rate_pct | Float64 | Percentile of ft_rate within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_efg_pct_pct | Float64 | Percentile of opp_efg_pct within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_tov_pct_pct | Float64 | Percentile of opp_tov_pct within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_orb_pct_pct | Float64 | Percentile of opp_orb_pct within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
opp_ft_rate_pct | Float64 | Percentile of opp_ft_rate within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
adj_off_rtg_n | Int64 | Sample size of adj_off_rtg: the team's offensive possessions in the season. |
adj_def_rtg_n | Int64 | Sample size of adj_def_rtg: the team's defensive possessions in the season. |
adj_net_rtg_n | Int64 | Sample size of adj_net_rtg: the team's offensive plus defensive possessions in the season. |
sos_n | Int64 | Sample size of sos: the completed games against a rated opponent. |
sov_n | Int64 | Sample size of sov: the wins against a rated opponent. |
off_rtg_n | Int64 | Sample size of off_rtg: the team's offensive possessions in the season. |
def_rtg_n | Int64 | Sample size of def_rtg: the team's defensive possessions in the season. |
net_rtg_n | Int64 | Sample size of net_rtg: the team's offensive plus defensive possessions in the season. |
pace_n | Int64 | Sample size of pace: the game clock the season's possessions used, in regulation games (48 minutes, 40 in the WNBA and college), rounded: about the games played, overtime adding a little. |
efg_pct_n | Int64 | Sample size of efg_pct: the team's field-goal attempts in the season, 0 when the rate is null. |
tov_pct_n | Int64 | Sample size of tov_pct: the NCAA team box's possessions (o_poss) in the season, 0 when the rate is null. |
orb_pct_n | Int64 | Sample size of orb_pct: the team's offensive-rebound chances in the season, 0 when the rate is null. |
ft_rate_n | Int64 | Sample size of ft_rate: the team's field-goal attempts in the season, 0 when the rate is null. |
opp_efg_pct_n | Int64 | Sample size of opp_efg_pct: the opponents' field-goal attempts in the season, 0 when the rate is null. |
opp_tov_pct_n | Int64 | Sample size of opp_tov_pct: the opponents' NCAA team-box possessions in the season, 0 when the rate is null. |
opp_orb_pct_n | Int64 | Sample size of opp_orb_pct: the opponents' offensive-rebound chances in the season, 0 when the rate is null. |
opp_ft_rate_n | Int64 | Sample size of opp_ft_rate: the opponents' field-goal attempts in the season, 0 when the rate is null. |
adj_off_rtg_ridge | Float64 | Adjusted offensive rating, possession-ridge method: points per 100 possessions against an average Division I defense on a neutral court. The NBA / WNBA ridge (possession_ridge_ratings) on the ncaa_mbb_possessions release, penalty COLLEGE_RIDGE_LAMBDA, home court fitted and ESPN neutral sites; possessions against a non-Division I opponent left out. Published beside the fixed-point adj_off_rtg, which it does not replace. |
adj_def_rtg_ridge | Float64 | Adjusted defensive rating, possession-ridge method: points allowed per 100 possessions against an average Division I offense on a neutral court; lower is better. |
adj_net_rtg_ridge | Float64 | Adjusted net rating, possession-ridge method: adj_off_rtg_ridge minus adj_def_rtg_ridge. |
adj_off_rtg_ridge_rank | Float64 | Rank of adj_off_rtg_ridge within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
adj_def_rtg_ridge_rank | Float64 | Rank of adj_def_rtg_ridge within the season (the lowest value ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
adj_net_rtg_ridge_rank | Float64 | Rank of adj_net_rtg_ridge within the season (the highest value ranks 1; ties average), among teams that played at least half the most games any team played in the season; null for a non-qualifier, a null value, or fewer than five qualifiers. |
adj_off_rtg_ridge_pct | Float64 | Percentile of adj_off_rtg_ridge within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
adj_def_rtg_ridge_pct | Float64 | Percentile of adj_def_rtg_ridge within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
adj_net_rtg_ridge_pct | Float64 | Percentile of adj_net_rtg_ridge within the season among the same qualified teams: 100 * (n + 1 - rank) / (n + 1), n the number ranked, so the best team is under 100 and nobody is 0; null when the rank is null. |
adj_off_rtg_ridge_n | Int64 | Sample size of adj_off_rtg_ridge: the team's offensive possessions in the season, counting any against a non-Division I opponent that the fit leaves out. |
adj_def_rtg_ridge_n | Int64 | Sample size of adj_def_rtg_ridge: the team's defensive possessions in the season, counting any against a non-Division I opponent that the fit leaves out. |
adj_net_rtg_ridge_n | Int64 | Sample size of adj_net_rtg_ridge: the team's offensive plus defensive possessions in the season, counting any against a non-Division I opponent that the fit leaves out. |
Raises
| Exception | Description |
|---|---|
ValueError | If league is not "mens" or "womens". |
Example
from sportsdataverse.mbb.mbb_team_strength import mbb_team_strength
strength = mbb_team_strength(2025)
strength.sort("adj_net_rtg_rank").select("team_id", "adj_net_rtg", "sos", "sov").head()
# The two methods side by side
strength.select("team_id", "adj_net_rtg_rank", "adj_net_rtg_ridge_rank").head()
mbb_tournament_ineligible
mbb_tournament_ineligible(seasons: 'list[int] | None' = None, *, league: 'str | None' = None, return_as_pandas: 'bool' = False) -> 'pl.DataFrame | pd.DataFrame'
Division I basketball programs that could not play in the NCAA tournament, per season.
A bundled, hand-curated list (2010-2027): programs reclassifying to Division I (four seasons
from Division II until 2025, three since the NCAA's January 2025 rule; St. Thomas came from
Division III), and APR, NCAA-infractions and self-imposed postseason bans. Every row cites
its source. The college season products (bracketology, season sim, strength of schedule) use
it by default to set eligible.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
seasons | list[int] | None | None | Seasons to keep, as the end year (2024 is 2023-24). None keeps all. |
league | str | None | None | "mens", "womens", or None for both. |
return_as_pandas | bool | False | Return a pandas DataFrame instead of polars. |
Returns
One row per ineligible (season, league, team_id): season, league, team_id (ESPN team id, Utf8), team, reason (reclassifying, apr_ban, infractions_ban, self_imposed_ban or other), detail, source_url and confidence (high / medium).
| col_name | type | description |
|---|---|---|
season | Int64 | Season, as the end year (2024 is 2023-24). |
league | String | mens or womens. |
team_id | String | ESPN team id (Utf8). |
team | String | School name of the barred program, as ESPN spells it. |
reason | String | Why the program was barred: reclassifying, apr_ban, infractions_ban, self_imposed_ban or other. |
detail | String | Short note on the row, such as the reclassification year or the case behind the ban. |
source_url | String | The source that documents the row. |
confidence | String | How well the source documents the row: high (the NCAA, the school or the conference says so) or medium (a secondary source). |
Raises
| Exception | Description |
|---|---|
ValueError | If league is not "mens", "womens" or None. |
Example
from sportsdataverse.mbb import mbb_tournament_ineligible
barred = mbb_tournament_ineligible([2023], league="mens")
# Pipeline next step (one line)
barred.filter(pl.col("reason") == "reclassifying").get_column("team").to_list()
ncaa_box_events
ncaa_box_events(pbp: 'pl.DataFrame') -> 'pl.DataFrame'
Each player's box counts per stats.ncaa.org event, the input of the stint and split box.
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
pbp | DataFrame | load_ncaa_mbb_pbp / load_ncaa_wbb_pbp rows, in release order (season, contest_id, event_team_espn_team_id, player_1_id, player_2_id, event_type, event_result, shot_value). |
Returns
Rows in sportsdataverse._common.game_stints.box_event_schema (String player ids), order the event's row in the release (the stint rows' order): one per event with a count for its player_1_id, and one per assisted field goal for its player_2_id. An event with no player id or no ESPN team id (a non-D1 side) has no row.
| col_name | type | description |
|---|---|---|
season | Int64 | Season, named by the year it ends (2025 is 2024-25). |
game_id | String | stats.ncaa.org contest id. |
team_id | Int64 | ESPN team id; a non-D1 team has none and gets no rows. |
player_id | String | stats.ncaa.org player id. |
order | Int64 | The action's place in the game: the stint rows' order (stats.nba.com order_index; for college the event's row in the pbp release). |
points | Int64 | Points the player scored: 2 or 3 per made field goal and 1 per made free throw. |
fgm | Int64 | Field goals made. |
fga | Int64 | Field goals attempted. |
fg3m | Int64 | Three-pointers made. |
fg3a | Int64 | Three-pointers attempted. |
ftm | Int64 | Free throws made. |
fta | Int64 | Free throws attempted. |
oreb | Int64 | Offensive rebounds (a team rebound is no player's). |
dreb | Int64 | Defensive rebounds (a team rebound is no player's). |
ast | Int64 | Assists: made field goals the play-by-play credits him as the passer on. |
stl | Int64 | Steals he is credited with. |
blk | Int64 | Shots he blocked. |
tov | Int64 | Turnovers (a team turnover is no player's). |
pf | Int64 | Personal fouls (technicals are not counted). |
Example
from sportsdataverse.mbb.mbb_loaders import load_ncaa_mbb_pbp
from sportsdataverse.mbb.mbb_game_stints import ncaa_box_events
ncaa_box_events(load_ncaa_mbb_pbp(2025)).head()