similar to: Two documentation questions

Displaying 20 results from an estimated 8000 matches similar to: "Two documentation questions"

2009 Mar 05
1
documentation questions
You've answered my question 2 about why the manual was in odd order > R CMD check was more of a check of the latex version of the files, not > the final manual. I was looking at the result of R CMD check, and it was in random order (perhaps file date?), not just a different collation choice. Very odd. I will cease worrying about what I might have "done wrong". I omitted the
2007 May 16
2
log rank test p value
How can I get the Log - Rank p value to be output? The chi square value can be output, so I was thinking if I can also have the degrees of freedom output I could generate the p value, but can't see how to find df either. > (survtest <- survdiff(Surv(time, cens) ~ group, data = surv,rho=0)) Call: survdiff(formula = Surv(time, cens) ~ group, data = surv, rho = 0) N Observed
2012 Jan 26
2
extracting from data.frames for survival analysis
Hi, I have a data frame: > class(B27.vec) [1] "data.frame" > head(B27.vec) AGE Gend B27 AgeOn DD uveitis psoriasis IBD CD UC InI BASDAI BASFI Smok UV 1 57 1 1 19 38 2 1 1 1 1 1 5.40 8.08 NA 1 2 35 1 1 33 2 2 1 1 1 1 1 1.69 2.28 NA 1 3 49 2 1 40 9 1 1 1 1 1 1 8.30 9.40 NA
2012 Oct 19
1
Looping survdiff
The number of recent questions from umn.edu makes me wonder if there's homework involved.... Simpler for your example is to use get and subset. dat <- structure(..... as found below var.to.test <- names(dat)[4:6] #variables of interest nvar <- length(var.to.test) chisq <- double(nvar) for (i in 1:nvar) { tfit <- survdiff(Surv(time, completion==2) ~
2018 Mar 05
2
backquotes and term.labels
A user reported a problem with the survdiff function and the use of variables that contain a space.? Here is a simple example.? The same issue occurs in survfit for the same reason. lung2 <- lung names(lung2)[1] <- "in st"?? # old name is inst survdiff(Surv(time, status) ~ `in st`, data=lung2) Error in `[.data.frame`(m, ll) : undefined columns selected In the body of the code
2011 Nov 24
3
How to deal with package conflicts
In my genridge package, I define a function ridge() for ridge regression, creating objects of class 'ridge' that I intend to enhance. In a documentation example, I want to use some functions from the car package. However, that package requires survival, which also includes a ridge() function, for coxph models. So, once I require(car) my ridge() function is masked, which means I have to
2018 Mar 08
4
Fwd: Re: [EXTERNAL] Re: backquotes and term.labels
Ben, Looking at your notes, it appears that your solution is to write your own terms() function for lme.? It is easy to verify that the "varnames.fixed" attribute is not returned by the ususal terms function. Then I also need to write my own terms function for the survival and coxme pacakges? Because of the need to treat strata() terms in a special way I manipulate the formula/terms in
2010 Jul 07
1
Appropriateness of survdiff {survival} for non-censored data
I read through Harrington and Fleming (1982) but it is beyond my statistical comprehension. I have survival data for insects that have a very finite expiration date. I'm trying to test for differences in survival distributions between different groups. I understand that the medical field is most often dealing with censored data and that survival analysis, at least in the package survival,
2012 Oct 24
2
Kaplan Meier Post Hoc?
This is more of a general question without data. After doing 'survdiff', from the 'survival' package, on strata including four groups (so 4 curves on a Kaplan Meier curve) you get a chi squared p-value whether to reject the null hypothesis or not. Is there a method to followup with pairwise testing on the respective groups? I have searched the library but have come up with
2009 Aug 03
1
survdiff for left-truncated data?
Hi Does anyone know if there is a function like survdiff which can also handle left-truncated and right-censored data? When I use it on left-truncated and right-censored data I get an error message saying Right censored data only. Many thanks Rajen [[alternative HTML version deleted]]
2018 Mar 07
1
backquotes and term.labels
Thanks to Bill Dunlap for the clarification. On follow-up it turns out that this will be an issue for many if not most of the routines in the survival package: a lot of them look at the terms structure and make use of the dimnames of attr(terms, 'factors'), which also keeps the unneeded backquotes. Others use the term.labels attribute. To dodge this I will need to create a
2014 Nov 26
6
testing dontrun examples
Is there a good strategy for testing examples which should not be run by default? For instance, I have examples which get data from the Internet. If I wrap them in try() then they can be skipped if the Internet is not available, but may not be tested in cases when I would like to know about the failure. (Not to mention that the example syntax is ugly.) If I mark them \dontrun or \donttest
2013 Nov 20
4
How to stop Kaplan-Meier curve at a time point
Hello R users I have a question with Kaplan-Meier Curve with respect to my research. We have done a retrospective study on fillings in the tooth and their survival in relation to the many influencing factors. We had a long follow-up time (upto 8yrs for some variables). However, we decided to stop the analysis at the 6year follow up time, so that we can have uniform follow-up time for all the
2018 Mar 08
1
Fwd: Re: [EXTERNAL] Re: backquotes and term.labels
>>>>> Ben Bolker <bbolker at gmail.com> >>>>> on Thu, 8 Mar 2018 09:42:40 -0500 writes: > Meant to respond to this but forgot. > I didn't write a new terms() function -- I added an attribute to the > terms() (a vector of the names > of the constructed model matrix), thus preserving the information at > the point when
2006 Apr 18
2
Wishlist for promptPackage / index
Hi R-devels, would it be possible to enhance either promptPackage() or the default indexing mechanism for packages so that -- if it exists -- (the contents of) file <pkgname>-package.Rd is sorted first in * the .dvi / .pdf documentation file * the .chm documentation file * the package 00index.html documentation file ? So far I found the following "hand-made" solution
2004 Jun 15
2
To run or not to run examples, CTFS package
Hi again; I have placed many examples in the CTFS Rd pages because my audience really really likes lots of examples in order to understand the options available in a functions. At this time I have set them all to \dontrun{}. however, this isn't because the example command line with its function and options won't work, but rather that CTFS specific datasets must exist to have the
2008 Feb 18
4
Compare mean survival time
Dear List, Does anybody no how to compare mean survival times for two (more) groups in R? What test statistics should I use? Thank you very much! Joe [[alternative HTML version deleted]]
2010 Apr 12
2
source(,echo=T) doesn't echo final comments
Hi, source(file,echo=T) will not echo the last comment in "file" if it is the last line in the file. For instance, when sourcing a file containing the following lines #comment 1 a<-1 #comment 2 R will echo > #comment 1 > a<-1 What is the solution to have R echo all of the comment lines? Specific context: This problem arises e.g. in the context of help files (.Rd) whose
2008 Dec 04
1
Comparing survival curves with "survdiff" "strata" help
ExpeRts, I'm trying to compare three survival curves using the function "survdiff" in the survival package. Following is my code and corresponding error message. > survdiff(Surv(st_months, status) ~ strata(BOR), data=mydata) Error in survdiff(Surv(st_months, status) ~ strata(BOR), data = mydata) : No groups to test When I check the "strata" of the variable. I get .
2012 Oct 19
2
Question about survdiff in for-loop.
Hi everyone!! I have dataset composed of a numbers of survival analyses. ( for batch survival analyses by using for-loop) . Here are code !! ####### dim(svsv) Num_t<-dim(svsv) Num<-Num_t[2] # These are predictors !! names=colnames(svsv) for (i in 1:Num ) { name_tt=names[i] survdiff(Surv(survival.m, survival) ~ names[i], data=svsv) fit.Group<-survfit(Surv(survival.m, survival) ~