Re: [R] POTENTIAL PHISHING E-MAIL: Codes of Fourier Transformation

2021-09-22 Thread Stephen Ellison
> I wanted to know the codes of Fourier Transformation of time series > data. The location of complete source code for all versions of R is given at https://cran.r-project.org/sources.html fft is in the stats package and is implemented as a call to C code, so you'll need to look in the C source

Re: [R] calculating area of ellipse

2021-05-11 Thread Stephen Ellison
> In doing meta-analysis of diagnostic accuracy I produce ellipses of confidence > and prediction intervals in two dimensions. How can I calculate the area of > the ellipse in ggplot2 or base R? There are established formulae for ellipse area, but I am curious: in a 2-d ellipse with different

Re: [R] Error Running Bootstrap Function within Wrapper Function

2021-01-06 Thread Stephen Ellison
Kevin, I didn't have the data set (you might want to post a link to a downloadable file instead), but on a quick look at the code your foo1 function looks as if it is not guaranteed to return an array of the same length each time. It's testing for nonzero coefs in a fitted model and then

Re: [R] Inappropriate color name

2020-11-16 Thread Stephen Ellison
> Whether or not you agree with my reason for doing so, my question was > how to contact the creator of the "colors" function. If you do not have advice > on this, please refrain from weighing in. ... which is precisely what Prof Gunter said. However, it is worth consulting the documentation

Re: [R] Inquiry for R software Licensing.

2020-07-11 Thread Stephen Ellison
> Patrick (Malone Quantitative) > There's only one version and it's free. You're forgetting Microsoft R, formerly Revolution R (https://mran.revolutionanalytics.com/download), which comes in open and enterprise flavours, both with multithreading and the latter with beefed up database access

Re: [R] argument "x" is missing in minpack.lm

2020-06-30 Thread Stephen Ellison
Ivan Krylov [krylov.r...@gmail.com] said: > Instead you can either close over X: > > X <- c(...) > holly <- function(p) (p$a * X^2) / (p:b^2 + X^2) > # function holly now "contains" the vector X That would not be an accurate statement as written. The function only contains an unevaluated call

Re: [R] version plot problem

2020-06-24 Thread Stephen Ellison
You have four character vectors in your data frame; those return non-finite ranges. plot(test[sapply(test, class)!="character"]) plots the non-character columns. S Ellison From: R-help [r-help-boun...@r-project.org] on behalf of Rasmus Liland

Re: [R] Obtaining p values from t-test run with a by function

2020-06-12 Thread Stephen Ellison
Define a wrapper function for the t test that only returns the p-value? by(mydata$WtBaseline,mydata$Group, function(...) t.test(...)$p.value) S Ellison From: R-help [r-help-boun...@r-project.org] on behalf of Sorkin, John [jsor...@som.umaryland.edu]

Re: [R] almost logistic data evaluation

2020-06-10 Thread Stephen Ellison
...@precheza.cz] Sent: 10 June 2020 07:59 To: Stephen Ellison; r-help@r-project.org Subject: RE: [R] almost logistic data evaluation Hi External heating. Normally I would use TA instrumentation but for technical reasons it is impossible. And other complicating factor is that temperature rise

Re: [R] almost logistic data evaluation

2020-06-09 Thread Stephen Ellison
> Actually „y“ is growing temperature, which, at some point, rise more rapidly > due to exothermic reaction. > This reaction starts and ends and proceed with some speed (hopefully > different in each material). Are you applying external heating or is it solely due to reaction kinetics?

Re: [R] Creating a histogram from a frequency vector - correction!

2019-10-09 Thread Stephen Ellison
lass="histogram") } plot(freqhist(freqs, breaks=c(4*0:5, 10*3:5, 70, 100, 140)) ) #Also works equidistant with default 0:length(counts) breaks: f2 <- c(30, 39, 31, 29, 10, 6, 3, 1, 0, 1) plot(freqhist(f2)) Steve E > -Original Message- > From: Stephen Ellison > Se

Re: [R] Creating a histogram from a frequency vector

2019-10-09 Thread Stephen Ellison
> I have a vector like say 73,53,42,67,41,50 where these numbers are the > number of occurrences of the data values 1,2,3,4,5,6 - so in essence I have > the frequency bit from the hist() function. I can't see an elegant way (there > are clearly messy workarounds like generating a vector of 73

Re: [R] [SPAM] Re: The "--slave" option

2019-09-20 Thread Stephen Ellison
> Sure, it's a silly example, but it makes about as much sense as using > "slave" to mean "quiet". It doesn't. It's a set of options chosen for when R is called as a slave process from a controlling process, and in that it is a reasonable description of the circumstance. --quiet is a separate

Re: [R] How to use breaks argument in hist() function correctly?

2019-09-18 Thread Stephen Ellison
> When I had breaks = 18, I get total number of cells as 16, which is > same when I put breaks = 20 > > In the 2nd case I was expecting total number of cells (i.e. bars) as > 20 i.e. if I understand the documentation correctly I should expect > total number of cells (bars) should be same as breaks

Re: [R] Durbin- Levinson algorithm

2019-09-04 Thread Stephen Ellison
Google "levionson-Durbin in R The first reference is the levinson function in the signal package. > -Original Message- > From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of Faheem > Jan via R-help > Sent: 04 September 2019 11:29 > To: R-help Mailing List > Subject: [R]

