Exercises: Regression line of y on x
Given the statistical parameters of a bivariate distribution: mean of $X$ equal to $4$, mean of $Y$ equal to $6$, variance of $X$ equal to $1,5$, and covariance equal to…
Given the statistical parameters of a bivariate distribution: mean of $X$ equal to $4$, mean of $Y$ equal to $6$, variance of $X$ equal to $1,5$, and covariance equal to $3$. Determine the equation of the regression line of $Y$ on $X$.
In a study on the relationship between the amount of fertilizer applied ($X$, in kg/ha) and the yield obtained ($Y$, in tonnes/ha), the regression line of $Y$ on $X$ was…
In a study on the relationship between the amount of fertilizer applied ($X$, in kg/ha) and the yield obtained ($Y$, in tonnes/ha), the regression line of $Y$ on $X$ was calculated to be $y = 0,4x + 2,1$. Estimate the yield that will be obtained if $15$ kg/ha of fertilizer is applied.
Given the following table with three pairs of values of a bivariate distribution: $X$: $1 \quad 2 \quad 3$ $Y$: $2 \quad 4 \quad 5$ Calculate the gradient of the…
Given the following table with three pairs of values of a bivariate distribution:
-
$X$: $1 \quad 2 \quad 3$
-
$Y$: $2 \quad 4 \quad 5$
Calculate the gradient of the regression line of $Y$ on $X$.
The regression line of $Y$ on $X$ of a bivariate distribution is $y = 1,2x - 0,5$. If we know that the marginal mean of the variable $X$ is $\bar{x} = 3$, what is the…
The regression line of $Y$ on $X$ of a bivariate distribution is $y = 1,2x - 0,5$. If we know that the marginal mean of the variable $X$ is $\bar{x} = 3$, what is the exact value of the marginal mean $\bar{y}$?
The following scatter diagram shows the relationship between the years of experience of a group of technicians and their monthly salary in hundreds of euros, together…
The following scatter diagram shows the relationship between the years of experience of a group of technicians and their monthly salary in hundreds of euros, together with the regression line of $Y$ on $X$. From the graph, visually estimate the expected salary for a technician with $6$ years of experience and determine the y-intercept of the line.
In a bivariate distribution, the standard deviations are known to be $\sigma_x = 2$ and $\sigma_y = 5$, and the linear correlation coefficient is $r = -0,8$. Calculate…
In a bivariate distribution, the standard deviations are known to be $\sigma_x = 2$ and $\sigma_y = 5$, and the linear correlation coefficient is $r = -0,8$. Calculate the equation of the regression line of $Y$ on $X$ knowing that the mean point of the distribution is $(10, 20)$.
The variables $X$ and $Y$ represent, respectively, the number of weekly training hours and the time in seconds to run $100$ metres for a group of athletes. If the…
The variables $X$ and $Y$ represent, respectively, the number of weekly training hours and the time in seconds to run $100$ metres for a group of athletes. If the regression line of $Y$ on $X$ is $y = -0,5x + 14$, interpret the physical meaning of the gradient of this line in the context of the problem.
A bivariate distribution has as its data matrix the following summations: $\sum x_i = 20$, $\sum y_i = 40$, $\sum x_i^2 = 120$, $\sum x_i y_i = 180$, and the total…
A bivariate distribution has as its data matrix the following summations: $\sum x_i = 20$, $\sum y_i = 40$, $\sum x_i^2 = 120$, $\sum x_i y_i = 180$, and the total number of observations is $N = 10$. Calculate the covariance and the variance of $X$, and write the equation of the regression line of $Y$ on $X$.
Marcos has obtained the following statistical parameters when studying the relationship between weekly study hours in Mathematics ($X$) and the grade obtained in the…
Marcos has obtained the following statistical parameters when studying the relationship between weekly study hours in Mathematics ($X$) and the grade obtained in the subject ($Y$, from $0$ to $10$) in his 1st year Bachillerato group: $\bar{x} = 6$, $\bar{y} = 6,5$, $\sigma_x^2 = 4$, $\sigma_y^2 = 2,25$, and covariance $\sigma_{xy} = 2,4$. To predict what grade a student who studies $8$ hours ($x = 8$) will get, Marcos writes in his notebook:
$$y - 6 = \frac{2,4}{2,25}\,(x - 6,5)$$He substitutes $x = 8$ and concludes that the estimated grade will be $7,6$.
- a) Identify the two conceptual mistakes made by Marcos when formulating the equation of the regression line of $Y$ on $X$ and explain why they are incorrect.
- b) Write the corrected equation of the regression line of $Y$ on $X$ and calculate the grade that the model truly predicts for $x = 8$.
A territorial delegation of AEMET studies the relationship between altitude ($X$, in hundreds of metres) and the annual mean temperature ($Y$, in $^\circ\text{C}$) at…
A territorial delegation of AEMET studies the relationship between altitude ($X$, in hundreds of metres) and the annual mean temperature ($Y$, in $^\circ\text{C}$) at five observatories in the Sistema Central:
-
Observatory 1: $(4; 14,3)$
-
Observatory 2: $(6; 13,3)$
-
Observatory 3: $(8; 12,0)$
-
Observatory 4: $(10; 10,9)$
-
Observatory 5: $(12; 9,5)$
- a) Before performing any algebraic calculation, reason out the expected sign of the covariance and the slope of the regression line of $Y$ on $X$. Also estimate approximately how many degrees the temperature decreases for every $100\text{ m}$ of ascent.
- b) Verify your estimate by calculating the means $\bar{x}$ and $\bar{y}$, the variance $\sigma_x^2$, and the covariance $\sigma_{xy}$, and determine the exact equation of the regression line of $Y$ on $X$.
- c) Use the line to predict the expected temperature at $900\text{ m}$ ($x = 9$) and at $3000\text{ m}$ ($x = 30$). Assess whether both predictions are reasonable, differentiating between interpolation and extrapolation.
A digital marketing company has collected data on investment in social media campaigns ($X$, in thousands of euros) and sales revenue generated ($Y$, in tens of…
A digital marketing company has collected data on investment in social media campaigns ($X$, in thousands of euros) and sales revenue generated ($Y$, in tens of thousands of euros) over $5$ consecutive months:
-
$X$: $2,5 \quad 3,0 \quad 3,5 \quad 4,0 \quad 4,5$
-
$Y$: $12 \quad 14 \quad 15 \quad 18 \quad 19$
Calculate the regression line of revenue as a function of investment and estimate the expected revenue if $5000$ euros is invested.
In a biomechanics study, the relationship between femur length ($X$, in cm) and height of an individual ($Y$, in cm) is analysed. The following statistical summaries are…
In a biomechanics study, the relationship between femur length ($X$, in cm) and height of an individual ($Y$, in cm) is analysed. The following statistical summaries are available for a sample of $50$ people:
$\bar{x} = 45$, $\bar{y} = 170$, $\sigma_x = 3,2$, $\sigma_y = 8,5$, $r = 0,92$.
Find the regression line of $Y$ on $X$ and estimate the height of a person whose femur measures $48$ cm. Briefly justify the reliability of this estimate.
The regression lines of a bivariate distribution are given by the equations $y = 0,5x + 4$ and $x = 1,6y - 2$. Determine the coordinates of the mean point of the…
The regression lines of a bivariate distribution are given by the equations $y = 0,5x + 4$ and $x = 1,6y - 2$. Determine the coordinates of the mean point of the distribution and the linear correlation coefficient $r$, giving reasons for its sign.
In a thermodynamics experiment, the temperature of a liquid ($Y$, in ºC) is measured as a function of elapsed time ($X$, in minutes). The regression line obtained is…
In a thermodynamics experiment, the temperature of a liquid ($Y$, in ºC) is measured as a function of elapsed time ($X$, in minutes). The regression line obtained is $y = -1,5x + 85$. Knowing that the coefficient of determination is $R^2 = 0,95$ and that the total duration of the experiment was $30$ minutes, is it reliable to estimate the temperature at $45$ minutes using this line? Justify your answer based on the concepts of interpolation and extrapolation.
The relationship between the amount of impurities in a metal alloy ($X$, in $\%$) and its tensile strength ($Y$, in MPa) has been studied. After analysing $20$ samples,…
The relationship between the amount of impurities in a metal alloy ($X$, in $\%$) and its tensile strength ($Y$, in MPa) has been studied. After analysing $20$ samples, $\bar{x} = 2,1$, $\bar{y} = 450$, and a regression line of $Y$ on $X$ given by $y = -15x + 481,5$ were obtained. Calculate the covariance of the distribution if the variance of the impurities is known to be $\sigma_x^2 = 0,8$.
The following scatter diagram shows the relationship between the depth of a mineral seam ($X$, in metres) and the extraction cost per tonne ($Y$, in thousands of euros).…
The following scatter diagram shows the relationship between the depth of a mineral seam ($X$, in metres) and the extraction cost per tonne ($Y$, in thousands of euros). The line plotted is the regression line of $Y$ on $X$. From the graph, obtain the coordinates of the two marked points on the line, calculate its exact equation, and estimate the extraction cost for a depth of $120$ metres.
The regression line of $Y$ on $X$ of a bivariate distribution is $y = 3x - 2$. If $4$ units are added to all observed values of the variable $X$ and all values of the…
The regression line of $Y$ on $X$ of a bivariate distribution is $y = 3x - 2$. If $4$ units are added to all observed values of the variable $X$ and all values of the variable $Y$ are multiplied by $2$, what will be the new equation of the regression line of $Y$ on $X$?
At a meteorological centre, atmospheric pressure ($X$, in hPa) is related to the probability of precipitation ($Y$, in $\%$). Knowing that the mean point of the…
At a meteorological centre, atmospheric pressure ($X$, in hPa) is related to the probability of precipitation ($Y$, in $\%$). Knowing that the mean point of the distribution is the point $(1013, 40)$, the standard deviation of the pressure is $5$ hPa, that of the probability is $20\%$, and the linear correlation coefficient is $-0,85$, find the equation of the regression line that allows the probability of rain to be estimated given the atmospheric pressure.
From the microdata of the Family Budget Survey of the Instituto Nacional de Estadística (INE), a sample of $5$ households is drawn to analyze monthly food expenditure…
From the microdata of the Family Budget Survey of the Instituto Nacional de Estadística (INE), a sample of $5$ households is drawn to analyze monthly food expenditure ($Y$, in hundreds of euros) as a function of net monthly household income ($X$, in thousands of euros):
-
Household A: $(1,5; 3,0)$
-
Household B: $(2,0; 3,8)$
-
Household C: $(2,5; 4,5)$
-
Household D: $(3,0; 5,1)$
-
Household E: $(3,5; 6,1)$
- a) Model the linear relationship between both variables by calculating the regression line of $Y$ on $X$ (detail the calculation of $\bar{x}$, $\bar{y}$, $\sigma_x^2$, and $\sigma_{xy}$).
- b) Interpret the socioeconomic meaning of the slope $m_{yx} = 1,5$ and the y-intercept $n = 0,75$ in the real context, paying special attention to the units of measurement of each variable.
- c) Estimate the food expenditure for a household with an income of $2800$ euros per month and for another with an income of $8500$ euros per month. Justify which of the two estimates offers greater statistical reliability based on the range of observed data.
In a study on school coexistence in 1st year Bachillerato, the number of unexcused absences ($X$) and the final evaluation grade ($Y$) of a sample of students are…
In a study on school coexistence in 1st year Bachillerato, the number of unexcused absences ($X$) and the final evaluation grade ($Y$) of a sample of students are analyzed. The following statistics are obtained: $\bar{x} = 4$, $\bar{y} = 6$, $\sigma_x^2 = 5$, $\sigma_y^2 = 3,2$, and $\sigma_{xy} = -3,6$.
Two prediction tasks are proposed:
-
Task 1: Estimate the expected grade ($Y$) for a student with $x = 6$ absences.
-
Task 2: Estimate the probable number of absences ($X$) of a student whose final grade was $y = 3,3$.
To solve Task 2, two teachers propose different methods:
-
Teacher A calculates the line of $Y$ on $X$, substitutes $y = 3,3$, and solves algebraically for the value of $x$.
-
Teacher B argues that solving for $x$ is incorrect and that the line of $X$ on $Y$ should be found in order to substitute $y = 3,3$ directly.
- a) Justify which of the two methods is statistically rigorous according to the least-squares criterion that defines regression lines.
- b) Find the equations of both regression lines ($Y$ on $X$, and $X$ on $Y$).
- c) Apply both methods for Task 2, compare the numerical results obtained, and explain the reason for the discrepancy between them using the coefficient of determination $r^2$.
Prove analytically that if the variables $X$ and $Y$ have a perfect linear correlation ($r = 1$ or $r = -1$), then the regression line of $Y$ on $X$ coincides exactly…
Prove analytically that if the variables $X$ and $Y$ have a perfect linear correlation ($r = 1$ or $r = -1$), then the regression line of $Y$ on $X$ coincides exactly with the regression line of $X$ on $Y$. Briefly explain what geometric implication this has for the angle formed by both lines in the plane.
In a study on the performance of solar panels, the variable $X$ represents solar irradiance ($W/m^2$) and the variable $Y$ the electric power generated ($W$). It is…
In a study on the performance of solar panels, the variable $X$ represents solar irradiance ($W/m^2$) and the variable $Y$ the electric power generated ($W$). It is known that the regression line of $Y$ on $X$ is given by $y = 0,18x + 5$, and the regression line of $X$ on $Y$ by $x = 5y - 10$. Calculate the marginal means $\bar{x}$ and $\bar{y}$, and find the exact percentage of the variability of the electric power that is explained by the solar irradiance.
A set of bivariate data $(x_i, y_i)$ is available, where the variable $X$ takes the values $1, 2, 3, 4$ and the variable $Y$ takes the values $2, k, 5, 8$. Given that…
A set of bivariate data $(x_i, y_i)$ is available, where the variable $X$ takes the values $1, 2, 3, 4$ and the variable $Y$ takes the values $2, k, 5, 8$. Given that the gradient of the regression line of $Y$ on $X$ is $m_{yx} = 1,9$, set up an equation and determine the exact value of the parameter $k$.
In a macroeconomic analysis, the inflation rate ($X$, in $\%$) is related to the unemployment rate ($Y$, in $\%$). The regression line of $Y$ on $X$ is $y = -0,6x + 8$.…
In a macroeconomic analysis, the inflation rate ($X$, in $\%$) is related to the unemployment rate ($Y$, in $\%$). The regression line of $Y$ on $X$ is $y = -0,6x + 8$. If the marginal variance of inflation is $\sigma_x^2 = 4$ and the marginal variance of unemployment is $\sigma_y^2 = 2,25$, determine the linear correlation coefficient $r$ and the percentage of the variability of unemployment that is explained by the linear regression model.
A civil engineer is studying the relationship between the load supported by a beam ($X$, in tonnes) and its maximum deformation ($Y$, in millimetres). Some data from the…
A civil engineer is studying the relationship between the load supported by a beam ($X$, in tonnes) and its maximum deformation ($Y$, in millimetres). Some data from the original report has been lost, but it is known that the mean load is $\bar{x} = 15$, the variance of the load is $\sigma_x^2 = 16$, the covariance is $\sigma_{xy} = 18$, the correlation coefficient is $r = 0,9$ and the y-intercept of the regression line of $Y$ on $X$ is $b = 2$. Calculate the mean deformation $\bar{y}$, the standard deviation $\sigma_y$ and the equation of the regression line of $Y$ on $X$.
The following graph shows a scatter plot relating the speed of a vehicle ($X$, in km/h) to the braking distance ($Y$, in metres). The two regression lines have been…
The following graph shows a scatter plot relating the speed of a vehicle ($X$, in km/h) to the braking distance ($Y$, in metres). The two regression lines have been drawn: Line A (in blue) and Line B (in green). Identify with reasoning, based on the properties of the gradients, which of the two lines is the regression line of $Y$ on $X$ and find its equation, knowing that both intersect at the point $(80, 40)$ and that the blue line passes through $(100, 56)$.
In a pharmaceutical study, the concentration of an active ingredient in blood ($Y$, in mg/L) is modelled as a function of the administered dose ($X$, in mg). If we…
In a pharmaceutical study, the concentration of an active ingredient in blood ($Y$, in mg/L) is modelled as a function of the administered dose ($X$, in mg). If we change variables by standardising both variables, that is, we define $Z_x = \frac{X - \bar{x}}{\sigma_x}$ and $Z_y = \frac{Y - \bar{y}}{\sigma_y}$, prove algebraically that the regression line of $Z_y$ on $Z_x$ passes through the origin and that its gradient is exactly the linear correlation coefficient $r$.
A bivariate distribution of $100$ pairs of values has been studied. It is known that the sum of squared residuals (the sum of squared differences between the actual…
A bivariate distribution of $100$ pairs of values has been studied. It is known that the sum of squared residuals (the sum of squared differences between the actual observed values $y_i$ and those estimated by the line $\hat{y}_i$) is equal to $150$. If the marginal variance of the variable $Y$ is $\sigma_y^2 = 4$, find the coefficient of determination $R^2$ using the relationship $\sum (y_i - \hat{y}_i)^2 = N \cdot \sigma_y^2 (1 - r^2)$, and calculate the absolute value of the gradient of the regression line of $Y$ on $X$ knowing that the marginal variance of $X$ is $\sigma_x^2 = 9$.
A university laboratory analyzes the relationship between two continuous physical variables, $X$ and $Y$, and obtains the general equations of their two least-squares…
A university laboratory analyzes the relationship between two continuous physical variables, $X$ and $Y$, and obtains the general equations of their two least-squares linear regression lines. Due to a labeling error in the software, which line corresponds to which regression was not saved:
-
Line 1 ($r_1$): $2x - 5y + 11 = 0$
-
Line 2 ($r_2$): $8x - 5y - 7 = 0$
- a) Deduce with reasoning which of the two is the regression line of $Y$ on $X$ and which one is that of $X$ on $Y$. To do so, analyze the two possible assignments and analytically prove that one of them is mathematically impossible based on the property of the product of their slopes $m_{yx} \cdot m_{xy} = r^2$ and the admissible range of the linear correlation coefficient.
- b) Find the exact coordinates of the centroid $(\bar{x}, \bar{y})$ of the bivariate distribution and calculate the linear correlation coefficient $r$.
- c) Furthermore, knowing that the standard deviation of $X$ is $\sigma_x = 2,5$, analytically reconstruct the value of the covariance $\sigma_{xy}$ and the variance $\sigma_y^2$.
A sports analyst for a football club studies the relationship between high-intensity kilometres covered per match ($X$, in km) and ball recoveries in the opponent's half…
A sports analyst for a football club studies the relationship between high-intensity kilometres covered per match ($X$, in km) and ball recoveries in the opponent's half ($Y$) by the players. After entering the data into a software program, he presents a report with the following results:
-
Regression line of $Y$ on $X$: $y = 0,8x - 1,2$
-
Regression line of $X$ on $Y$: $x = 1,5y + 2,1$
The report contains three statements made by the analyst:
-
"Since both slopes are positive, there is a positive and very strong linear correlation between both variables."
-
"To estimate the distance a player should run to achieve $y = 5$ recoveries, it suffices to solve for the variable $x$ in the first line, which results in $x = 7,75\text{ km}$."
-
"If we change the unit of measurement of distance $X$ from kilometres to metres ($X' = 1000X$), both the covariance $\sigma_{x'y}$ and the slope $m_{yx}'$ of the regression line of $Y$ on $X$ will be multiplied by $1000$."
Critically evaluate the report:
- a) Analytically prove that the two equations provided contain an insurmountable statistical contradiction that invalidates the model.
- b) Explain the fundamental error committed by the analyst in statement 2.
- c) Analytically examine statement 3 using the definitions of covariance and variance: deduce how $\sigma_{x'y}$ and the slope $m_{yx}'$ actually change under the change of scale $X' = k\cdot X$, and determine whether the statement is true or false.