[R] shaded area between a curve and a circle

2022-10-22 Thread L... L...
Dear, I have a picture in which I draw a circle over the standard normal curve. See below the lines used to draw the figure. The figure is ok, but my problem is: How to shade the areas A, B, C, D, E and F? I know I have to find the points of intersection but I don't know how to find them.

[R] concatenating text within a function

2016-10-01 Thread L... L...
Dear all, I have the following variables: fc <- quote(sqrt(2) * pi ^ (-0.1e1 / 0.2e1) * (x / theta) ^ alpha * alpha / x * exp(-(x / theta) ^ (2 * alpha) / 2)) and d2 <- D(D(fc, "alpha"), "alpha") I would like to create a function formed by the product of fc and d2. I tried: fcd2 <-

[R] quantile of a discrete random variable

2015-06-25 Thread L... L...
Dear all, is there a general method for calculating the quantile of a discrete random variable? If yes, is there a R function to do this? Best regards Marcelo Lamack [[alternative HTML version deleted]]

[R] quantile of a discrete random variabel --- again

2015-06-25 Thread L... L...
I thank all for your reply. My question was not well formulated. I will do it again: Suppose that the random variable X is discrete with probability mass function (pmf) F (binomial, poisson, ) not necessarily available in R. Is there a general method to get the quantiles (as qbinom, qpois,

[R] cure fraction model

2013-12-19 Thread L... L...
Dear all, is there an R function to simulate random observations from a cure fraction model (random observations with long-term survivos). Some references how can I do this will be welcome. Best Regards ML [[alternative HTML version deleted]]

[R] Linear Discriminant Analysis

2010-03-23 Thread L L
Hi, I was wondering if you can show me how to plot the discriminant boundary lines for an LD analysis in R. I am curious as to perform this on a larger scale, so I was wondering if you can provide me an example on the infamous 'iris' data. Here's what I have so far: iris.lda=lda(Species ~.,

Re: [R] class export in package creation / setClass / namespace?

2009-07-21 Thread L L
: MartinMo L L lmla...@gmail.com writes: Ok, I could solve also the latter problem by defining show.myclass function in the zzz.R file and adding the line 'S3method(show,myclass)' into NAMESPACE file. Now the package passes all checks. MartinMo I would have, in NAMESPACE

Re: [R] class export in package creation / setClass / namespace?

2009-07-20 Thread L L
'show'? I could not find suitable examples from the web/mailing lists. br Leo On Fri, Jul 10, 2009 at 5:37 AM, Martin Morgan mtmor...@fhcrc.org wrote: L L wrote: Dear all, I have been trying to create an R package. This has been successfull until I tried to define classes. Currently

Re: [R] class export in package creation / setClass / namespace?

2009-07-20 Thread L L
into a package is available but rather scattered in the web. A step-by-step tutorial written by an experienced user who is aware of best practices etc. would be rather useful for a beginner. best regards Leo On Mon, Jul 20, 2009 at 7:09 PM, L L lmla...@gmail.com wrote: Thanks, the issue was solved

[R] R package creation: 'show' extension not imported correctly

2009-07-20 Thread L L
Dear List, I have a problem related to R package creation. I extended the 'show' method to cover a new class with the following lines in the zzz.R file in the R directory while creating an R package. setClass(rpa, contains=list) show.rpa - function (...) {cat(rpa object \n)} The corresponding

[R] class export in package creation / setClass / namespace?

2009-07-09 Thread L L
Dear all, I have been trying to create an R package. This has been successfull until I tried to define classes. Currently, my procedure is the following: Start R, load the function and class definition tmp - function (x) {x} setClass(rpa, contains = list, where=topenv(parent.frame())) Use

[R] generate ROC curve using randomForest package

2007-09-15 Thread L L
Hi, I am new here. I would like to compare the performance of the random forest model with support vector machine. Can anybody let me know how to generate a ROC curve for random forest model since there is no need to run the cross-validation. Thank you very much! TL