KLdist.matrix
1
0
Entering edit mode
Ladan Amini ▴ 10
@ladan-amini-4733
Last seen 9.6 years ago
Hello, I am using KLdist.matrix from bioDist package, and the KL distance between two time series is slightly different for different runs. Example: n.th=rnorm(10^6,mean=0,sd=sqrt(0.1)) n.exp=rnorm(10^6,mean=0,sd=sqrt(0.5)) x <- rbindn.th,n.exp) #run no.1 KLdist.matrix(x, symmetrize = TRUE) #result: # n.th #n.exp 1.228867 #run no.2 KLdist.matrix(x, symmetrize = TRUE) #result: # n.th #n.exp 1.142033 #run no.3 KLdist.matrix(x, symmetrize = TRUE) #result: # n.th #n.exp 1.162144 I tried to fix the value of gridsizenumber, but it gives the following error: KLdist.matrix(x, symmetrize = TRUE,gridsizenumber=10) Erreur dans .local(x, ...) : argument(s) inutilisé(s) (gridsizenumber = 10) ERROR I would appreciate a lot if anyone can help me to solve this problem. Thank! Ladan [[alternative HTML version deleted]]
bioDist bioDist • 873 views
ADD COMMENT
0
Entering edit mode
@wolfgang-huber-3550
Last seen 3 months ago
EMBL European Molecular Biology Laborat…
Dear Ladan you can see the source code of this function by typing showMethods("KLdist.matrix", inc=T) and there you will see the code fragment for (i in 1:nr) { if (nc > 10000) dat <- sample(x[i, ], nc * 0.1) .... } i.e. the data are randomly subsampled if nc, the number of columns of the matrix, is above 10000. It would have been reasonable to expect that this behaviour would be documented in the function's manual page. Numeric integration is a difficult task, and I would consider this function a first, brave move into the right direction. Feedback on its performance on various applications will for sure be welcome, and if you take it as a start point for adaptation / further development to fulfill the needs of your use case, that might be the wisest way of making use of it. Best wishes Wolfgang Il Jul/1/11 12:27 PM, Ladan Amini ha scritto: > Hello, > > I am using KLdist.matrix from bioDist package, and the KL distance between > two time series is > slightly different for different runs. > > Example: > n.th=rnorm(10^6,mean=0,sd=sqrt(0.1)) > n.exp=rnorm(10^6,mean=0,sd=sqrt(0.5)) > x<- rbindn.th,n.exp) > #run no.1 > KLdist.matrix(x, symmetrize = TRUE) > #result: > # n.th > #n.exp 1.228867 > #run no.2 > KLdist.matrix(x, symmetrize = TRUE) > #result: > # n.th > #n.exp 1.142033 > #run no.3 > KLdist.matrix(x, symmetrize = TRUE) > #result: > # n.th > #n.exp 1.162144 > > I tried to fix the value of gridsizenumber, but it gives the following > error: > > KLdist.matrix(x, symmetrize = TRUE,gridsizenumber=10) > Erreur dans .local(x, ...) : argument(s) inutilis?(s) (gridsizenumber = 10) > ERROR > > I would appreciate a lot if anyone can help me to solve this problem. > > Thank! > Ladan > > [[alternative HTML version deleted]] > > > > > _______________________________________________ > Bioconductor mailing list > Bioconductor at r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor -- Wolfgang Huber EMBL http://www.embl.de/research/units/genome_biology/huber
ADD COMMENT

Login before adding your answer.

Traffic: 930 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6