search for: phreg

Displaying 20 results from an estimated 20 matches for "phreg".

Did you mean: p_reg
2007 Jan 10
2
SAS and R code hazard ratios
Greetings, I am new to R and have been comparing CPH survival analysis hazard ratios between R and SAS PhReg. The binary covariates' HRs are the same, however the continuous variables, for example age, have quite different HRs although in the same direction. SAS PhReg produces HRs which are the change in risk for every one increment change in the independent variable. How do I interpret the HRs...
2011 Feb 27
3
nested case-control study
...regression for nested case-control study as described in "Estimation of absolute risk from nested case-control data" by Langholz and Borgan (1997) where Horvitz-Thompson sampling weight (log of (number in the risk set divided by the number sampled)) is used with regression. In SAS Proc Phreg, this is implemented as an offset (offset=logweight). I checked clogistic() in Epi package and clogit() in survival package, but couldn't figure out how to incorporate this weighting with either. Also when considering nested case-control sampling for Cox proportional hazards model, the a...
2008 Dec 04
1
comparing SAS and R survival analysis with time-dependent covariates
...3) on Linux) survival analyses with time-dependent covariates. The results differed significantly so I tried to understand on a short example where I went wrong. The following example shows that even when argument 'method' in R function coxph and argument 'ties' in SAS procedure phreg are the same, the results of Cox regr. are different. This seems to happen when there are ties in the events/covariates times. My question is what software, R or SAS, is more reliable for the survival analysis with time-dependent covariates or if you could point out a problem in the following...
2011 Aug 21
3
pooled hazard model with aftreg and time-dependent variables
...: >> weibullaft<-aftreg(Surv(sta,time,S) ~ TDC1 + TIC1 + sample + individual, >> dist="weibull", >> data.frame=Data, id=ID) , it appears an error with aftreg saying: Error in solve.default(fit$hessian) : Lapack routine dgesv: system is exactly singular With phreg the error is: fail in [dsytrf]; info = 14 1 - I am probably doing something wrong. Any suggestion to control for individuals too would be highly appreciated. 2 - Is including factor(sample) enough to control for the samples? Data S sta time TDC1 total_time TIC1 ID sample...
2011 Jul 20
0
comparing SAS and R survival analysis with time-dependent covariates
...100% death rate in group 1 vs. 0% in group 0, at all the time points where the two groups can be compared. Section 3.5 of Therneau and Grambsch, Extending the Cox Model, has a picture of the log-likelihood in such a case, which very quickly approaches an asymptote as beta goes to infinity. Both phreg and coxph iterate until the loglik "doesn't change anymore". The printed solution depends entirely on the convergence criteria, which are slightly different in the two programs. I chose to add a warning message. Final note: I never use the discrete option, having found the Efron ap...
2013 Apr 24
2
Trouble Computing Type III SS in a Cox Regression
I should hope that there is trouble, since "type III" is an undefined concept for a Cox model. Since SAS Inc fostered the cult of type III they have recently added it as an option for phreg, but I am not able to find any hints in the phreg documentation of what exactly they are doing when you invoke it. If you can unearth this information, then I will be happy to tell you whether a. using the test (whatever it is) makes any sense at all for your data set b. if "a"...
2005 Jun 22
1
A question on time-dependent covariates in the Cox model.
...osed group (dose between 5 and 60). For some reason there is a theory of the dose increasing its effect over time (however it was only given (and measured) once = at the time of examination). I tested a model: coxph(Surv(time,dod)~dose + dose:time) Previously I tested the model in SAS: proc phreg data=test; model time*dod(0)=dose dosetime /rl ties=efron; dosetime=time*dose; run; Without the interaction terms I get the same results for the two models. By including the interaction terms I do not. The model in R gives a negative coefficient for the interaction term which is expected to b...
2011 Sep 05
1
SAS code in R
...have used the code below to obtain the survival estimates (at 1 year) and confidence intervals for combinations of risk factors for my outcome. /* Combinations of Risk Factors */ data test2; input sex treat; DATALINES; 0 0 1 0 0 1 1 1 ; run; /* Survival estimates for the above combinations */ proc phreg data = pudat2; model withtime*wcens(0) = sex treat /ties = efron; baseline out = surv2 survival = survival lower = slower upper = supper covariates = test2 /method = ch nomean cltype=loglog; run; /* Survival estimates at 1 year */ proc print data = surv2 noobs; where withtime = 364; run;...
2010 Feb 19
1
eha aftreg performance
G?ran, thanks for the update, I'm just about to install it! Just wanted to drop you a short line about performance (as you once requested): aftreg takes ages on my windows machine to calculate a small set of 7 observations which are not even grouped together by "id". To be a bit more precise, it takes 2:40 mins on my Intel T9300 Core2 Duo @ 2.5 GHz. Bigger samples with about 700
2011 Apr 01
2
Cox Proportional Hazards model with a time-varying covariate
...31   5 0 C 4  .   332  10 1 C 3  . 333  16 0 C 3  .   334  -2 1 C 4  .   335  17 0 C 4  . 336  16 0 C 4  .   337  16 1 C 3  .   338  33 1 C 3 20 339  24 0 C 3 11   340  12 1 C 3  .   341  27 1 C 4 18 342   2 1 C 4  .   343  -6 0 C 4  .   344 -20 1 C 4  . 345  14 0 C 3  .   346   3 1 C 3  . ;   PROC PHREG DATA = VITCLEAR;     MODEL RSPTIM*CENS(0) = TRT DENS INFCTN / TIES = EXACT;     IF INFTIM GT RSPTIM OR INFTIM = . THEN INFCTN = 0;     ELSE INFCTN = 1;     STRATA CENTER;     TITLE1 'Cox Proportional Hazards Model';     TITLE2 'Example 22.2: Hyalurise in Vitreous Hemorrhage' ; RUN;...
2008 Jun 16
1
回复: cch() and coxph() for case-cohort
...ter selection, but coxph does not contain info of cohort size=4028. The rough estimate between coxph() and cch() is same, but the lower and upper CI and P-value are a little different. Can we exactly use coxph() to repeat cch() using with appropriate configuration in coxph()? Is SAS a better way(PHREG,CASECOH.SAS) to implement time-dependent case-cohort? > summary(fit2.ccP) Call: coxph(formula = Surv(edrel, rel) ~ stage + histol + age + offset(-100 * (1 - subcohort)) + cluster(seqno), data = ccoh.data) n= 1154 coef exp(coef) se(coef) robust se z p stageII 0.7363...
2009 Jan 16
3
Fitting of lognormal distribution to lower tail experimental data
Hi, I am beginner with R and need firm guidance with my problem. I have seen some other threads discussing the subject of right censored data, but I am not sure whether or not this problem can be regarded as such. Data: I have a vector with laboratory test data (strength of wood specimens, example attached as txt-file). This data is the full sample. It is a common view that this kind of data
2008 Jun 16
0
cch() and coxph() for case-cohort
...ter selection, but coxph does not contain info of cohort size=4028. The rough estimate between coxph() and cch() is same, but the lower and upper CI and P-value are a little different. Can we exactly use coxph() to repeat cch() using with appropriate configuration in coxph()? Is SAS a better way(PHREG,CASECOH.SAS) to implement time-dependent case-cohort? <output deleted> ----------end included message -------------------- I showed you how to do time-dependent case cohort analysis. Stop complaining and use the advice. No, SAS will not be better. It will be different due to default...
2008 Oct 22
2
Weibull parameter estimation
Dear R-users I would like to fit weibull parameters using "Method of moments" in order to provide the inital values of the parameter to de function 'fitdistr' . I don`t have much experience with maths and I don't know how to do it. Can anyone please put me in the rigth direction? Borja [[alternative HTML version deleted]]
2011 Mar 07
0
survest() for cph() in Design package
...0WLM smoke25: independent variable 2 (0/1), 1/2+ pack/dat at age 25 logw: weight to be used as an offset in the model rstime2: indicator variable to indicate whether age is below 50, 50-69 or >=70, used as strata in the model The SAS code is (if this helps to address my question/problem) proc phreg data=uminers; model rstime*cc(0)=cr500 smoke25/ entry=rsentry offset=logw rl; baseline out=ch covariates=covs cumhaz=cumhaz stdcumhaz=secumhaz lowercumhaz=lci uppercumhaz=uci/ nomean; strata rstime2; run; My R code is: library(survival) library(Design) > uminers<-read.table("umi...
2007 Jun 13
0
"R is not a validated software package..
...stubborn about SAS vs S, I have one example I like to argue with. The S survival code has an extensive test suite, including a set of small examples where I have worked out the correct results by hand. Many of these latter are documented in the appendix of the Therneau and Grambsch book. The SAS phreg procedure does not pass all the tests. (Cox model + Efron approx for ties + deviance residuals for one. The size of the error is numerically insignificant, a 1/n vs 1/(n-1) type of thing: but it leads to slightly different robust standard errors).
2009 Jun 15
2
Schoenfeld Residuals with tied data
Dear all, I am struggling with calculation of Schoenfeld residuals of my Cox Ph models. Based on the formula as attached, I calculated the Schoenfeld residuals for both non tied and tied data, respectively. And then I validated my results with R using the same data sets. However, I found that my results for non-tied data was ok but the results for tied data were different from R's. How
2004 Jul 04
2
smooth non cumulative baseline hazard in Cox model
...- France ------------ SMOOTH Macro (SAS) ------------ %macro smooth (data=_last_, time=, width=, survival=survival); /********************************************************************* MACRO SMOOTH produces graphs of smoothed hazard functions using output from either PROC LIFETEST or PROC PHREG. With PROC LIFETEST, it uses the data set produced by the OUTSURV option in the PROC statement. With PROC PHREG, it uses the data set produced by the BASELINE statement. SMOOTH employs a kernel smoothing method described by H. Ramlau-Hansen (1983), "Smoothing Counting Process Intensities b...
2010 Dec 10
1
survreg vs. aftreg (eha) - the relationship between fitted coefficients?
Dear R-users, I need to use the aftreg function in package 'eha' to estimate failure times for left truncated survival data. Apparently, survreg still cannot fit such models. Both functions should be fitting the accelerated failure time (Weibull) model. However, as G?ran Brostr?m points out in the help file for aftreg, the parameterisation is different giving rise to different
2009 Oct 27
2
cox regression extract strata as numeric
Hi there, I perform a stratified cox and then I need the strata as a  numeric array "straft.ln" ft.ln <- coxph(Surv(times,deaths)~ages+chemos+chemos:f1+chemos:f2+horms+horms:f1+horms:f2+grades+grades:f1+grades:f2+positives+positives:f1+positives:f2+sizes+sizes:f1+sizes:f2+strata(stra),data=ddd) basehazzft.ln=basehaz(ft.ln,centered=FALSE) H0ft.ln=c(basehazzft.ln[,1])