Re: [R] Trying to understand how to sort a DF on two columns

2019-08-14 Thread Stephen Ellison
> I want to sort a DF, temp, on two columns, patid and time. I have searched > the internet and found code that I was able to modify to get my data sorted. > Unfortunately I don't understand how the code works. I would appreciate it > if someone could explain to me how the code works. Among other

Re: [R] need help in if else condition

2019-07-16 Thread Stephen Ellison
> However, having installed "Action of the Toes" (are R releases named > by Culture AIs, by any chance?) Peanuts cartoons. https://twitter.com/snoopy/status/269963551135891456 Steve E *** This email and any attachments are

Re: [R] Using options(max.print = 1000000) to read in data

2019-07-08 Thread Stephen Ellison
> This corresponds with the info found in my global environment for the > object indicated. Now, how do I go about determining if the dataset is a > matrix? Consider ?is.matrix ? S Ellison *** This email and any attachments are

Re: [R] Sample size required to estimate population variance

2019-07-05 Thread Stephen Ellison
> Thanks for the suggestion but I'm not sure that it answers my original > question.I need to know how many samples I need to collect to collect in > order to estimate the sample size needed to achieve a specific margin of > error for confidence intervals for the population variance. I'm not sure

Re: [R] Post Hoc for Homogeneity of variance

2019-06-04 Thread Stephen Ellison
> Thomas Subia Could you please explain the difference between: > any differences in variance between factors. and > variance differences between factors ? *** This email and any attachments are confidential. Any

Re: [R] Tying to underdressed the magic of lm redux

2019-06-03 Thread Stephen Ellison
If you want to pass a data frame (not just its name) plus (some) column names to your function, the easiest way is to put the _quoted_ names in a vector, as previously posted. For example f1 <- function(dfrm, colnames) { print(dfrm[,colnames]) #or, if you like, for(nn in colnames)

Re: [R] Pairwise testing with pairwise.prop.test

2019-04-01 Thread Stephen Ellison
> > 3) Is there a way to assign the numbers to the treatment group that they > were > > originally in? For example, "1" in the result should be "3", indicating that > > that was the temperature the experiment took place at. Pairwise.prop.test > > doesn't seem to accept matrices with more than 2

Re: [R] Kernel Density Estimation at manually specified points

2011-06-28 Thread Stephen Ellison
May be a kludge, but it might be simpler to write your own density function for a few specified points. For example my.density - function(x, bw = 'nrd0', at) { x-na.omit(x) # #Borrowed from density.default for compatibility if (is.character(bw)) { if

Re: [R] Confidence interval from resampling

2011-06-23 Thread Stephen Ellison
Depending on how critical the problem is, you might also want to look at the literature on bootstrap CI's, perhaps starting from the references in boot.ci in the boot package. The simple quantiles are not necessarily the most appropriate. For example I seem to recall that BCa intervals were the

Re: [R] reading the results of a within subject test

2011-06-23 Thread Stephen Ellison
From: r-help-boun...@r-project.org [r-help-boun...@r-project.org] On Behalf Of Ann [trivialesc...@gmail.com] Subject: [R] reading the results of a within subject test Hi, I ran the following in R (on item means): aov(VAR ~(a*b)+Error(item/(a*b)), data = item) I'm confused... Could

Re: [R] setting breaks in hist

2011-06-21 Thread Stephen Ellison
Not according to the help page. Bit kludgy,but try something like y - rnorm(73, 17.2) nbreaks - function(x, n) { r - range(pretty(y)) seq(r[1], r[2], length.out=n+1) } hist(y, breaks=nbreaks(y,13)) -Original Message- From: r-help-boun...@r-project.org

[R] Possible amendment to 'Writing R extensions' [was 'Porting unmaintained packages to post R 2.10.0 era']

2011-06-20 Thread Stephen Ellison
Dear Uwe, If you think the relevant section is not sufficient, it's your turn to provide a short and precise suggestion for a change, preferable a diff against the R-devel sources. That way you may be able to convince an R Core member to work on it. I would be more than happy to rearrange

Re: [R] Porting unmaintained packages to post R 2.10.0 era

2011-06-17 Thread Stephen Ellison
-Original Message- From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On Behalf Of Uwe Ligges Sent: 17 June 2011 12:04 See the manual. It tells you R CMD INSTALL --build will generate a binary package. ... it seems I am not the only one to make

Re: [R] Porting unmaintained packages to post R 2.10.0 era

2011-06-17 Thread Stephen Ellison
-Original Message- You can install to any library, even a temporary one that does not need to be in .libPaths() of your regular R installation. So you won't do any harm to your sytsem. The principal point I was making is that the manuals are not very informative on the

Re: [R] based on mean and std

2011-06-02 Thread Stephen Ellison
You can plot explicitly over a range of x; for example x-seq(10, 15, 0.1) #for mean 12.5, sd 0.6 plot(x, pnorm(x, 12.5, 0.6), type=l, ylim=c(0,1) Or you can try the default plot for a univariate function (see ?curve) plot(function(x) pnorm(x, 12.5, 0.6), xlim=c(10,15)) #Note use of the