Open your copy of Fitting a Model: State Demographics Starter File. If you haven’t already, Save a Copy now.

1 Which two columns will you explore? x-axis and y-axis.

2 Fill in the code to make a scatter plot exploring the relationship between those columns:

scatter-plot​(​states-table, "state",  ,  ​)

3 Pick two states to use for your first model: and .

4 Based on these two points, define your model in Function and Pyret Notation:

Function Notation Pyret Notation

𝑓(𝑥) = x +

fun f​(​x​): (​  ​* x​) +   end

5 Type this model into Pyret, and fit it to your data use fit-model. What 𝑆 value did you get?

6 What’s the best model you can build? In the table below, record your models and the 𝑆 values you got for them, then draw a star next to the one with the best 𝑆-value.

Model (Function or Pyret Notation - whatever you prefer!) 𝑆

What does this model actually mean? Try completing the sentence below:

This model predicts that a 1 percent[x-axis units] increase in [x-axis] is associated with a [slope, y-units] increaseincrease / decrease in [y-axis]. Based on the 𝑆 of S, I would say this model fits real well / not great / poorly / terribly.

These materials were developed partly through support of the National Science Foundation, (awards 1042210, 1535276, 1648684, 1738598, 2031479, and 1501927). CCbadge 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.