search for: ycding

Displaying 20 results from an estimated 35 matches for "ycding".

2018 Jan 15
1
consolidate three function into one
...riting R function and need to find a good guide source about writing R functions. If you know a good book or website for guidance of R function, please let me know. Thanks, Ding From: Bert Gunter [mailto:bgunter.4567 at gmail.com] Sent: Monday, January 15, 2018 10:11 AM To: Ding, Yuan Chun <ycding at coh.org> Cc: Richard M. Heiberger <rmh at temple.edu>; r-help at r-project.org Subject: Re: [R] 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 objec...
2018 Jan 15
0
consolidate three function into one
...ich you might find useful. Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Mon, Jan 15, 2018 at 9:57 AM, Ding, Yuan Chun <ycding at coh.org> wrote: > 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 ge...
2018 Jan 15
2
consolidate three function into one
...ee Cluster", legend.labs = legend.labs, lty=1, lwd=3) print(fig) } -----Original Message----- From: Richard M. Heiberger [mailto:rmh at temple.edu] Sent: Sunday, January 14, 2018 1:34 PM To: Ding, Yuan Chun <ycding at coh.org> Cc: Bert Gunter <bgunter.4567 at gmail.com>; r-help at r-project.org Subject: Re: [R] 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...
2018 Mar 05
0
data analysis for partial two-by-two factorial design
...ong and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Mon, Mar 5, 2018 at 2:03 PM, David Winsemius <dwinsemius at comcast.net<mailto:dwinsemius at comcast.net>> wrote: > On Mar 5, 2018, at 8:52 AM, Ding, Yuan Chun <ycding at coh.org<mailto: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...
2018 Mar 05
5
data analysis for partial two-by-two factorial design
...is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Mon, Mar 5, 2018 at 2:03 PM, David Winsemius <dwinsemius at comcast.net> wrote: > > > 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...
2018 Mar 05
2
data analysis for partial two-by-two factorial design
...ge.com> statistical site. Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Fri, Mar 2, 2018 at 10:34 AM, Ding, Yuan Chun <ycding at coh.org<mailto:ycding at coh.org>> wrote: 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...
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...
2018 Jan 14
2
consolidate three function into one
...egend = "bottom", legend.title = "Tree Cluster", legend.labs = legend.labs, lty=1, lwd=3) } From: Bert Gunter [mailto:bgunter.4567 at gmail.com] Sent: Sunday, January 14, 2018 9:50 AM To: Ding, Yuan Chun <ycding at coh.org> Subject: Re: [R] consolidate three function into one I have not looked at your code *at all*, so I am not sure what exactly you mean by "consolidate." Is this what you are after? f1 <- function(...) { code 1} f2 <- function(...) { code 2} f3 <- function(...) { co...
2018 Jan 14
0
consolidate three function into one
...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. > > 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,...
2018 Mar 02
0
data analysis for partial two-by-two factorial design
...hange.com statistical site. Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Fri, Mar 2, 2018 at 10:34 AM, Ding, Yuan Chun <ycding at coh.org> wrote: > 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...
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 Mar 05
2
data analysis for partial two-by-two factorial design
...ing things into it." > > -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) > > > > On Mon, Mar 5, 2018 at 2:03 PM, David Winsemius <dwinsemius at comcast.net> > wrote: > > > > > 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. > >...
2018 Mar 05
0
data analysis for partial two-by-two factorial design
...keep coming along and sticking things into it." > -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) > > On Mon, Mar 5, 2018 at 2:03 PM, David Winsemius <dwinsemius at comcast.net> wrote: > > > 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 c...
2018 Mar 05
0
data analysis for partial two-by-two factorial design
...sticking things into it." > > -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) > > > > On Mon, Mar 5, 2018 at 2:03 PM, David Winsemius <dwinsemius at comcast.net> wrote: > > > > > 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. > > >...
2018 May 11
3
add one variable to a data frame
...B C1 C2 1 1 29_log 1 1 2 2 29_log 1 1 3 3 29_log 1 1 4 4 27_cat 2 2 5 5 27_cat 2 2 6 6 1_log 3 3 7 7 1_log 3 3 8 8 1_log 3 3 9 9 1_log 3 3 10 10 1_log 3 3 11 11 3_cat 4 4 12 12 3_cat 4 4 Sarah On Fri, May 11, 2018 at 1:52 PM, Ding, Yuan Chun <ycding at coh.org> wrote: > Hi All, > > I have a data frame dat1: > dat1 <-data.frame(N=seq(1, 12,1), B=c("29_log","29_log", "29_log", "27_cat", "27_cat", > "1...
2018 Jan 14
0
consolidate three function into one
...ts, adding flexibility to accommodate the number of clusters or the number of Kaplan Meier curves generated in one figure. So, I just need to define one function. Thanks, Ding From: Bert Gunter [mailto:bgunter.4567 at gmail.com] Sent: Sunday, January 14, 2018 9:50 AM To: Ding, Yuan Chun <ycding at coh.org> Subject: Re: [R] consolidate three function into one I have not looked at your code *at all*, so I am not sure what exactly you mean by "consolidate." Is this what you are after? f1 <- function(...) { code 1} f2 <- function(...) { code 2} f3 <- function(...) { co...
2018 May 11
0
add one variable to a data frame
...)))[ match( dat1$B, unique(dat1$B) )] -Don -- Don MacQueen Lawrence Livermore National Laboratory 7000 East Ave., L-627 Livermore, CA 94550 925-423-1062 Lab cell 925-724-7509 ?On 5/11/18, 12:04 PM, "R-help on behalf of Ding, Yuan Chun" <r-help-bounces at r-project.org on behalf of ycding at coh.org> wrote: 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 Subje...
2018 Apr 20
1
create multiple categorical variables in a data frame using a loop
> On Apr 19, 2018, at 1:22 PM, David Winsemius <dwinsemius at comcast.net> wrote: > > >> On Apr 19, 2018, at 11:20 AM, Ding, Yuan Chun <ycding at coh.org> wrote: >> >> Hi All, >> >> I want to create a categorical variable, cat.pfoa, in the file of pfas.pheno (a data frame) based on log2pfoa values. I can do it using the following code. >> >> pfas.pheno <-within(pfas.pheno, {cat.pfoa<-NA >...
2018 May 11
0
add one variable to a data frame
...B C1 C2 1 1 29_log 1 1 2 2 29_log 1 1 3 3 29_log 1 1 4 4 27_cat 2 2 5 5 27_cat 2 2 6 6 1_log 3 3 7 7 1_log 3 3 8 8 1_log 3 3 9 9 1_log 3 3 10 10 1_log 3 3 11 11 3_cat 4 4 12 12 3_cat 4 4 Sarah On Fri, May 11, 2018 at 1:52 PM, Ding, Yuan Chun <ycding at coh.org> wrote: > Hi All, > > I have a data frame dat1: > dat1 <-data.frame(N=seq(1, 12,1), B=c("29_log","29_log", "29_log", "27_cat", "27_cat", > "1...
2018 May 11
3
add one variable to a data frame
Hi All, I have a data frame dat1: dat1 <-data.frame(N=seq(1, 12,1), B=c("29_log","29_log", "29_log", "27_cat", "27_cat", "1_log", "1_log", "1_log", "1_log", "1_log",