Skip to content
Prev 317951 / 398506 Next

Cramer von Mises test for a discrete distribution

On Wed, Feb 20, 2013 at 10:03 AM, Santiago Guallar <sguallar at yahoo.com> wrote:
That's good - often people say "crash" when all they have seen is a
"stop" from R.
Nicely up to date...
Oh don't do that! You're not asking how to do basic statistics, you
are trying to do it yourself and getting a crash. Fair question for
starters...
Will I, will I, will I....
*** caught segfault ***
address 0x5620e458, cause 'memory not mapped'

Traceback:
 1: .C("CvMTestStat", as.double(x), as.integer(length(x)),
as.double(y),     as.integer(length(y)), testscore = double(1))
 2: cvmts.test(prm, prpmr)

Possible actions:
1: abort (with core dump, if enabled)
2: normal R exit
3: exit R without saving workspace
4: exit R saving workspace
Selection:

Yes! This looks like a bug in that package function, a bit of
investigation seems to blame it on when you have repeated values in
the vectors:
[1] 0.025
[1] 0.955
*** caught segfault ***
address 0x514daba8, cause 'memory not mapped'

Traceback:
 1: .C("CvMTestStat", as.double(x), as.integer(length(x)),
as.double(y),     as.integer(length(y)), testscore = double(1))
 2: cvmts.test(rep(1, 10), rep(2, 10))

Possible actions:
1: abort (with core dump, if enabled)
2: normal R exit
3: exit R without saving workspace
4: exit R saving workspace

Functions shouldn't crash like this - so time for you to email the maintainer:
[1] "Yuanhui Xiao <yxiao at gsu.edu>"

The function disappears into C code, but I suspect its dividing by
zero somewhere...

Barry