Displaying 20 results from an estimated 10000 matches similar to: "running Cox regression model for 1000 markers"
2018 Mar 05
0
data analysis for partial two-by-two factorial design
Hi Bert and David,
Thank you so much for willingness to spend some time on my problem!!! I have some statistical knowledge (going to get a master in applied statisitics), but do not have a chance to purse a phD for statistics, so I am always be careful before starting to do analysis and hope to gather supportive information from real statisticians.
Sorry that I did not tell more info about
2018 Jan 15
1
consolidate three function into one
Thank you, your suggestion is simpler and logically better. I had impression that the last object in a function gets returned, so I did not add the print function at the bottom line of the function definition. Returning an object and graph the object are different process, I am a beginner for writing R function and need to find a good guide source about writing R functions. If you know a good
2024 Jun 12
1
my R code worked well when running the first 1000 lines of R code
Hi Rui,
Thank you very much!
Yes, I verified using real data, it worked correctly as expected after adding tidyr:: to the pivot_longer function and dplyr:: to the group_by and summarize
Function.
I did not know how to assign the tidyr and dplyr to the three functions because I do not really understand well the three functions and just got the code from a google search.
I also tried your
2018 Jan 15
0
consolidate three function into one
That is certainly OK, but you can also just use
print(ggsurvplot(...))
as your final statement.
out <- RFS( ...)
would then return the ggsurvplot object *and* graph it.
Any good R tutorial or a web search will provide more details on function
returns, which you might find useful.
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along and
2018 Mar 05
5
data analysis for partial two-by-two factorial design
David:
I believe your response on SO is incorrect. This is a standard OFAT (one
factor at a time) design, so that assuming additivity (no interactions),
the effects of drugA and drugB can be determined via the model you rejected:
For example, if baseline control (no drugs) has a response of 0, drugA has
an effect of 1, drugB has an effect of 2, and the effects are additive,
with no noise we
2018 Mar 05
0
data analysis for partial two-by-two factorial design
> On Mar 5, 2018, at 8:52 AM, Ding, Yuan Chun <ycding at coh.org> wrote:
>
> Hi Bert,
>
> I am very sorry to bother you again.
>
> For the following question, as you suggested, I posted it in both Biostars website and stackexchange website, so far no reply.
>
> I really hope that you can do me a great favor to share your points about how to explain the
2018 Mar 05
2
data analysis for partial two-by-two factorial design
Hi Bert,
I am very sorry to bother you again.
For the following question, as you suggested, I posted it in both Biostars website and stackexchange website, so far no reply.
I really hope that you can do me a great favor to share your points about how to explain the coefficients for drug A and drug B if run anova model (response variable = drug A + drug B). is it different from running three
2018 Jan 15
2
consolidate three function into one
Hi Richard,
Thank you so much!! I understand the problem now, I assign a name to the "ggsurvplot" object and then add print(fig) at bottom of function definition, now figure gets printed on screen.
Ding
# function to generate RFS curves
RFS <- function( inputfile, N ) {
cluster<- survfit(Surv(RFS_days2, OV_Had_a_Recurrence_CODE) ~ clusters,
data =
2024 Jun 12
1
my R code worked well when running the first 1000 lines of R code
Hello,
Inline.
?s 19:03 de 12/06/2024, Yuan Chun Ding via R-help escreveu:
> I am sorry that I know I should provide a dataset that allows to replicate my problem.
>
> It is a research dataset and quite large, so I can not share.
>
> Both Bert and Tim guessed my problem correctly. I also thought about the conflicting issue between different packages and function masking.
> I
2018 Mar 02
0
data analysis for partial two-by-two factorial design
This list provides help on R programming (see the posting guide linked
below for details on what is/is not considered on topic), and generally
avoids discussion of purely statistical issues, which is what your query
appears to be. The simple answer is yes, you can fit the model as
described, but you clearly need the off topic discussion as to what it
does or does not mean. For that, you might try
2018 Mar 05
0
data analysis for partial two-by-two factorial design
> On Mar 5, 2018, at 2:27 PM, Bert Gunter <bgunter.4567 at gmail.com> wrote:
>
> David:
>
> I believe your response on SO is incorrect. This is a standard OFAT (one factor at a time) design, so that assuming additivity (no interactions), the effects of drugA and drugB can be determined via the model you rejected:
>> three groups, no drugA/no drugB, yes drugA/no drugB,
2018 Mar 05
0
data analysis for partial two-by-two factorial design
> On Mar 5, 2018, at 3:04 PM, Bert Gunter <bgunter.4567 at gmail.com> wrote:
>
> But of course the whole point of additivity is to decompose the combined effect as the sum of individual effects.
Agreed. Furthermore your encoding of the treatment assignments has the advantage that the default treatment contrast for A+B will have a statistical estimate associated with it. That was a
2018 Mar 05
2
data analysis for partial two-by-two factorial design
But of course the whole point of additivity is to decompose the combined
effect as the sum of individual effects.
"Mislead" is a subjective judgment, so no comment. The explanation I
provided is standard. I used it for decades when I taught in industry.
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along and
sticking things into
2018 May 11
0
add one variable to a data frame
Sarah's solutions are good, and here's another, even more basic:
tmp1 <- unique(dat1$B)
tmp2 <- seq_along(tmp1)
dat1$C <- tmp2[ match( dat1$B, tmp1) ]
> dat1
N B C
1 1 29_log 1
2 2 29_log 1
3 3 29_log 1
4 4 27_cat 2
5 5 27_cat 2
6 6 1_log 3
7 7 1_log 3
8 8 1_log 3
9 9 1_log 3
10 10 1_log 3
11 11 3_cat 4
12 12 3_cat 4
As a single line
2018 Jan 14
0
consolidate three function into one
FAQ 7.22
You must print a ggplot object, for example with
print(m52.2cluster)
For the FAQ, run the line
system.file("../../doc/FAQ")
in R on your computer.
Open up the resulting filepath in your favorite editor and scroll down to 7.22
On Sun, Jan 14, 2018 at 4:21 PM, Ding, Yuan Chun <ycding at coh.org> wrote:
> Hi Bert,
>
> I am sorry to bother you on weekend.
>
2018 May 11
3
add one variable to a data frame
Hi Sarah,
Thank you so much!! I got your good ideas.
Ding
-----Original Message-----
From: Sarah Goslee [mailto:sarah.goslee at gmail.com]
Sent: Friday, May 11, 2018 11:40 AM
To: Ding, Yuan Chun
Cc: r-help mailing list
Subject: Re: [R] add one variable to a data frame
[Attention: This email came from an external source. Do not open attachments or click on links from unknown senders or
2024 Jul 25
1
please help generate a square correlation matrix
Hi Rui,
You are always very helpful!! Thank you,
I just modified your R codes to remove a row with zero values in both column pair as below for my real data.
Ding
dat<-gene22mut.coded
r <- P <- matrix(NA, nrow = 22L, ncol = 22L,
dimnames = list(names(dat), names(dat)))
for(i in 1:22) {
#i=1
x <- dat[[i]]
for(j in (1:22)) {
#j=2
if(i == j) {
#
2018 Mar 02
3
data analysis for partial two-by-two factorial design
Dear R users,
I need to analyze data generated from a partial two-by-two factorial design: two levels for drug A (yes, no), two levels for drug B (yes, no); however, data points are available only for three groups, no drugA/no drugB, yes drugA/no drugB, yes drugA/yes drug B, omitting the fourth group of no drugA/yes drugB. I think we can not investigate interaction between drug A and drug B,
2018 Jan 14
2
consolidate three function into one
Hi Bert,
I am sorry to bother you on weekend.
I am still struggling on defining a correct function.
I first defined the function RFS (see below), then run it by provide the two argument.
m52.2cluster <-RFS(inputfile =allinfo_m52, N=2 )
I do not get error message, but no figure displays on screen. I do not know what is going on.
Can you help me a little more on this issue?
Thank you,
2024 Jul 25
1
please help generate a square correlation matrix
?s 20:47 de 25/07/2024, Yuan Chun Ding escreveu:
> Hi Rui,
>
> You are always very helpful!! Thank you,
>
> I just modified your R codes to remove a row with zero values in both column pair as below for my real data.
>
> Ding
>
> dat<-gene22mut.coded
> r <- P <- matrix(NA, nrow = 22L, ncol = 22L,
> dimnames = list(names(dat),