Help using Base SAS procedures

How to get base variable in this figure

Reply
Contributor
Posts: 64

How to get base variable in this figure

Please help how to get the BASE variable from AVAL variable ...

My concern is how to retain the base values for even above observation of basline in AVISIT


Screenshot_2013-09-07-11-29-42-343835749.png
Trusted Advisor
Posts: 1,128

Re: How to get base variable in this figure

hi Dr.Majeti,

i tried to explain with a sample data, hope it helps yo

data have;

    infile cards missover;

    input group visit$ aval ablfl $;

cards;

1 SCR   0

1 run   1

1 week0 2    Y

1 week1 1   

1 week2 4   

1 week3 5   

2 SCR   0

2 run   1

2 week0 3    Y

2 week1 1   

2 week2 4   

2 week3 5   

;

run;

proc sort data=    have;

    by group descending ablfl;

run;

data want;

    set have;

    by group descending ablfl;

    retain base;

    if ablfl='Y' then base=aval;

run;

proc sort data=    want;

    by group visit ablfl;

run;

Thanks,

Jagadish

Thanks,
Jag
Ask a Question
Discussion stats
  • 1 reply
  • 147 views
  • 3 likes
  • 2 in conversation