Displaying 20 results from an estimated 110 matches for "qchisq".
Did you mean:
chisq
2004 Sep 06
1
qchisq (PR#7212)
Full_Name: David Clayton
Version: 1.8.1
OS: Linux
Submission from: (NULL) (131.111.126.242)
qchisq behaves very strangely when ncp is passed as zero (forcing internal
qnchisq to be called) when first argument is small.
Eg
> qchisq(1-1e-6, 1, ncp=0, lower.tail=TRUE)
qchisq(1-1e-6, 1, ncp=0, lower.tail=TRUE)
[1] 1024
while, if ncp is unspecified,
> qchisq(1-1e-6, 1)
qchisq(1-1e-6, 1)
[1...
2004 Jan 19
2
small bug on qchisq (PR#6442)
Full_Name: Drouilhet R?my
Version: 1.8.1
OS: Linux
Submission from: (NULL) (195.221.43.136)
qchisq(1,10) works well but qchisq(1,10,ncp=0) does not work whereas ncp=0 is
the default value of the function qchisq(1,10). (of course, 10 will be replaced
by any integer value).
Let us notice that this bug occurs only when applying probability one.
(qchisq(seq(0,.9,.1),10,ncp=0) works very well).
2009 Oct 11
2
Accuracy (PR#13999)
Full_Name: Viktor Witkovsky
Version: 2.9.2
OS: Windows XP
Submission from: (NULL) (78.98.89.227)
Hello,
I have found strange behavior of the function qchisq (the non-central qchisq is
based on inversion of pchisq, which is further based on pgamma). The function
gives wrong results without any warning. For example:
qchisq(1e-12,1,8.94^2,lower.tail=FALSE) gives 255.1840972465858 (notice that
here the correct value should be 255.1841334848075),
but
qchis...
2005 Aug 26
3
Matrix oriented computing
Hi,
I want to compute the quantiles of Chi^2 distributions with different
degrees of freedom like
x<-cbind(0.005, 0.010, 0.025, 0.05, 0.1, 0.5, 0.9, 0.95, 0.975, 0.99, 0.995)
df<-rbind(1:100)
m<-qchisq(x,df)
and hoped to get back a length(df) times length(x) matrix with the
quantiles. Since this does not work, I use
x<-c(0.005, 0.010, 0.025, 0.05, 0.1, 0.5, 0.9, 0.95, 0.975, 0.99, 0.995)
df<-c(1:100)
m<-qchisq(x,df[1])
for (i in 2:length(df)) {
m<-rbind(m,qchisq(x,df[i]))
}
di...
2010 Nov 12
1
what's wrong with this 'length' in function?
...#####
p26=function(x,alpha){
# dummy variable
j=1
ci=matrix(ncol=2,nrow=3)
while (j<4){
if (j==2) {x=x+c(-1,1)*0.5}
ci[j,]=
x+qnorm(1-alpha/2)^2/2+
c(-1,1)*qnorm(1-alpha/2)*
sqrt(x+qnorm(1-alpha/2)^2/4)
j=j+1
if (j==3) { # exact
x=x-c(-1,1)*0.5
ci[j,]=c(
qchisq(1-alpha/2,df=2*x)/2,
qchisq(alpha/2,df=2*x+2)/2)
j=j+1
}
}
rownames(ci)=c('without','with','exact')
colnames(ci)=c('lower','upper')
return(round(ci,2))
}
###################################################
Most bits are fine.
The problem part...
2003 Apr 13
2
Peculiarity in non-central qchisq for ncp > 294.92 ...
Hello all,
Here's my query:
Running R 1.6.2 on FreeBSD 5.0, and on WinXP, and I find that the
following hangs the process:
dchisq(alpha=0.01, df=1, ncp=295)
but it does work for ncp < 294.92.
Is this general?
Best wishes to all,
Andrew
Andrew Robinson Ph: 208 885 7115
Department of Forest Resources Fa: 208 885 6226
University of Idaho E : andrewr at uidaho.edu
PO
2007 Oct 10
5
chi2
Hello,
I want to use the quantile function so I read the doc but I don't understand with this
> qchisq(seq(0.05,0.95,by=0.05),df=(length(don)-1))
[1] 62667.11 62795.62 62882.42 62951.47 63010.74 63064.00 63113.39 63160.27 63205.65 63250.33 63295.04 63340.48 63387.48 63437.03 63490.53 63550.14 63619.68
[18] 63707.24 63837.16
Can you help me please?
__________________________________________...
2008 Nov 07
4
chi square table
Hi,
How do we get the value of a chi square as we usually look up on the
table on our text book?
i.e. Chi-square(0.01, df=8), the text book table gives 20.090
> dchisq(0.01, df=8)
[1] 1.036471e-08
> pchisq(0.01, df=8)
[1] 2.593772e-11
> qchisq(0.01, df=8)
[1] 1.646497
>
nono of them give me 20.090
Thanks,
cruz
2001 Mar 10
1
Bug in qchisq?
Hello developers and users:
My system fails (the computer freezes) when I use the ncp parameter,
with the lower.tail=FALSE option in the qchisq function.
qchisq(0.025,31,ncp=1,lower.tail=FALSE)
Thank you very much for your help.
Kenneth Cabrera
Universidad Nacional de Colombia
ICNE
Sede Medellin
krcabrer at perseus.unalmed.edu.co
PS
I am using:
$platform "i386-pc-mingw32"
$arch "x86"
$os "Win32"
$syst...
2001 Mar 10
0
Re: [R] Bug in qchisq? (PR#875)
Kenneth Cabrera <krcabrer@epm.net.co> writes:
> Hello developers and users:
>
> My system fails (the computer freezes) when I use the ncp parameter,
> with the lower.tail=FALSE option in the qchisq function.
>
> qchisq(0.025,31,ncp=1,lower.tail=FALSE)
Yup, that's a bug. We have in pnchisq.c
48 for (ux = 1.0; pnchisq(ux, n, lambda, lower_tail, log_p) <
p; ux *= 2);
49 for (lx = ux; pnchisq(lx, n, lambda, lower_tail, log_p) >
p; lx *= 0.5);
but if we look...
2001 Mar 13
0
Re: [R] Bug in qchisq? (PR#875)
...ard <p.dalgaard@biostat.ku.dk> writes:
PD> Kenneth Cabrera <krcabrer@epm.net.co> writes:
>> Hello developers and users:
>>
>> My system fails (the computer freezes) when I use the ncp parameter,
>> with the lower.tail=FALSE option in the qchisq function.
>>
>> qchisq(0.025,31,ncp=1,lower.tail=FALSE)
PD> Yup, that's a bug. We have in pnchisq.c
PD> 48 for (ux = 1.0; pnchisq(ux, n, lambda, lower_tail, log_p) < p;
PD> ux *= 2);
PD> 49 for (lx = ux; pnchisq(lx, n, lambda, lower_t...
2008 Jan 07
2
chi-squared with zero df (PR#10551)
Full_Name: Jerry W. Lewis
Version: 2.6.1
OS: Windows XP Professional
Submission from: (NULL) (24.147.191.250)
pchisq(0,0,ncp=lambda) returns 0 instead of exp(-lambda/2)
pchisq(x,0,ncp=lambda) returns NaN instead of exp(-lambda/2)*(1 +
SUM_{r=0}^infty ((lambda/2)^r / r!) pchisq(x, df + 2r))
qchisq(.7,0,ncp=1) returns 1.712252 instead of 0.701297103
qchisq(exp(-1/2),0,ncp=1) returns 1.238938 instead of 0
2005 Jan 21
2
chi-Squared distribution
Dear Rs:
outer(1:3, 1:3, function(df1, df2) qf(0.95, df1, df2))
I compare this F distribution results with the table, the answers were perfect. But I need to see for chi-sqaured distribution. When I employed the similar formula
outer(1:3, 1:3, function(df1, df2) qchisq(0.95, df1, df2)) , I am getting unexpected results. I need to see the following values:
p=0.750 .....
1 1.323
2 2.773
3 4.108
Thanking you
Prasanna
Prasanna Balaprakash,
Universit? Libre de Bruxelles,
50, Av. F. Roosevelt, CP 194/6,
B-1050 Brussels,
Belgium...
2007 Jun 14
0
Confidence interval for coefficient of variation
...sigma/mu
# CV > .33 may give poor results, so warn the user
if(k>.33) warning("Confidence interval may be very approximate.")
method <- casefold(method) # In case we see "McKay"
if(method=="mckay"){
# McKay method. See equation 15.
t1 <- qchisq(1-alpha/2,v)/v
t2 <- qchisq(alpha/2,v)/v
u1 <- v*t1
u2 <- v*t2
lower <- k/sqrt(( u1/(v+1) -1)*k*k + u1/v)
upper <- k/sqrt(( u2/(v+1) -1)*k*k + u2/v)
} else if (method=="naive"){
# Naive method. See equation 17.
t1 <- qchisq(1-alpha/2,v)/v...
2005 Jan 21
2
chi-Squared distribution in Friedman test
...poulos" <dimitris.rizopoulos at med.kuleuven.ac.be>
>To: "Prasanna Balaprakash" <pbalapra at ulb.ac.be>
>Cc: <r-help at stat.math.ethz.ch>
>Sent: Friday, January 21, 2005 1:05 PM
>Subject: Re: [R] chi-Squared distribution
>
>
>> if you check ?qchisq, you'll see that the second
>
>My mistake, the third argument
>
>> argument of the function denotes the non-centrality parameter! Try
>>
>> qchisq(0.75, 1:3)
>>
>> to get your answer.
>>
>> Best,
>> Dimitris
>>
>> ----
>>...
2008 Feb 06
1
ci.pd() (Epi) and Newcombe method
...hod.
I think there is an error in the computation for the
Newcombe method.
Specifically, where the code says
# Put the data in the right form
x1 <- aa; n1 <- aa+cc; p1 <- x1/n1
x2 <- bb; n2 <- bb+dd; p2 <- x2/n2
pd <- x1/n1 - x2/n2
z <- qnorm(1-alpha/2)
zz <- qchisq(1-alpha/2,1)
I believe zz (which is used in the Newcombe method,
while z is used for Agresti-Caffo) should be
zz <- qchisq(1-alpha,1)
(though I think they could just as well have written
xx <- z^2), since z^2 seems to be what they want for the
Newcombe method, and qnorm(1-alpha/2)^2 = qc...
2012 May 11
1
identify() doesn't return "true" numbers
...urn(identify(X))
invisisble(X)
}
qqplot.mv.interactive <- function (data, xlim=NULL, ylim=NULL)
{
x <- as.matrix(data) # n x p numeric matrix
center <- colMeans(x) # centroid
n <- nrow(x); p <- ncol(x); cov <- cov(x);
d <- mahalanobis(x,center,cov) # distances
qqInteractive(qchisq(ppoints(n),df=p),d, # ppoints(n) makes
a sequence from 0 to 1. with stepsize 1/n
main="QQ Plot Assessing Multivariate Normality", # qchisq() makes a
chi squared distribution function for the given probabilities in ppoints(n)
and degress of freedom df
ylab=...
2003 May 15
2
kolmogorov-smirnov
...e question: Can I find somewhere in R the
significance values for a Kolmogorov distribution (I know the degrees
of freedom and I have already the maximum deviation). ks.test is not
really doing what I want. All I need is the values, like one can get
the values for a chi-squared distribution by 'qchisq(0.05, 375)'.
tnx,
Kurt.
2004 Mar 10
1
accuracy of chi-square distribution approximations
Hi there,
How accurate is the aproximation R makes to the Chi-Square distribution?
For example, if I run:
> qchisq(1/1000000,6)
[1] 0.03650857
how accurate is 0.0365 compared to the theoretical percentile? What kind
of approximations have been made in the software's algorithm? It woudl be
useful to know since I am working with tiny percentiles such as one
one-millionth and one one-billionth, and I am not s...
2005 Jan 21
0
R: chi-Squared distribution
Hi,
Attention chi-squared distribution, unlike F
distribution, has only df1 as parameter, not df1 and
df2. So correct into:
outer(1:3, 1:3, function(df1, df2) qchisq(0.95, df1,
df2))
outer(1:3, 1:3, function(df1, df2) qchisq(0.95, df1))
^^^^^^^^^^^^^^^^^^^^
Regards,
Vito
you wrote:
Dear Rs:
outer(1:3, 1:3, function(df1, df2) qf(0.95, df1, df2))
I compare this F distribution results with the table,
the answers were perfect. But...