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

Capture.JPG

I have a data set which displays a "lognormal" shaped dependence of Y on X. The data is radioactive emission rate as a function of time. I see a rapid rise in the early stages followed by a slower decay over time.

 

The code I use is as follows:

 

proc glimmix data = QUERY_FOR_SUB1CT;

model rate = time / dist=lognormal link=log noscale solution;

run;

I found this code in an example in the communities. My question is how do I translate the results into a function that I can use in another program such as Excel. My parameter estimates are:

 

 

Parameter Estimates

Effect

Estimate

Standard
Error

DF

t Value

Pr > |t|

Intercept

-17.2289

65.7665

29249

-0.26

0.7933

time

-0.00013

0

29249

-Infty

<.0001

Scale

11.9519

0.09883

.

.

.

 

I see on Wikipedia that the lognormal pdf is as attached in the pic but I fail to see how to populate this equation given the SAS output.

 

1 ACCEPTED SOLUTION

Accepted Solutions
Rick_SAS
SAS Super FREQ

Are you sure that you want to use LINK=LOG? 

 

To model lognormal data, most people use only DIST=LOGNORMAL and an identity link function.The assumption is that

LOG(rate) is normally distributed and is estimated by 

LOG(RATE) = -17.23 - 0.00013*Time + eps

where eps (the residuals) is normally distributed with a variance that is estimated by the scale parameter.

View solution in original post

2 REPLIES 2
Rick_SAS
SAS Super FREQ

Are you sure that you want to use LINK=LOG? 

 

To model lognormal data, most people use only DIST=LOGNORMAL and an identity link function.The assumption is that

LOG(rate) is normally distributed and is estimated by 

LOG(RATE) = -17.23 - 0.00013*Time + eps

where eps (the residuals) is normally distributed with a variance that is estimated by the scale parameter.

mksas33
Calcite | Level 5

You are correct. I forgot to alter my code in what I posted above. On my machine I am using an identity link, such that results appear as follows.

 

Parameter Estimates

Effect

Estimate

Standard
Error

DF

t Value

Pr > |t|

Intercept

-2.7970

0.01497

29249

-186.85

<.0001

time

-0.00124

0.000120

29249

-10.28

<.0001

Scale

3.5190

0.02910

.

.

.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

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
  • 2 replies
  • 902 views
  • 0 likes
  • 2 in conversation