Re: [R] ggplot inside of the function

2019-11-25 Thread Thevaraja, Mayooran
Great it works. Thank you so much Eric. Cheers, Mayooran -Original Message- From: Eric Berger Sent: Monday, 25 November 2019 11:22 PM To: Thevaraja, Mayooran Cc: r-help Subject: Re: [R] ggplot inside of the function Hi Mayooran, If you define the following function f <- functio

[R] ggplot inside of the function

2019-11-24 Thread Thevaraja, Mayooran
Hello Folks I am working some R package development. When I was using ggplot inside of the function, I need to get the output graph's legend must be corresponding to the input parameters numerical value (need to be automatically changed when we input different parameters).

[R] replace_missings

2019-10-17 Thread Thevaraja, Mayooran
Hello You can use the following function, ## replace_missings <- function(x, replacement) { is_missings <- is.na(x) x[is_missings] <- replacement message(sum(is_missings), " missings replaced by the given value ",

Re: [R] NA value in list of data frame

2019-10-17 Thread Thevaraja, Mayooran
Hello You can use the following function, ## replace_missings <- function(x, replacement) { is_missings <- is.na(x) x[is_missings] <- replacement message(sum(is_missings), " missings replaced by the given value ", replacement) x }

Re: [R] read

2019-08-08 Thread Thevaraja, Mayooran
Hi you can save your data file in txt or csv file. Then you can use function " vld <-read.table("C:/Users/ .txt",header=T)". Regards Mayooran -Original Message- From: R-help On Behalf Of Val Sent: Friday, 9 August 2019 12:11 PM To: r-help@R-project.org (r-help@r-project.org)

Re: [R] need help in if else condition

2019-07-16 Thread Thevaraja, Mayooran
Hello Everyone I am trying to draw the smooth curve for my simulation and theoretical result. Anyone has any suggestion to me. Code given below. library(ggplot2) p <- c(0.0005,0.0025,0.0050,0.0075,0.0100,0.0200) p_ sim1 <- c(0.3030,0.8245,0.9730,0.9955,1.,1.) p_

Re: [R] How to extract data based on first column ID in R

2019-06-23 Thread Thevaraja, Mayooran
Hello Check out following link: https://dzone.com/articles/learn-r-how-extract-rows https://stat.ethz.ch/R-manual/R-devel/library/base/html/Extract.data.frame.html Cheers Mayooran Sent from Mail for Windows 10 From:

Re: [R] Only change one parameter(n times) in R function then get outputs (n times)

2019-06-10 Thread Thevaraja, Mayooran
>; Bert Gunter<mailto:bgunter.4...@gmail.com>; Thevaraja, Mayooran<mailto:m.thevar...@massey.ac.nz> Cc: r-help@r-project.org<mailto:r-help@r-project.org> Subject: Re: [R] Only change one parameter(n times) in R function then get outputs (n times) Sorry ... that should have been "s

[R] Only change one parameter(n times) in R function then get outputs (n times)

2019-06-09 Thread Thevaraja, Mayooran
Hello Friends, I have my own written an R function comparison (p,d,N). I need to get output corresponding changes in p while d and N are fixed. Also, my output is given three values such as A, B and C. Suppose if I change ten different p's values, we will get ten values of

Re: [R] Automatically simulates random numbers (not general) in R?

2019-06-06 Thread Thevaraja, Mayooran
lt;- sort(sample(start[i-1]+1,1)) } } start } start(15) -Original Message- From: Boris Steipe Sent: Friday, 7 June 2019 12:34 PM To: Thevaraja, Mayooran Subject: Re: [R] Automatically simulates random numbers (not general) in R? You did not initialize the variable "start

[R] Automatically simulates random numbers (not general) in R?

2019-06-06 Thread Thevaraja, Mayooran
Hello Guys! I am wondering about below function which automatically simulates random numbers - given below that manual calculation too. Anyone help me to fix that error. I got that error "object of type 'closure' is not subsettable" So Do you have any ideas? Regards Mayooran

[R] How to generate mutiple set of samples in R?

2019-06-05 Thread Thevaraja, Mayooran
Hello I am trying to generate samples from a bulk set of number for my research. So I need to get an output which contains various collection of samples, for example, sample1, sample2, sample3, Does anyone suggest any ideas? [[alternative HTML version deleted]]