R squared or coefficients for prediction

In summary, the conversation discusses using a model to predict the time a task will take to execute and calculating the error between the predicted and actual time. The speaker is seeking opinions on the best method to use the error to predict the next execution of a similar task and mentions using adjusted R^2 and mean squared error as potential options.
  • #1
xeon123
90
0
I created a little model that predicts the time a task will take to execute. Than, I calculate the real time that the task took to execute. With the predict and real value I have the error of my prediction. I want to use that error to predict the next execution (the next execution is a similar task has the one I ran). I was looking to R-squared or coefficients to help me. Does anyone has an opinion about this. What is the best use I can do to the error of my prediction to help to predict again?

For now I am using Adjusted R^2, but I don't know other methods.
 
Last edited:
Mathematics news on Phys.org
  • #2
I would use the mean squared error (see https://en.wikipedia.org/wiki/Mean_squared_error). The formula is $$MSE = \frac 1 n \sum_{i = 1}^n(Y_i - \hat{Y_i})^2$$
Here ##Y_i## is the actual time of the i-th task, and ##\hat{Y_i}## is the predicted time of the same task.
 

1. What is R squared and how is it calculated?

R squared, also known as the coefficient of determination, is a statistical measure that represents the proportion of variance in the dependent variable that is explained by the independent variable(s). It is calculated by dividing the sum of squared errors (SSE) by the total sum of squares (SST). The result is a value between 0 and 1, with a higher value indicating a better fit of the data.

2. How is R squared interpreted?

R squared can be interpreted as the percentage of variation in the dependent variable that is explained by the independent variable(s). For example, an R squared value of 0.75 means that 75% of the variation in the dependent variable can be explained by the independent variable(s).

3. What is the difference between R squared and adjusted R squared?

R squared is a measure of how well the independent variable(s) explain the variation in the dependent variable, while adjusted R squared takes into account the number of independent variables in the model. Adjusted R squared penalizes for adding unnecessary variables, and is a more reliable measure of model fit when comparing models with different numbers of variables.

4. Can R squared be negative?

Yes, R squared can be negative. This indicates that the model is worse at predicting the dependent variable than a horizontal line, which would have an R squared value of 0. Negative R squared values can occur when the regression line is a poor fit for the data or when the model is overfitting.

5. Can R squared be used to determine causation?

No, R squared cannot be used to determine causation. It only measures the strength of the relationship between the independent and dependent variable(s). To determine causation, additional research and experimentation is needed.

Similar threads

Replies
4
Views
4K
  • Set Theory, Logic, Probability, Statistics
Replies
1
Views
993
Replies
14
Views
1K
  • Classical Physics
Replies
1
Views
755
  • Beyond the Standard Models
Replies
12
Views
2K
  • High Energy, Nuclear, Particle Physics
Replies
1
Views
1K
  • Science Fiction and Fantasy Media
Replies
13
Views
1K
  • Set Theory, Logic, Probability, Statistics
Replies
1
Views
961
Replies
6
Views
1K
  • Introductory Physics Homework Help
Replies
1
Views
851
Back
Top