BookmarkSubscribeRSS Feed
KH1
Calcite | Level 5 KH1
Calcite | Level 5

hi,

I need to calculate total time at risk for males and females separately for incidence rate denominator.

I have a variables 'time_major' in days which denotes time in days from T0 to outcome/death/loss to follow up.

 

What I dont know is how to get the total time_major for each sex and use it to get incidence rate per 100 person years. 

The reason is that thhe sum of the total time for males and females cannot exceed the overall time_major. 

 

thanks

KH

3 REPLIES 3
ballardw
Super User

I would help to provide some example data, fake is fine, that illustrates your starting point and what the desired outcome would be. The example data would be best as a data step we can execute and should provide examples of all the behaviors you expect in the data.

KH1
Calcite | Level 5 KH1
Calcite | Level 5

thanks!

 

data b; set a;

input sex $ eventtype time;

datalines;

m  1       3000

f    1       3996

f    1       285 

m   2      4000

m   3      893

m   2      1000

m   2      3952

f     1      123 

f     1      964

m   1      478

m   2      2789

;

run;

 

note: eventtype: 1=contralateral major amputation (MAIN outcome of interest); 2=death; 3=migration from country

time is time to event (contralaterl major amputation/death/migration) from T0 (30 days after surviving a unilateral major amputation) in days

 

I want to calculate incidence of contralateral major amputation per 100 person years among males and females separately.

 

thank you

 

KH1
Calcite | Level 5 KH1
Calcite | Level 5

What I would like to know is if the total time in the incidence rate denominator is the sum of all times or the longest follow up time.

just need to know how to calculate the denominator for incidence rate.

 

I did this:

 

proc sort; by sex;

proc print;

var time;

sum time;

by sex;

run;

 

and it added up time ind ays for all females and males separately. is this correct?

 

 

thanks

 

SAS INNOVATE 2024

Innovate_SAS_Blue.png

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Get the $99 certification deal.jpg

 

 

Back in the Classroom!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 1033 views
  • 0 likes
  • 2 in conversation