-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Function “fast.cophenetic.phylo” failed #6
Comments
Dear Hongyi, I haven't tried running the script with such a high OTU size cutoff previously; I assume that this way, you probably remove so many OTUs that some samples end up with (almost) no taxa. I am currently out of office, but will be back tomorrow and give this a try. I'll post an update here :-) Best, Sebastian |
Dear Sebastian First, I replace "my.root" with "1" in the script “my.node_paths <- mclapply(seq(1, Ntip(x)), function (tip) {nodepath(x, from=tip, to=my.root)}, mc.cores=use.cores);” in functions.community_similarity.R as I have mentioned before. "my.root" is not defined. Second, since my sequence number is very large, I have to set the "size.thresh <-10" when doing Sparcc (to avoid consuming excessive amount of memory or time). However, if you look at the script below: At last, I found the numbers in the matrix of PINA (both weighted and unweighted) are all very small (1e-3~1e-5), is that right? I found PINA was also small in your ISME paper, but larger than mine. Should I use higher "size.thresh" since the otu table of soil samples seems to be sparser than hmp otu table? Best, Hongyi |
Oh, I forgot to say that "my.tree" should also be filtered for PINA: |
Dear Hongyi, thanks for the update and the comments, and sorry for not coming back to you about this before...
I'm aware of the issue, but I'm not sure if your fix is the correct one. The original problem of
I am aware of this problem; I had out-commented the size filtering within the SparCC code for various reasons. Again, I hope to get around to properly re-write the code, and removing such inconsistencies is a big part of that. In the meantime, sorry for the inconvenience!
Yes, the memory management is the other big problem of the current implementation. I have spent quite some time trying to figure this out, and I believe the problem is at the level of
I have also encountered low PINA values in various contexts. One possible reason is the rooting bug mentioned above when computing the cophenetic distances, although I am not certain how much it would actually influence the absolute value range. Thank you again for your comments. I hope to be able to clean up the code accordingly; for now, there is no "easy fix" for the rooting issue and the |
Hi Sebastian,
I am trying to run the "prepare.community_similarity.R" script with a higher PARAM$thresh.otu_size <- 300 for higher speed, however, I get
`[[998]]
[1] "Error in nodepath(x, from = tip, to = my.root) : can't find 'my.root'\n"
attr(,"class")
[1] "try-error"
attr(,"condition")
<simpleError in nodepath(x, from = tip, to = my.root): can't find 'my.root'>
[[999]]
[1] "Error in nodepath(x, from = tip, to = my.root) : can't find 'my.root'\n"
attr(,"class")
[1] "try-error"
attr(,"condition")
<simpleError in nodepath(x, from = tip, to = my.root): can't find 'my.root'>
[[1000]]
[1] "Error in nodepath(x, from = tip, to = my.root) : can't find 'my.root'\n"
attr(,"class")
[1] "try-error"
attr(,"condition")
<simpleError in nodepath(x, from = tip, to = my.root): can't find 'my.root'>
[ reached getOption("max.print") -- omitted 2329 entries ]
Calculate distances between all pairs of tips => 2017-06-21 10:05:55
Done => 2017-06-21 10:06:32
Coerce into matrix => 2017-06-21 10:06:32
Done. Returning => 2017-06-21 10:06:34
Warning message:
In mclapply(seq(1, Ntip(x)), function(tip) { :
all scheduled cores encountered errors in user code`
I replace my.root with 1 in the script “my.node_paths <- mclapply(seq(1, Ntip(x)), function (tip) {nodepath(x, from=tip, to=my.root)}, mc.cores=use.cores);” it works. I don't kown if it's correct?
By the way, I get the histogram.SparCC.pdf file with blank.
bests!
Hongyi
The text was updated successfully, but these errors were encountered: