BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
ugoagwup
Fluorite | Level 6

Hello!

I need some assistance.  A simple linear regression script such as the following would give me a regression plot with 95% CI bounds on defaultRegression PlotRegression Plot.

Proc glm data= Tdata;
model LFTvalues = bckTrans_auc/ solution;
run;
 
Please how can I use Proc SGplot to replicate exact same plot and have full control of things display like removing the title from the plot? 
1 ACCEPTED SOLUTION

Accepted Solutions
ugoagwup
Fluorite | Level 6

Already figured out a way to solve my problem

 

proc sgplot data= Tdata;

reg x=bckTrans_auc y=LFTvalues/CLM CLI;

yaxis label = "AST (Units per liter)";
xaxis label = "AUC(h*ng/mL)";

Run;

 

View solution in original post

4 REPLIES 4
ugoagwup
Fluorite | Level 6

Thanks @Reeza 

The following codes solved my problem

 

 proc sgplot data= Tdata; reg x= bckTrans_auc y=LFTvalues/CLM CLI; yaxis label = "AST (Units per liter)"; xaxis label = "AUC(h*ng/mL)"; Run; 

 

Please do you know how I can include the regression equation on the plot?

 

Reeza
Super User
AFAIK there isn't an option for that but you can check the INSET statement or REG statement options which is where I'd expect to see it.
Otherwise, here's an alternative method.
https://blogs.sas.com/content/iml/2013/02/27/slope-of-a-regression-line.html
ugoagwup
Fluorite | Level 6

Already figured out a way to solve my problem

 

proc sgplot data= Tdata;

reg x=bckTrans_auc y=LFTvalues/CLM CLI;

yaxis label = "AST (Units per liter)";
xaxis label = "AUC(h*ng/mL)";

Run;

 

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 4 replies
  • 1233 views
  • 5 likes
  • 2 in conversation