Data visualization with SAS programming

SGPLOT Scatter with Log Scale

Reply
Contributor GDA
Contributor
Posts: 21

SGPLOT Scatter with Log Scale

I'm trying to create a simple scatter chart with the Y axis log transformed. Reading the help documentation seems simple enough but it still creates a linear Y axis. What am I missing?


proc sgplot data=WORK.DATA;
SCATTER x=TIME_EACH_MEASUREMENT y=NUM_ERRS /
GROUP=Failure_Cause;
YAXIS TYPE=LOG LOGSTYLE=LOGEXPAND LOGBASE=10;
run;
Contributor GDA
Contributor
Posts: 21

Re: SGPLOT Scatter with Log Scale

Ah Ha. Found it. Turns out I had a couple of negative values in the data set. I guess I should read the log even when an error doesn't occur.
Ask a Question
Discussion stats
  • 1 reply
  • 2661 views
  • 0 likes
  • 1 in conversation