2 December 2004PubH8420: Parametric Regression Models Slide 1 Applications - SAS Parametric Regression in SAS –PROC LIFEREG –PROC GENMOD –PROC LOGISTIC.

Slides:



Advertisements
Similar presentations
A. The Basic Principle We consider the multivariate extension of multiple linear regression – modeling the relationship between m responses Y 1,…,Y m and.
Advertisements

Data: Crab mating patterns Data: Typists (Poisson with random effects) (Poisson Regression, ZIP model, Negative Binomial) Data: Challenger (Binomial with.
A Model to Evaluate Recreational Management Measures Objective I – Stock Assessment Analysis Create a model to distribute estimated landings (A + B1 fish)
Logistic Regression I Outline Introduction to maximum likelihood estimation (MLE) Introduction to Generalized Linear Models The simplest logistic regression.
Overview of Logistics Regression and its SAS implementation
Generalized Linear Mixed Model English Premier League Soccer – 2003/2004 Season.
April 25 Exam April 27 (bring calculator with exp) Cox-Regression
Logistic Regression Multivariate Analysis. What is a log and an exponent? Log is the power to which a base of 10 must be raised to produce a given number.
1 Statistics 262: Intermediate Biostatistics Kaplan-Meier methods and Parametric Regression methods.
Some Terms Y =  o +  1 X Regression of Y on X Regress Y on X X called independent variable or predictor variable or covariate or factor Which factors.
Part 21: Hazard Models [1/29] Econometric Analysis of Panel Data William Greene Department of Economics Stern School of Business.
Linear statistical models 2009 Models for continuous, binary and binomial responses  Simple linear models regarded as special cases of GLMs  Simple linear.
PH6415 Review Questions. 2 Question 1 A journal article reports a 95%CI for the relative risk (RR) of an event (treatment versus control as (0.55, 0.97).
1 BAMS 580B Lecture 2 Part 1 – LTC Planning. 2 Topics  LTC Capacity Planning  Objectives  Approaches LBH Deterministic Model – Parameter Estimation.
Chapter 11 Survival Analysis Part 2. 2 Survival Analysis and Regression Combine lots of information Combine lots of information Look at several variables.
EPI 809/Spring Multiple Logistic Regression.
1 Modeling Ordinal Associations Section 9.4 Roanna Gee.
Logistic Regression Biostatistics 510 March 15, 2007 Vanessa Perez.
Deaths of snails vs exposure by species. Deaths of snails vs exposure by temperature.
OLS versus MLE Example YX Here is the data:
WLS for Categorical Data
Adjusting for extraneous factors Topics for today More on logistic regression analysis for binary data and how it relates to the Wolf and Mantel- Haenszel.
Linear statistical models 2009 Count data  Contingency tables and log-linear models  Poisson regression.
Accelerated Failure Time (AFT) Model As An Alternative to Cox Model
1 B. The log-rate model Statistical analysis of occurrence-exposure rates.
Survival Analysis A Brief Introduction Survival Function, Hazard Function In many medical studies, the primary endpoint is time until an event.
1 Kaplan-Meier methods and Parametric Regression methods Kristin Sainani Ph.D. Stanford University Department of Health.
Logistic Regression II Simple 2x2 Table (courtesy Hosmer and Lemeshow) Exposure=1Exposure=0 Disease = 1 Disease = 0.
GEE and Generalized Linear Mixed Models
17. Duration Modeling. Modeling Duration Time until retirement Time until business failure Time until exercise of a warranty Length of an unemployment.
SAS Lecture 5 – Some regression procedures Aidan McDermott, April 25, 2005.
STT : BIOSTATISTICS ANALYSIS Dr. Cuixian Chen Chapter 8: Fitting Parametric Regression Models STT
Logistic Regression III: Advanced topics Conditional Logistic Regression for Matched Data Conditional Logistic Regression for Matched Data.
Simple Linear Regression
STT : Biostatistics Analysis Dr. Cuixian Chen
Logit model, logistic regression, and log-linear model A comparison.
1 Experimental Statistics - week 10 Chapter 11: Linear Regression and Correlation.
EIPB 698E Lecture 10 Raul Cruz-Cano Fall Comments for future evaluations Include only output used for conclusions Mention p-values explicitly (also.
ALISON BOWLING THE GENERAL LINEAR MODEL. ALTERNATIVE EXPRESSION OF THE MODEL.
April 6 Logistic Regression –Estimating probability based on logistic model –Testing differences among multiple groups –Assumptions for model.
Applied Epidemiologic Analysis Fall 2002 Patricia Cohen, Ph.D. Henian Chen, M.D., Ph. D. Teaching Assistants Julie KranickSylvia Taylor Chelsea MorroniJudith.
4-Oct-07GzLM PresentationBIOL The GzLM and SAS Or why it’s a necessary evil to learn code! Keith Lewis Department of Biology Memorial University,
Different Distributions David Purdie. Topics Application of GEE to: Binary outcomes: – logistic regression Events over time (rate): –Poisson regression.
1 היחידה לייעוץ סטטיסטי אוניברסיטת חיפה פרופ’ בנימין רייזר פרופ’ דוד פרג’י גב’ אפרת ישכיל.
When and why to use Logistic Regression?  The response variable has to be binary or ordinal.  Predictors can be continuous, discrete, or combinations.
April 4 Logistic Regression –Lee Chapter 9 –Cody and Smith 9:F.
Applied Epidemiologic Analysis - P8400 Fall 2002 Lab 9 Survival Analysis Henian Chen, M.D., Ph.D.
Pro gradu –thesis Tuija Hevonkorpi.  Basic of survival analysis  Weibull model  Frailty models  Accelerated failure time model  Case study.
Lecture 12: Cox Proportional Hazards Model
STT : BIOSTATISTICS ANALYSIS Dr. Cuixian Chen Chapter 7: Parametric Survival Models under Censoring STT
Log-linear Models HRP /03/04 Log-Linear Models for Multi-way Contingency Tables 1. GLM for Poisson-distributed data with log-link (see Agresti.
1 Topic 4 : Ordered Logit Analysis. 2 Often we deal with data where the responses are ordered – e.g. : (i) Eyesight tests – bad; average; good (ii) Voting.
Sigmoidal Response (knnl558.sas). Programming Example: knnl565.sas Y = completion of a programming task (1 = yes, 0 = no) X 2 = amount of programming.
We’ll now look at the relationship between a survival variable Y and an explanatory variable X; e.g., Y could be remission time in a leukemia study and.
Lecture 3: Parametric Survival Modeling
Applied Epidemiologic Analysis - P8400 Fall 2002 Labs 6 & 7 Case-Control Analysis ----Logistic Regression Henian Chen, M.D., Ph.D.
Treat everyone with sincerity,
Logistic Regression Saed Sayad 1www.ismartsoft.com.
1 Say good things, think good thoughts, and do good deeds.
Dependent Variable Discrete  2 values – binomial  3 or more discrete values – multinomial  Skewed – e.g. Poisson Continuous  Non-normal.
Applied Epidemiologic Analysis - P8400 Fall 2002 Labs 6 & 7 Case-Control Analysis ----Logistic Regression Henian Chen, M.D., Ph.D.
REGRESSION MODEL FITTING & IDENTIFICATION OF PROGNOSTIC FACTORS BISMA FAROOQI.
Analysis of matched data Analysis of matched data.
[Topic 11-Duration Models] 1/ Duration Modeling.
Generalized Linear Models
ביצוע רגרסיה לוגיסטית. פרק ה-2
Survival Analysis {Chapter 12}
Parametric Survival Models (ch. 7)
Treat everyone with sincerity,
Presentation transcript:

2 December 2004PubH8420: Parametric Regression Models Slide 1 Applications - SAS Parametric Regression in SAS –PROC LIFEREG –PROC GENMOD –PROC LOGISTIC Reference: SAS ver. 8.0 SAS/STAT User’s Guide, SAS Institute, Inc., Cary, NC

2 December 2004PubH8420: Parametric Regression Models Slide 2 Applications – PROC LIFEREG Mathematical Model where y is a vector of response values, (often the log of the failure times) X is a matrix of covariates variables (usually including an intercept term), β is a vector of unknown regression parameters σ is an unknown scale parameter, and ε is a vector of errors (assumed to come from any known distribution)

2 December 2004PubH8420: Parametric Regression Models Slide 3 Applications – PROC LIFEREG Log Likelihood –if all the responses are observed, where –If some of the responses are right censored,

2 December 2004PubH8420: Parametric Regression Models Slide 4 Applications – PROC LIFEREG Model & Estimation –Accelerated Failure Time (Life) Model The effect of independent variables on an event time distribution is multiplicative on the event time The effect of the covariates : change the scale of a baseline distribution of failure times, not the location –Estimation : MLE using a Newton-Raphson algorithm –Standard Errors of the parameter estimates : the inverse of the observed information matrix –Test : Normal based Test (e.g. chi-sq test, LRT)

2 December 2004PubH8420: Parametric Regression Models Slide 5 Applications – PROC LIFEREG Kidney Transplant Data PROC FORMAT; VALUE female 0='Male' 1='Female'; VALUE algfmt 0='Non-ALG' 1='ALG'; RUN DATA kidney; INFILE "surd01.dat"; INPUT id 1-4 age 5-6 sex 7 Alg 22 duration status 28; lntime = log(duration); FORMAT sex female. Alg algfmt.; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 6 Applications – PROC LIFEREG Exponential Regression TITLE1 "Kidney Transplants Data"; PROC LIFEREG DATA=kidney; CLASS ALG; MODEL DURATION*STATUS(0)= ALG/ DIST=EXPONENTIAL; OUTPUT OUT=out CDF=prob; TITLE2 "Simple Exponential Regression”; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 7 Applications – PROC LIFEREG Kidney Transplants Data 1 Simple Exponential Regression The LIFEREG Procedure Model Information Data Set WORK.KIDNEY Dependent Variable Log(duration) Censoring Variable status Censoring Value(s) 0 Number of Observations 469 Noncensored Values 192 Right Censored Values 277 Left Censored Values 0 Interval Censored Values 0 Name of Distribution Exponential Log Likelihood Algorithm converged. Output

2 December 2004PubH8420: Parametric Regression Models Slide 8 Applications – PROC LIFEREG Type III Analysis of Effects Wald Effect DF Chi-Square Pr > ChiSq ALG Analysis of Parameter Estimates Standard 95% Confidence Chi- Parameter DF Estimate Error Limits Square Intercept Alg ALG Alg Non-ALG Scale Weibull Shape Output Continued

2 December 2004PubH8420: Parametric Regression Models Slide 9 Applications – PROC LIFEREG Interpretation (Risk = λ exp(xβ) ) –λ = Exp(-β0) = exp(-4.215) = –β1 = coefficient for ALG = –RR(ALG=1:ALG=0) = exp(β1) = the risk of ALG group = λ exp(β1) = 0.015*0.654 = the risk of Non-ALG group = λexp(0) = Testing & Conclusion –Using ALG decreased the risk 34.6% –Significant effect ( )

2 December 2004PubH8420: Parametric Regression Models Slide 10 Applications – PROC LIFEREG Estimated CDF of Residuals Vs. Observed Duration

2 December 2004PubH8420: Parametric Regression Models Slide 11 Applications – PROC LIFEREG Multiple Regression PROC LIFEREG DATA=kidney; CLASS ALG; MODEL DURATION*STATUS(0)= AGE ALG/ DIST=EXPONENTIAL; OUTPUT OUT=out QUANTILES=.5 STD=STD P=MED_DURATION; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 12 Applications – PROC LIFEREG Estimation Comparison Exponential RegressionCox Regression Para- meter Hazards Ratio 95% Confidence Limits Hazards Ratio 95% Confidence Limits age ALG

2 December 2004PubH8420: Parametric Regression Models Slide 13 Applications – PROC LIFEREG Predicted Values and Confidence Intervals DATA out1; SET out; ltime=log(med_duration); stde=std/med_duration; upper=exp(ltime+1.64*stde); lower=exp(ltime-1.64*stde); RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 14 Applications – PROC LIFEREG Median Predicted Values Vs. AGE by the Use of ALG

2 December 2004PubH8420: Parametric Regression Models Slide 15 Applications – PROC LIFEREG Other supported distributions –Generalized Gamma –Loglogistic –Lognormal –Weibull Some relations among the distributions: The Weibull with Scale=1 : exponential distribution The gamma with Shape=1 : Weibull distribution. The gamma with Shape=0 : lognormal distribution.

2 December 2004PubH8420: Parametric Regression Models Slide 16 Applications – PROC GENMOD Piecewise exponential distribution (Poisson Regression) TITLE1 "Kidney Transplants Data"; PROC GENMOD DATA=kidney; CLASS ALG; MODEL STATUS = AGE ALG/ DIST=POISSON LINK=log OFFSET=lntime type3; TITLE2 "Multiple Piecewise Exponential Regression"; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 17 Applications – PROC LOGISTIC Dichotomized data DATA kidney1; SET kidney; DO month=1 TO duration; IF month=duration AND status=1 THEN fail=1; ELSE fail=0; OUTPUT; END; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 18 Applications – PROC LOGISTIC LOGISTIC REGRESSION with LOGIT LINK PROC LOGISTIC DATA=kidney1; CLASS month fail/ PARAM=reference REF=first; MODEL fail=age ALG; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 19 Applications – PROC LOGISTIC LOGISTIC REGRESSION with CLOGLOG LINK PROC LOGISTIC DATA=kidney1 ; CLASS month fail/ PARAM=reference REF=first; MODEL fail=age ALG/ LINK=CLOGLOG; RUN;

2 December 2004PubH8420: Parametric Regression Models Slide 20 Applications - SAS Comparison of Parameter Estimates –Hazards Ratio in Log Scale PHREGLIFEREGGENMODLOGISTIC MethodCox Reg. Exp. Reg ( -β ) Piecewise Exp. Reg LOGITCLOGLOG AGE ALG