turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- SAS Programming
- /
- SAS/GRAPH and ODS Graphics
- /
- regression line in proc gplot

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

09-17-2012 01:04 PM

Hi all,

I'm trying to plot and fit data to a power function (y=ax^b) using proc gplot. The interpol option in the symbol statement allows you to define a type of regression (eg: rl=linear, rq=quadratic etc) but I don't see the power function as being one of them.

Is there perhaps another way to do this? I can easily do this in Excel as the trendline option has the power option........but need to use SAS to do it.

Thanks!

Mike

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Posted in reply to mikepk

10-04-2012 08:17 AM

Do you have some sample data you could post up?

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Posted in reply to mikepk

10-04-2012 10:07 AM

Here's how I normally do this.

- Augment the raw data with new observations that contain x-values that cover the range of your data and are spaced closely together. For example, if your data range is 0 to 10, I would add values 0, 0.01, 0.02, etc. The Y values are missing for these new observations.
- Perform the regression on this augmented data set and save the predicted values
- Plot the original data, and overlay the predicted values for the augmented data. At this point, you can simply connect the predicted value points linearly, that will be close enough for graphical purposes.

--

Paige Miller

Paige Miller