100% Guaranteed Results


SAS – Chapter 4: Random Number Generation and Plotting
$ 24.99
Category:

Description

5/5 – (1 vote)

1. Plotting Simple Linear Regression Data
a. Create a data table with Y   0 1X where X ranges from 1 to 30, 0 25 , 1 1, and   ~ N(  0,  5) . Keep only the variables X and Y.
b. Use PROC SGPLOT and the REG statement to plot the line of best fit for the data. Create a plot of the data. Use both the SCATTER and REG statement to plot the points and a line of best fit.
1) Enhance the plot by coloring the points blue and using the symbol STARFILLED 2) Color the regression line red and use the pattern DOT.
3) Add a title of your choosing to the X-axis, Y-axis, and the main title.
4) Use the X-axis limits from 0 to 31, and the Y-axis limits from 15 to 65.
5) Name the legend ‘Scatter’ and ‘Line of Best Fit’ for both plot types.

c. Alter the previous plot by changing the SCATTER statement to NEEDLE and the REG statement to PBSPLINE. (This demonstrates the ease in which plot types can be altered.)

Chapter 4: Random Number Generation and Plotting Page 2 of 2

Reviews

There are no reviews yet.

Be the first to review “SAS – Chapter 4: Random Number Generation and Plotting”

Your email address will not be published. Required fields are marked *

Related products