Question

In: Computer Science

In R programming produce a scatter plot in which you plot the actual used car prices...

In R programming

produce a scatter plot in which you plot the actual
used car prices (y axis) against the predicted used
car prices. Plot a dotted line showing where the
points would be if the predicted values equalled the
actual values. Give your plot an appropriate title.

# YOUR CODE HERE

Solutions

Expert Solution

##data is not given, using some dummy data
actual_price<-runif(15)
predicted_price<-actual_price+runif(15)
par(mfrow=c(1,2))
plot(predicted_price,actual_price,main="predicted price vs actual price",xlab="predicted",ylab="actual")
predicted_price=actual_price
plot(predicted_price,actual_price,type="l", lty=3,main="when predicted price = actual price",xlab="predicted",ylab="actual")


Related Solutions

Does anyone know the code to use in R programming to create a scatter plot?
Does anyone know the code to use in R programming to create a scatter plot?
There are four numeric columns in R programming language's iris data set. Create a scatter plot...
There are four numeric columns in R programming language's iris data set. Create a scatter plot between the four numeric columns using R programming language and give answers to the following parts. Calculate the correlation between each pair of the four numeric columns in iris. Which pair of variables has the strongest linear relationship? Interpret their ??. Which pair of variables has the weakest linear relationship? Interpret their ??. Which pair(s) of variables can you conclude have a population correlation...
What is the correct interpretation for the correlation coefficient r=1r=1? The scatter plot contains points which...
What is the correct interpretation for the correlation coefficient r=1r=1? The scatter plot contains points which all lie on a horizontal line. The scatter plot contains points which show no discernable relationship. The scatter plot contains points that all lie on a line with negative slope. The scatter plot contains points that all lie on a line with positive slope.
Does anyone know the code to use in R programming to create a box plot?
Does anyone know the code to use in R programming to create a box plot?
You are constructing a scatter plot of excess returns for stock A versus the market index....
You are constructing a scatter plot of excess returns for stock A versus the market index. If the correlation coefficient between stock A and the index is 0.1, you will find that the points of the scatter diagram (select one: all fall on the line of best fit; are widely scattered around the line) and the line of best fit has a (select one: positive; negative) slope. A. all fall on the line of best fit; positive slope B. all...
Use the advertised prices for a used car of a particular model to create a linear...
Use the advertised prices for a used car of a particular model to create a linear model for the relationship between a​ car's Year and its Price. Complete parts a through e. Year   Price ($) 1994   18,194 1994   17,945 1994   16,887 1994   14,447 1995   19,282 1995   19,017 1995   20,849 1995   18,621 1996   22,665 1996   23,081 1997   24,899 1997   25,492 1997   23,703 1997   24,413 1997   23,934 1) Find the equation of the regression line. ​2) Explain the meaning of the slope...
6. In a study of used car prices, a sample of dealerships in a large city...
6. In a study of used car prices, a sample of dealerships in a large city showed a wide discrepancy in the final sales prices. For 50 cars of identical specifications, the following prices were recorded:             Prices                                     Relative Frequency $19200< $19400                                          .10 $19400< $19600                                          .20 $19600< $19800                                          .40 $19800< $20000                                          .30 a. Approximate the mean selling price of these 50 used cars. (6 pts) b. Approximate the median selling price of a used car. (6 pts) 7. A study of loss payment per insurance claim...
Use the advertised prices for a used car of a particular model to create a linear...
Use the advertised prices for a used car of a particular model to create a linear model for the relationship between a​ car's Year and its Price. Complete parts a through e. Year   Price ($) 1994   11,538 1994   12,333 1994   10,436 1994   11,995 1995   14,567 1995   14,658 1995   13,656 1995   15,199 1996   16,192 1996   17,039 1996   19,074 1997   19,823 1997   19,249 1997   19,242 1997   20,577 ​a) Find the equation of the regression line. Price=___ + _____ year b) Explain the...
Assume that the prices of resources used to produce automobiles increases. What does the supply and...
Assume that the prices of resources used to produce automobiles increases. What does the supply and demand model predict will happen as a result in the market for automobiles? Question 4 options: A) Equilibrium price and quantity decrease. B) Equilibrium price increases, and equilibrium quantity decreases. C) Equilibrium price and quantity increase. D) Equilibrium price decreases, and equilibrium quantity increases.
How do you plot continuous versus category in r studio
How do you plot continuous versus category in r studio
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT