Defining a Function from Two Points
1 The scatter plot displays the relationship between clownfish age and adoption time in weeks. Identify the coordinates of the data points.
1st point: (x1, y1)
2nd point: (x2, y2) |
2 We want to understand how change (Δ) in the age
x-value of the clownfish relates to the change (Δ) in their adoption time in weeks
y-value.
Compute the slope (rate of change) between the points: $$\displaystyle \frac{\Delta \text{y}}{\Delta \text{x}} =$$ $$\displaystyle \frac{y₂ - y₁}{x₂ - x₁} =$$ $$\displaystyle \frac{\qquad}{\qquad}$$
Based solely on data from these two clownfish, an increase in age of Δ year(s) predicts an increase of Δ weeks in adoption time.
3 Now, use slope-intercept form (y = mx + b) to calculate the y-intercept (vertical shift) of the line passing through the two points.
Hint: Fill in the blanks for y and x below with the coordinates of the first point. Then use the slope we just calculate for m. Finally, solve for b.
y = slope (m) × x + by-intercept / vertical shift
4 Use the slope and y-intercept you calculated to write the complete model below (in both Function and Pyret notation):
$$\displaystyle \textit{clownfish}(x) =$$ slope (m)x + y-intercept / vertical shift fun clownfish(x): ( * x) + end
Define a Function for Your Lizard Line
5 Refer to the line you drew on How could we Measure Whether a Model is a Good Fit? (Lizards) to show the relationship you saw between the lizards' weight in pounds
and adoption time in weeks
. Identify two points that could be used to define the line (the points do not have to be dots from the scatter plot itself).
Students may all be working with different points for this section!
First point: (x1, y1) Second point: (x2, y2)
6 Compute the slope (rate of change) between the points: $$\displaystyle \frac{\Delta \text{y}}{\Delta \text{x}} =$$ $$\displaystyle \frac{y₂ - y₁}{x₂ - x₁} =$$ $$\displaystyle \frac{\qquad}{\qquad}$$
Based solely on these 2 points, increasing a lizard’s weight by 1 pound, predicts a(n) increase or decrease? of Δ weeks week(s) in adoption time.
7 Now, use slope-intercept form (y = mx + b) to calculate the y-intercept (vertical shift) of the line passing through the two points.
y = slope (m) × x + by-intercept / vertical shift
8 Use the slope and y-intercept you calculated to write the complete model below (in both Function and Pyret notation):
lizard(x) = slope (m)x + y-intercept / vertical shift fun lizard(x): ( * x) + end
These materials were developed partly through support of the National Science Foundation, (awards 1042210, 1535276, 1648684, 1738598, 2031479, and 1501927).
Bootstrap by the Bootstrap Community is licensed under a Creative Commons 4.0 Unported License. This license does not grant permission to run training or professional development. Offering training or professional development with materials substantially derived from Bootstrap must be approved in writing by a Bootstrap Director. Permissions beyond the scope of this license, such as to run training, may be available by contacting contact@BootstrapWorld.org.