BookmarkSubscribeRSS Feed
ChrisMac
Fluorite | Level 6

Hi,

 

I have some problems creating cumulative incidence curves with number-at-risk tables. I am using the %CIF-macro, though it does not provide me any information on number-at-risk at any given time.

 

Thanks in advance!

7 REPLIES 7
Reeza
Super User

If you're using SAS 9.4 it supports the Cumulative Incidence Risk within PROC PHREG

ChrisMac
Fluorite | Level 6

Hi Reeza!

Thanks for the reply. However, PROC PHREG does not provide me with the numbers at risk at any given time 😕

Reeza
Super User

The OUTCIF dataset on PROC LIFETEST - sorry wrong proc initially. 

It seems to generate the ATRISK numbers....add the OUTCIF option as specified in the docs to the following example:

 

http://documentation.sas.com/api/docsets/statug/14.2/content/statug_code_liftex4.htm?locale=en

 

http://documentation.sas.com/?docsetId=statug&docsetTarget=statug_lifetest_syntax01.htm&docsetVersio...

ChrisMac
Fluorite | Level 6

OUTCIF only works in SAS/STAT and not SAS 9.4 unfortunately 😞

 

Reeza
Super User

@ChrisMac wrote:

OUTCIF only works in SAS/STAT and not SAS 9.4 unfortunately 😞

 


If you don't have SAS STAT how are you doing any survival analysis...

I'm assuming that means you're not on SAS 9.4, because it's definitely available in 9.4 - I did test before responding.

 

 

 

 

ChrisMac
Fluorite | Level 6

Hi,

 

I do have SAS 9.4. However, it wont run. This is the output:

 

proc lifetest data=surgery2; time follow_up*death(0); run;

This one works. However, the next one does not work:

 

57 proc lifetest data=surgery2 outcif=test3; time follow_up*death(0); run;
------
22
76
ERROR 22-322: Syntax error, expecting one of the following: ;, (, AALEN, ALPHA, ALPHAQT,
ANNOTATE, ATRISK, BANDMAX, BANDMAXTIME, BANDMIN, BANDMINTIME, CENSOREDCOLOR,
CENSOREDSYMBOL, CONFBAND, CONFTYPE, DATA, DESCRIPTION, EVENTSYMBOL, FORMCHAR, GOUT,
GRAPHICS, INTERVALS, LANNOTATE, LINEPRINTER, MAXTIME, METHOD, MISSING, NELSON,
NINTERVAL, NOCENSPLOT, NOLEFT, NOPRINT, NOTABLE, OUTS, OUTSURV, OUTT, OUTTEST,
PLOTS, REDUCEOUT, SID, SINGULAR, STDERR, TIMELIM, TIMELIST, WIDTH.

ERROR 76-322: Syntax error, statement will be ignored.

 

Likewise, this one doesn't work either:

 

58 proc lifetest data=surgery2 plots=cif(test); time follow_up*death(0); run;
---
22
76
ERROR 22-322: Syntax error, expecting one of the following: (, ALL, CENSOR, CENSORED, D, DENSITY,
H, HAZ, HAZARD, LLS, LOGLOGS, LOGSURV, LS, NONE, P, PDF, S, SUR, SURV, SURVIVAL.

ERROR 76-322: Syntax error, statement will be ignored.

Rick_SAS
SAS Super FREQ

The OUTCIF= option was added in SAS/STAT 14.1, which was released as part of 9.4M3 in July 2015. 

You can submit the statement

%put &=SYSVLONG;

and look in the SAS log to find your version of SAS.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 7 replies
  • 5474 views
  • 3 likes
  • 3 in conversation