1 Data
Each row is one schedule or condition with a single response alternative: the reinforcement rate it produced (R) and the response rate (B), for example one row per VI schedule. Use rates (per hour, per minute) rather than session totals unless sessions were the same length. The units you name here are the units of Re and k. Group is optional; use it to fit a curve for each subject or condition and compare their k and Re.
Each row is one observation: a session, condition, season, player, or phase. Enter totals (or rates) for both alternatives. Group is optional; use it to fit and compare conditions separately (for example, baseline vs. intervention).
Pull NBA shooting totals straight from pbpstats.com. It splits every shot into five zones, so you can compare any two shot types that do not overlap: threes vs. twos, corner vs. above-the-break threes, rim vs. mid-range, and more. Attempts are the behavior and makes are the reinforcers.
Each team or player season is one observation, as in Romanowich et al. (2007) and Alferink et al. (2009); Alferink et al. kept players with at least 15 attempts of each shot type. From 2000-01 on, pbpstats league totals agree with the official totals on Basketball-Reference to within a few shots a season, except 2025-26: there pbpstats has about 1,100 more missed threes, apparently end-of-quarter heaves that the official totals leave out. pbpstats is missing play-by-play for some games from 1996-97 to 1999-00. Your browser requests the data directly from api.pbpstats.com, a free service, so large requests can take a minute.
Numbers can use a decimal point (43.16) or, in tab- or semicolon-separated files, a decimal comma (43,16). Thousands separators (1,234 or 1 234) are fine. Percentages can be .366, 36.6, or 36.6%.
Columns
Detected automatically from the column names. Change any that are wrong.
Single-schedule VI practice data
Ten variable-interval schedules, from VI 6 s to VI 450 s, with the reinforcers per hour and responses per minute obtained on each. Responding rises steeply across lean schedules and levels off across rich ones, the shape Herrnstein (1970) described. The fit gives k = 134.4 responses per minute and Re = 37.5 reinforcers per hour, the values Excel Solver finds for the same data.
Two subjects (simulated)
Simulated data, not from a study: two subjects on the same seven VI schedules, generated with the same k (100 responses per minute) but different Re (20 and 60 reinforcers per hour), plus random noise. The group comparison should find a difference in Re but not in k, the pattern Herrnstein’s theory expects when the amount of other reinforcement differs.
NBA league shooting, 1979-80 to 2025-26
Regular-season league totals for all 47 seasons with a three-point line. Alternative 1 is three-point shots and alternative 2 is two-point shots. Attempts are the behavior and makes are the reinforcers, following Vollmer and Bourret (2000), Romanowich et al. (2007), and Alferink et al. (2009). Seasons are grouped by three-point line distance; the line was shortened to 22 ft for 1994-95 through 1996-97, the change Romanowich et al. (2007) analyzed.
Source: Basketball-Reference.com league totals, retrieved October 16, 2026. Download the CSV.
Concurrent VI VI practice data
Five conditions of a two-key concurrent variable-interval practice data set, with responses and reinforcers on the left and right keys. A good first example: clear undermatching (a = 0.716) with a slight left-key bias (b = 1.200).
2 Settings
3 Results
4 Graphs
Hover or tap a point for its values. Every graph also has a Data table button that lists the plotted numbers.
5 Observation details
6 Check your understanding
A few questions built from your own results. Choose an answer to see why it is right or wrong.
Method and references
Equations
Strict matching (Herrnstein, 1961): the proportion of behavior allocated to an alternative equals the proportion of reinforcers it produces.
B1 / (B1 + B2) = R1 / (R1 + R2)
Generalized matching (Baum, 1974): the log behavior ratio is a linear function of the log reinforcer ratio.
log(B1/B2) = a · log(R1/R2) + log b
- a (sensitivity): 1 is matching. Below 1 is undermatching: behavior ratios change less than reinforcer ratios, so preference shifts less than one-for-one toward the option earning more. Above 1 is overmatching: behavior ratios change more than reinforcer ratios. Below 0, behavior moves away from the reinforcers.
- log b (bias): 0 is no bias. Positive favors alternative 1, negative favors alternative 2, regardless of reinforcement. b is the ratio of behavior (alternative 1 to alternative 2) when both produce equal reinforcement.
Herrnstein’s hyperbola (Herrnstein, 1970), the quantitative law of effect: with one response alternative, the response rate is a hyperbolic function of the reinforcement rate it produces.
B = k · R / (R + Re)
- k (asymptote): the response rate approached as reinforcement grows without limit, in the units of B.
- Re (extraneous reinforcement): reinforcement from all other sources, such as other behavior in the setting, in the units of R. It is also the schedule reinforcement rate that produces half of k. R / (R + Re) is the schedule’s share of all reinforcement, so responding follows relative, not absolute, reinforcement.
How the numbers are computed
- a and log b come from ordinary least-squares regression of log(B1/B2) on log(R1/R2), as in Baum (1979) and the basketball studies.
- VAC (variance accounted for) is R2 of that fit. The strict-matching VAC uses the line a = 1, log b = 0 instead and can be negative.
- Confidence intervals and t tests (a vs. 1, a vs. 0, log b vs. 0) use the Student t distribution with n − 2 degrees of freedom.
- Verdict, using Baum’s (1979) .90 to 1.11 range: Matching when the 95% CI for a includes 1 and an equivalence test (two one-sided tests: the 90% CI inside the range at the 95% setting, the 80% CI at the 90% setting, and the 98% CI at the 99% setting; Lakens, 2017) shows a is close to 1. Inconclusive when the CI includes 1 but is too wide for that. Slight under- or overmatching when the CI excludes 1 but lies inside the range; borderline when it crosses the range’s edge; plain under- or overmatching when it lies outside. Reversed when the CI is below 0, and no reliable relation when it includes 0 but not 1.
- Groups are compared with a Welch t test on the difference in a (and in log b), with Holm’s adjustment when there are more than two groups. Alferink et al. (2009) required non-overlapping CIs, which is a far stricter standard (about a 0.5% test; Knol et al., 2011).
- The Durbin-Watson statistic checks residuals in row order. With time-ordered rows such as seasons, values well below 2 mean ordinary confidence intervals are too narrow, so a Newey-West (1987) interval is also shown.
- Shot data: makes are a chance sample of attempts, which pulls the fitted a toward 0 (regression dilution; Hutcheon et al., 2010). For team or player data the page estimates how large that pull is and gives a corrected a.
- Zeros: rows with a zero are left out by default. Adding 0.5 is offered only for whole-number counts, because with rates it makes the answer depend on the units.
- Influence: Observation details gives each row’s leverage, its studentized residual (from a fit without the row, with n − 3 degrees of freedom), its Cook’s distance (Cook, 1977), and a without the row. A row dominates the fit when its Cook’s distance is above the median of F(2, n − 2), so that leaving it out moves the estimates outside their 50% confidence region (Cook & Weisberg, 1982), and is influential above 4/n.
- Bands: the log-ratio graph shows the confidence band for the line, ±t·s√(1/n + (x − x̄)²/Sxx), and the prediction band for a new row, which adds 1 under the root.
- Hyperbola: k and Re minimize the sum of squared differences between observed and predicted response rates, the criterion Excel Solver uses. Starting values come from a scan of Re with the best k for each, refined by the Levenberg-Marquardt method. Standard errors come from the Jacobian, s2(J′J)−1 with n − 2 degrees of freedom, as in scipy’s curve_fit, and the confidence intervals use the t distribution. These intervals are approximate: they assume the model is close to linear near the estimates, and the sampling distribution of Re is often skewed. VAC is 1 − SSE divided by the total sum of squares of B.
- Profile intervals for k and Re (Bates & Watts, 1988) hold one parameter at each candidate value, refit the other, and keep the values whose SSE is within t²s² of the minimum, the method of R’s confint for nls. They can be lopsided, and open-ended when the data never level off.
- Groups in hyperbola mode each get their own curve. Extra-sum-of-squares F tests (Motulsky & Christopoulos, 2004) compare that model with one where the groups share k, share Re, or share the whole curve.
- Exponentiated hyperbola (McDowell, 1986, 2005): B = kRa / (Ra + Rea), with standard errors from the Jacobian and n − 3 degrees of freedom. It is compared with Herrnstein’s hyperbola by an extra-sum-of-squares F test with 1 and n − 3 degrees of freedom and by AICc (Burnham & Anderson, 2002).
- The classic theory treats k as fixed for a given response and organism, so differences between conditions should show up in Re. McDowell (2005) concluded that this constant-k assumption is not tenable, so compare k across conditions with care.
Basketball notes
- Shots made can only follow shots taken, so the two measures are not independent (Alferink et al., 2009). This is a known limit of the basketball application.
- A fit across players or league seasons describes group-level allocation, not one person's choices (Alferink et al., 2009, Study 3).
- A three-point bias is expected when makes are unweighted, because a three is the larger reinforcer. Weighting by points (Vollmer & Bourret, 2000) moves that magnitude effect out of the bias term.
See what a and b do
Move the sliders to see how sensitivity and bias change the matching line and the proportion curve. The dashed lines are perfect matching. Gray dots are your current data.
References
- Alferink, L. A., Critchfield, T. S., Hitt, J. L., & Higgins, W. J. (2009). Generality of the matching law as a descriptor of shot selection in basketball. Journal of Applied Behavior Analysis, 42(3), 595–608. doi:10.1901/jaba.2009.42-595
- Bates, D. M., & Watts, D. G. (1988). Nonlinear regression analysis and its applications. Wiley.
- Baum, W. M. (1974). On two types of deviation from the matching law: Bias and undermatching. Journal of the Experimental Analysis of Behavior, 22(1), 231–242. doi:10.1901/jeab.1974.22-231
- Baum, W. M. (1979). Matching, undermatching, and overmatching in studies of choice. Journal of the Experimental Analysis of Behavior, 32(2), 269–281. doi:10.1901/jeab.1979.32-269
- Baum, W. M. (1982). Choice, changeover, and travel. Journal of the Experimental Analysis of Behavior, 38(1), 35–49. doi:10.1901/jeab.1982.38-35
- Burnham, K. P., & Anderson, D. R. (2002). Model selection and multimodel inference: A practical information-theoretic approach (2nd ed.). Springer.
- Cook, R. D. (1977). Detection of influential observation in linear regression. Technometrics, 19(1), 15–18. doi:10.1080/00401706.1977.10489493
- Cook, R. D., & Weisberg, S. (1982). Residuals and influence in regression. Chapman and Hall.
- Herrnstein, R. J. (1961). Relative and absolute strength of response as a function of frequency of reinforcement. Journal of the Experimental Analysis of Behavior, 4(3), 267–272. doi:10.1901/jeab.1961.4-267
- Herrnstein, R. J. (1970). On the law of effect. Journal of the Experimental Analysis of Behavior, 13(2), 243–266. doi:10.1901/jeab.1970.13-243
- Holm, S. (1979). A simple sequentially rejective multiple test procedure. Scandinavian Journal of Statistics, 6(2), 65–70.
- Hutcheon, J. A., Chiolero, A., & Hanley, J. A. (2010). Random measurement error and regression dilution bias. BMJ, 340, c2289. doi:10.1136/bmj.c2289
- Knol, M. J., Pestman, W. R., & Grobbee, D. E. (2011). The (mis)use of overlap of confidence intervals to assess effect modification. European Journal of Epidemiology, 26(4), 253–254. doi:10.1007/s10654-011-9563-8
- Lakens, D. (2017). Equivalence tests: A practical primer for t tests, correlations, and meta-analyses. Social Psychological and Personality Science, 8(4), 355–362. doi:10.1177/1948550617697177
- McDowell, J. J. (1986). On the falsifiability of matching theory. Journal of the Experimental Analysis of Behavior, 45(1), 63–74. doi:10.1901/jeab.1986.45-63
- McDowell, J. J. (2005). On the classic and modern theories of matching. Journal of the Experimental Analysis of Behavior, 84(1), 111–127. doi:10.1901/jeab.2005.59-04
- Motulsky, H., & Christopoulos, A. (2004). Fitting models to biological data using linear and nonlinear regression: A practical guide to curve fitting. Oxford University Press.
- Newey, W. K., & West, K. D. (1987). A simple, positive semi-definite, heteroskedasticity and autocorrelation consistent covariance matrix. Econometrica, 55(3), 703–708. doi:10.2307/1913610
- Reed, D. D., Critchfield, T. S., & Martens, B. K. (2006). The generalized matching law in elite sport competition: Football play calling as operant choice. Journal of Applied Behavior Analysis, 39(3), 281–297. doi:10.1901/jaba.2006.146-05
- Romanowich, P., Bourret, J., & Vollmer, T. R. (2007). Further analysis of the matching law to describe two- and three-point shot allocation by professional basketball players. Journal of Applied Behavior Analysis, 40(2), 311–315. doi:10.1901/jaba.2007.119-05
- Vollmer, T. R., & Bourret, J. (2000). An application of the matching law to evaluate the allocation of two- and three-point shots by college basketball players. Journal of Applied Behavior Analysis, 33(2), 137–150. doi:10.1901/jaba.2000.33-137
- Wearden, J. H., & Burgess, I. S. (1982). Matching since Baum (1979). Journal of the Experimental Analysis of Behavior, 38(3), 339–348. doi:10.1901/jeab.1982.38-339