similar to: Error: could not find function

Displaying 20 results from an estimated 2000 matches similar to: "Error: could not find function"

2013 Sep 09
1
Hmisc binconf function value interpretation during narrow confidence intervals
Hello all, I've been using binconf (package Hmisc) at a range of alpha values and noticed that using the 'Wilson' method when alpha is larger (i.e. narrow CI), results in the upper value being smaller than the lower value. The 'exact' and 'asymptotic' methods give results in the realm I'd expect. But the help file suggests: "Following Agresti and Coull, the
2008 Feb 06
1
ci.pd() (Epi) and Newcombe method
Greetings! I suspect that there is an error in the code for the function ci.pd() in the Epi package. This function is for computing confidence intervals for a difference of proportions between two independent groups of 0/1 responses, and implements the Newcombe ("Nc") method and the Agrasti-Caffo "AC" method. I think there is an error in the computation for the Newcombe
2004 Jul 12
6
proportions confidence intervals
Dear R users this may be a simple question - but i would appreciate any thoughts does anyone know how you would get one lower and one upper confidence interval for a set of data that consists of proportions. i.e. taking a usual confidence interval for normal data would result in the lower confidence interval being negative - which is not possible given the data (which is constrained between
2004 Aug 06
3
Bug in qnorm or pnorm?
I found the following strange behavior using qnorm() and pnorm(): > x<-8.21;x-qnorm(pnorm(x)) [1] 0.0004638484 > x<-8.22;x-qnorm(pnorm(x)) [1] 0.01046385 > x<-8.23;x-qnorm(pnorm(x)) [1] 0.02046385 > x<-8.24;x-qnorm(pnorm(x)) [1] 0.03046385 > x<-8.25;x-qnorm(pnorm(x)) [1] 0.04046385 > x<-8.26;x-qnorm(pnorm(x)) [1] 0.05046385 > x<-8.27;x-qnorm(pnorm(x))
2011 Mar 29
2
normal distribution and floating point traps (?): unexpected behavior
dear all, here's a couple of questions that puzzled me in these last hours: ##### issue 1 qnorm(1-10e-100)!=qnorm(10e-100) qnorm(1-1e-10) == -qnorm(1e-10) # turns on to be FALSE. Ok I'm not a computer scientist but, # but I had a look at the R inferno so I write: all.equal(qnorm(1-1e-10) , -qnorm(1e-10)) # which turns TRUE, as one would expect, but all.equal(qnorm(1-1e-100) ,
2017 Apr 16
1
Getting high precision values from qnorm in the tail
Hello All I am looking for high precision values for the normal distribution in the tail,(1e-10 and 1 - 1e-10) as the R package that I am using sets any number which is out of this range to these values and then calls the qnorm and qt function. What I have noticed is that the qnorm implementation in R is not symmetric when looking at the tails. This is quite surprising to me, as it is well known
2010 Oct 21
1
gam plots and seWithMean
hello I'm learning mgcv and would like to obtain numerical output corresponding to plot.gam. I can do so when seWithMean=FALSE (the default) but only approximately when seWithMean=TRUE. Can anyone show how to obtain the exact values? Alternatively, can you clarify the explanation in the manual "Note that, if seWithMean=TRUE, the confidence bands include the uncertainty about the
2012 Jun 18
3
(1-1e-100)==1 true?
Hi, This problems has bothered me for the lase couple of hours. > 1e-100==0 [1] FALSE > (1-1e-100)==1 [1] TRUE How can I tell R that 1-1e-100 does not equal to 1, actually, I found out that > (1-1e-16)==1 [1] FALSE > (1-1e-17)==1 [1] TRUE The reason I care about this is that I was try to use qnorm() in my code, for example, > qnorm(1e-100) [1] -21.27345 and if I want to
2012 Oct 17
1
how R implement qnorm()
how R implement qnorm() I wonder anyone knows the mathematical process that R calculated the quantile? The reason I asked is soly by curiosity. I know the probability of a normal distribution is calculated through integrate the Gaussian function, which can be implemented easily (see code), while the calculation of quantile (or Zα) in R is a bit confusing as it requires inverse error function (X
2001 Jul 02
2
Shapiro-Wilk test
Hi, does the shapiro wilk test in R-1.3.0 work correctly? Maybe it does, but can anybody tell me why the following sample doesn't give "W = 1" and "p-value = 1": R> x<-1:9/10;x [1] 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 R> shapiro.test(qnorm(x)) Shapiro-Wilk normality test data: qnorm(x) W = 0.9925, p-value = 0.9986 I can't imagine a sample being
2007 Mar 29
1
ansari.test.default: bug in call to uniroot?
A recent message on ansari.test() prompted me to play with the examples. This doesn't work for me in R version 2.4.1 R> ansari.test(rnorm(100), rnorm(100, 0, 2), conf.int = TRUE) Error in uniroot(ab, srange, tol = 1e-04, zq = qnorm(alpha/2, lower = FALSE)) : object "ab" not found It looks like there's a small typo in ccia() inside ansari.test.default() in which
2011 May 30
1
Error in minimizing an integrand using optim
Hi, Am not sure if my code itself is correct. Here's what am trying to do: Minimize integration of a function of gaussian distributed variable 'x' over the interval qnorm(0.999) to Inf by changing value of parameter 'mu'. mu is the shift in mean of 'x'. Code: # x follows gaussian distribution # fx2 to be minimized by changing values of mu # integration to be done over
2007 Jun 25
3
How to shadow 'power' area?
Dear all, Suppose I plot two normal distributions (A and B) side by side and add vertical line which hipotheticaly represent alpha value; e.g.: x <- seq(-3.5,5, length=1000) y <- dnorm(x) # Plot distribution A plot(y~x, type='l',axes=F,xlab="",ylab="",lwd=2) # Plot distribution B y2 <- dnorm(x-1.5) lines(y2~x,lwd=2) # Plot vertical line for alpha value
2001 Apr 05
1
PR#896
Sorry to all that are angry about the form of my previous mail. I didn't realise what would happen :((. Here it is in (hopefully) plain text (if my mailer doesn't spoil it again): ############## Dear developers, I have a problem with some discrepancy between R 1.2.1 for Windows and R 1.2.2 (and less) for Linux. While trying to correct the wilcox.test (see my previous bug report) I
2005 Oct 27
1
Puzzled over curve() syntax.
It's probably toadally elementary (and, like, duhhhhh) but I can't figure out why the following doesn't work: curve(function(x){qnorm(x,4,25)},from=0,to=1) I get the error: Error in xy.coords(x, y, xlabel, ylabel, log) : 'x' and 'y' lengths differ But if I do foo <- function(x){qnorm(x,4,25)} curve(foo,from=0,to=1) it goes like a train. Also
2000 Dec 11
1
qqline (PR#764)
I think qqline does not do exactly what it is advertised to do ("`qqline' adds a line to a normal quantile-quantile plot which passes through the first and third quartiles."). Consider the graph: tmp <- qnorm(ppoints(10)) qqnorm(tmp) qqline(tmp) The line (which I expected go through all the points), has a slightly shallower slope than does the points plotted by qqnorm. I think
2006 Oct 23
2
getting the by() function to work properly
Hola everyone, Solving this issue would be a huge time saver for analyzing my thesis data, so I'll try to be as concise as possible and hope that someone can give me a hand. I am trying to run a function that I created, which works fine until I try to use it with the by function. That function is listed at the bottom (f3) just in case that might be the issue. Essentially I have compiled a
2019 Jun 21
4
Calculation of e^{z^2/2} for a normal deviate z
You may want to look into using the log option to qnorm e.g., in round figures: > log(1e-300) [1] -690.7755 > qnorm(-691, log=TRUE) [1] -37.05315 > exp(37^2/2) [1] 1.881797e+297 > exp(-37^2/2) [1] 5.314068e-298 Notice that floating point representation cuts out at 1e+/-308 or so. If you want to go outside that range, you may need explicit manipulation of the log values. qnorm()
2010 Oct 03
2
sampling from normal distribution
Hello If i want to resampl from the tails of normal distribution , are these commans equivelant??   upper tail:qnorm(runif(n,pnorm(b),1))  if b is an upper tail boundary   or   upper tail:qnorm((1-p)+p(runif(n))  if p is the probability of each interval (the observatins are divided to intervals)   Regards [[alternative HTML version deleted]]
2019 Jun 23
2
Calculation of e^{z^2/2} for a normal deviate z
I agree with many the sentiments about the wisdom of computing very small p-values (although the example below may win some kind of a prize: I've seen people talking about p-values of the order of 10^(-2000), but never 10^(-(10^8)) !). That said, there are a several tricks for getting more reasonable sums of very small probabilities. The first is to scale the p-values by dividing the