Skip to main content
Mathematics LibreTexts

4.8: Fitting Exponential Models to Data

  • Page ID
    117135
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    Building an Exponential Model from Data

    As we’ve learned, there are a multitude of situations that can be modeled by exponential functions, such as investment growth, radioactive decay, atmospheric pressure changes, and temperatures of a cooling object. What do these phenomena have in common? For one thing, all the models either increase or decrease as time moves forward. But that’s not the whole story. It’s the way data increase or decrease that helps us determine whether it is best modeled by an exponential equation. Knowing the behavior of exponential functions in general allows us to recognize when to use exponential regression, so let’s review exponential growth and decay.

    Recall that exponential functions have the form \(y=ab^x\) or \(y=A_0e^{kx}\). When performing regression analysis, we use the form most commonly used on graphing utilities, \(y=ab^x\). Take a moment to reflect on the characteristics we’ve already learned about the exponential function \(y=ab^x\) (assume \(a>0\)):

    • \(b\) must be greater than zero and not equal to one.
    • The initial value of the model is \(y=a\).
      • If \(b>1\), the function models exponential growth. As \(x\) increases, the outputs of the model increase slowly at first, but then increase more and more rapidly, without bound.
      • If \(0<b<1\), the function models exponential decay. As \(x\) increases, the outputs for the model decrease rapidly at first and then level off to become asymptotic to the x-axis. In other words, the outputs never become equal to or less than zero.

    As part of the results, your calculator will display a number known as the correlation coefficient, labeled by the variable \(r\), or \(r^2\). (You may have to change the calculator’s settings for these to be shown.) The values are an indication of the “goodness of fit” of the regression equation to the data. We more commonly use the value of \(r^2\) instead of \(r\), but the closer either value is to \(1\), the better the regression equation approximates the data.

    EXPONENTIAL REGRESSION

    Exponential regression is used to model situations in which growth begins slowly and then accelerates rapidly without bound, or where decay begins rapidly and then slows down to get closer and closer to zero. We use the command “ExpReg” on a graphing utility to fit an exponential function to a set of data points. This returns an equation of the form,

    \[y=ab^x\]

    Note that:

    • \(b\) must be non-negative.
    • when \(b>1\), we have an exponential growth model.
    • when \(0<b<1\), we have an exponential decay model.
    How to: Given a set of data, perform exponential regression using a graphing utility
    1. Use the STAT then EDIT menu to enter given data.
      1. Clear any existing data from the lists.
      2. List the input values in the L1 column.
      3. List the output values in the L2 column.
    2. Graph and observe a scatter plot of the data using the STATPLOT feature.
      1. Use ZOOM [9] to adjust axes to fit the data.
      2. Verify the data follow an exponential pattern.
    3. Find the equation that models the data.
      1. Select “ExpReg” from the STAT then CALC menu.
      2. Use the values returned for a and b to record the model, \(y=ab^x\).
    4. Graph the model in the same window as the scatterplot to verify it is a good fit for the data.

    Building a Logarithmic Model from Data

    Just as with exponential functions, there are many real-world applications for logarithmic functions: intensity of sound, pH levels of solutions, yields of chemical reactions, production of goods, and growth of infants. As with exponential models, data modeled by logarithmic functions are either always increasing or always decreasing as time moves forward. Again, it is the way they increase or decrease that helps us determine whether a logarithmic model is best.

    Recall that logarithmic functions increase or decrease rapidly at first, but then steadily slow as time moves on. By reflecting on the characteristics we’ve already learned about this function, we can better analyze real world situations that reflect this type of growth or decay. When performing logarithmic regression analysis, we use the form of the logarithmic function most commonly used on graphing utilities, \(y=a+b\ln(x)\). For this function

    • All input values, \(x\),must be greater than zero.
    • The point \((1,a)\) is on the graph of the model.
    • If \(b>0\),the model is increasing. Growth increases rapidly at first and then steadily slows over time.
    • If \(b<0\),the model is decreasing. Decay occurs rapidly at first and then steadily slows over time.
    LOGARITHMIC REGRESSION

    Logarithmic regression is used to model situations where growth or decay accelerates rapidly at first and then slows over time. We use the command “LnReg” on a graphing utility to fit a logarithmic function to a set of data points. This returns an equation of the form,

    \[y=a+b\ln(x)\]

    Note that

    • all input values, \(x\),must be non-negative.
    • when \(b>0\), the model is increasing.
    • when \(b<0\), the model is decreasing.
    How to: Given a set of data, perform logarithmic regression using a graphing utility
    1. Use the STAT then EDIT menu to enter given data.
      1. Clear any existing data from the lists.
      2. List the input values in the L1 column.
      3. List the output values in the L2 column.
    2. Graph and observe a scatter plot of the data using the STATPLOT feature.
      1. Use ZOOM [9] to adjust axes to fit the data.
      2. Verify the data follow a logarithmic pattern.
    3. Find the equation that models the data.
      1. Select “LnReg” from the STAT then CALC menu.
      2. Use the values returned for a and b to record the model, \(y=a+b\ln(x)\).
    4. Graph the model in the same window as the scatterplot to verify it is a good fit for the data.

    Building a Logistic Model from Data

    Like exponential and logarithmic growth, logistic growth increases over time. One of the most notable differences with logistic growth models is that, at a certain point, growth steadily slows and the function approaches an upper bound, or limiting value. Because of this, logistic regression is best for modeling phenomena where there are limits in expansion, such as availability of living space or nutrients.

    It is worth pointing out that logistic functions actually model resource-limited exponential growth. There are many examples of this type of growth in real-world situations, including population growth and spread of disease, rumors, and even stains in fabric. When performing logistic regression analysis, we use the form most commonly used on graphing utilities:

    \(y=\dfrac{c}{1+ae^{−bx}}\)

    Recall that:

    • \(\dfrac{c}{1+a}\) is the initial value of the model.
    • when \(b>0\), the model increases rapidly at first until it reaches its point of maximum growth rate, \((\dfrac{\ln(a)}{b}, \dfrac{c}{2})\). At that point, growth steadily slows and the function becomes asymptotic to the upper bound \(y=c\).
    • \(c\)  is the limiting value, sometimes called the carrying capacity, of the model.
    LOGISTIC REGRESSION

    Logistic regression is used to model situations where growth accelerates rapidly at first and then steadily slows to an upper limit. We use the command “Logistic” on a graphing utility to fit a logistic function to a set of data points. This returns an equation of the form

    \[y=\dfrac{c}{1+ae^{−bx}}\]

    Note that

    • The initial value of the model is \(\dfrac{c}{1+a}\).
    • Output values for the model grow closer and closer to \(y=c\) as time increases.
    How to: Given a set of data, perform logistic regression using a graphing utility
    1. Use the STAT then EDIT menu to enter given data.
      1. Clear any existing data from the lists.
      2. List the input values in the L1 column.
      3. List the output values in the L2 column.
    2. Graph and observe a scatter plot of the data using the STATPLOT feature.
      1. Use ZOOM [9] to adjust axes to fit the data.
      2. Verify the data follow a logistic pattern.
    3. Find the equation that models the data.
      1. Select “Logistic” from the STAT then CALC menu.
      2. Use the values returned for \(a\), \(b\), and \(c\) to record the model, \(y=\dfrac{c}{1+ae^{−bx}}\).
    4. Graph the model in the same window as the scatterplot to verify it is a good fit for the data.

    This page titled 4.8: Fitting Exponential Models to Data is shared under a CC BY 4.0 license and was authored, remixed, and/or curated by OpenStax via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.