search for: medschl

Displaying 18 results from an estimated 18 matches for "medschl".

2009 Feb 27
2
Competing risks adjusted for covariates
Dear R-users Has anybody implemented a function/package that will compute an individual's risk of an event in the presence of competing risks, adjusted for the individual's covariates? The only thing that seems to come close is the cuminc function from cmprsk package, but I would like to adjust for more than one covariate (it allows you to stratify by a single grouping vector). Any
2012 Jul 11
4
Help with loop
Hi, I have two dataframes: The first, df1, contains some missing data: cola colb colc cold cole 1 NA 5 9 NA 17 2 NA 6 NA 14 NA 3 3 NA 11 15 19 4 4 8 12 NA 20 The second, df2, contains the following: cola colb colc cold cole 1 1.4 0.8 0.02 1.6 0.6 I'm wanting all missing data in df1$cola to be replaced by the value of df2$cola.
2006 Jul 05
0
Problem with coxme
------------- Begin Forwarded Message ------------- Date: Wed, 5 Jul 2006 09:09:14 -0500 (CDT) From: Terry Therneau <therneau at mayo.edu> Subject: RE: Problem with coxme To: jhz22 at medschl.cam.ac.uk Cc: R-help at stat.mat.ethz.ch, liulei at virginia.edu, spencer.graves at pdf.com Content-MD5: BXKVsHtW/1I9mIUqrXBU0g== The original question involved a strange error message from coxme when trying to fit a random slopes model: coxme(Surv(time, status) ~ rx+x2, data=rats2, random...
2009 May 20
1
turning off specific types of warnings
Dear R users, I have a long function that among other things uses the "survest" function from the Design package. This function generates the warning: In survest.cph (...) S.E. and confidence intervals are approximate except at predictor means. Use cph(...,x=T,y=T) (and don't use linear.predictors=) for better estimates. I would like to turn this specific warning off, as it
2012 Jan 17
2
An "unsubsettable object" in a mixed model
I am having problems using the /lme /command to fit mixed models. I have a data set similar to longitudinal data, except the hypothesised correlation is between observations taken from different individuals in the same family rather than from the same individual at different times. As soon as I try to specify any correlation structure other than independent, I get the error message
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
2010 Apr 14
5
Running cumulative sums in matrices
Dear R-helpers, I have a huge data-set so need to avoid for loops as much as possible. Can someone think how I can compute the result in the following example (that uses a for-loop) using some version of apply instead (or any other similarly super-efficient function)? example: #Suppose a matrix: m1=cbind(1:5,1:5,1:5) #The aim is to create a new matrix with every column containing the
2010 Dec 11
0
is there a packge or code to generate markov chains in R
...ined, reproducible code. > -- Henrique Dallazuanna Curitiba-Paran?-Brasil 25? 25' 40" S 49? 16' 22" O [[alternative HTML version deleted]] ------------------------------ Message: 41 Date: Fri, 10 Dec 2010 16:21:29 -0000 From: "Eleni Rapsomaniki" <er339 at medschl.cam.ac.uk> To: <r-help at r-project.org> Subject: [R] survreg vs. aftreg (eha) - the relationship between fitted coefficients? Message-ID: <807B01905E122642ACFED8271250B0C306129AF8 at me-mail1.medlan.cam.ac.uk> Content-Type: text/plain; charset="iso-8859-1" Dear R-users,...
2009 Feb 16
1
How do i compute predicted failure time from a cox model?
Given a cox model: library(Hmisc); library(survival); (library(Design); cox.model=cph(Surv(futime, fustat) ~ age, data=ovarian, surv=T) str(cox.model) What I need is the total estimated time until failure (death), not the probability of failing at a given time (survival probability), or hazard etc, which is what I get from survest and predict for example. I suspect the answer is
2009 Oct 13
2
update.formula drop interaction terms
Dear R users, How do I drop multiplication terms from a formula using update? e.g. forml=as.formula("Surv(time, status) ~ x1+x2+A*x3+A*x4+B*x5+strata(sex)") #I would like to drop all instances of variable A (the main effect and its interactions). The following: updated.forml=update(forml, ~ . -A) #gives me this: #Surv(time, status) ~ x1 + x2 + x3 + x4 + B + x5 + strata(sex) + A:x3 +
2011 Oct 02
0
Arimax First-Order Transfer Function
Dear list members, I am a (very) recent convert to R and I am hoping you can help me with a problem I'm having. I'm trying to fit a first-order transfer function to an ARIMA intervention analysis using the "arimax" function. The data was obtained from McCleary & Hay (1980) (via Rob Hyndman's Time Series Library: http://robjhyndman.com/tsdldata/data/schizo.dat). It has
2007 Sep 07
0
Modules which require gcc4 to build
Dear R-Devel, we use R on 32 and 64 bit versions of RHEL AS 4 (U5) where the default compiler is gcc 3. However recently we have had problems updating MCMCpack which appears to require gcc4. I have a few questions. a) Is it OK to mix and match gcc3 and gcc4? b) Should we recompile the whole of R under gcc4? c) On posting to the RHEL 4 list one respondent said not to touch gcc4 with a barge
2010 Jul 19
1
divide grid.newpage into two?
Hi, ? Is there some easy way to split the grid.newpage() into two columns? For example, how could I put the two forest plots below (meta1 and meta2) next to each other? library(meta) data(Olkin95) meta1 <- metabin(event.e, n.e, event.c, n.c,data=Olkin95, subset=c(41,47,51,59),sm="RR", meth="I",studlab=author) meta2=meta1 meta2$studlab=rep("",length(meta1$studlab)
2009 Nov 23
1
Calibration score for survival probability
Good afternoon! I need to evaluate the goodness-of-fit (aka calibration) for survival probability estimates from a Cox model. I tried to use 'calibrate' in the Design package but I'm not sure if it should/would produce what I need (ie a chi-sq type statistic with a table of expected vs observed probabilities). Any other functions I should be aware of? Also, has anybody come across
2011 Jul 08
1
survConcordance with 'counting' type Surv()
Dear Prof. Therneau I was impressed to discover that the 'survConcordance' now handles Surv() objects in counting format (example below to clarify what I mean). This is not documented in the help page for the function. I am very curious to see how a c-index is estimated in this case, using just the linear predictors. It was my impression that with left truncation the ordering of
2009 Feb 18
1
Age as time-scale in a cox model-How to calculate x-time risk?
Dear R users, My question is more methodology related rather than specific to R usage. Using time on study as time in a cox model, eg: library(Design) stanf.cph1=cph(Surv(time, status) ~ t5+id+age, data=stanford2, surv=T) #In this case the 1000-day survival probability would be: stanf.surv1=survest(stanf.cph1, times=1000) #Age in this case is a covariate. #I now want to compare the above
2011 Jun 24
1
UnoC function in survAUC for censoring-adjusted C-index
Hello, I am having some trouble with the 'censoring-adjusted C-index' by Uno et al, in the package survAUC. The relevant function is UnoC. The question has to do with what happens when I specify a time point t for the upper limit of the time range under consideration (we want to avoid using the right-end tail of the KM curve). Copying from the example in the help file: TR <-
2009 Mar 25
2
Competing risks Kalbfleisch & Prentice method
Dear R users I would like to calculate the Cumulative incidence for an event adjusting for competing risks and adjusting for covariates. One way to do this in R is to use the cmprsk package, function crr. This uses the Fine & Gray regression model. However, a simpler and more classical approach would be to implement the Kalbfleisch & Prentice method (1980, p 169), where one fits cause