-
Notifications
You must be signed in to change notification settings - Fork 28
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
Error in layout$fun(graph = list(1598, TRUE, c(0, 0, 0, 0, 0, 0, 0, 0, : At rinterface_extra.c:82 : The value 10.642051692927977 is not representable as an integer. Invalid value #362
Comments
differential_Taxa_abundance_Mat_vs_Open_fdr05.pdf Also it is an issue with my dataset as the workshop example has no problem |
same problem here ! |
Hi team, It seems to occur in large graphs more than small ones. For example, if I aggregate 16S data at the Order level things it renders perfectly! If I aggregate to Family, Genus, or Species however it does not and triggers the above error. I thought this may be due to package updates and incompatibility. But it occurs even with minimal packages loaded. This doesn't mean there was some update to a metacoder dependency that has broken things. Then: a clue! Trial and error has shown that using a layout diffferent than 'davidson-harel' things render fine! This is with using "reingold-tilford" as 'initial_layout'. I tested with using 'davidson-harel' as layout and all other layouts as 'initial layout' and the issue persists. So the problem seems to be in the 'davidson-harel' layout. This is unfortunate, since for my data the other layouts do not give very useful plots. I would love to resolve this so I hope this may help others more knowledegable than me squash this bug! Cheers, |
Can anyone supply example code and data that reproduces this error? Thanks! |
Hi Zach (and community!), The script includes a (roughly) minimal example and tests narrowing things down. I have commented it for you with observations. You just need to adjust input and output directory to match your file structure (I hope that is the only thing to change anyways). I have at least figured out the cause of the problem: it is the Davidson-harel layout when trying to visualize very large (many-taxa) trees. I am not sure if this is a memory problem; I tested on a machine with 128GB RAM so pretty large (I sadly do not have access to a cloud right now to test further). I hope this was helpful!
|
Great, thanks! I have reproduced the error |
Hi @zachary-foster, Is there a fix for this? I'm running into the same issue. Thank you! |
Hello,
I finally got through the scripts to the point where I am trying to tweak my Log2FC heat.tree
I get a tree with no issues if I use the following script
set.seed(1)
obj6 %>%
heat_tree(node_label = taxon_names,
node_size = n_obs, # number of OTUs
node_color = log2_median_ratio, # difference between groups
node_color_interval = c(-15, 15), # symmetric interval
node_color_range = c("cyan", "gray", "magenta"), # diverging colors
node_size_axis_label = "OTU count",
node_color_axis_label = "Log 2 ratio of median counts",
title = "Open vs Mat samples")
But if I add a line to control the layout as follows:
set.seed(1)
obj6 %>%
heat_tree(node_label = taxon_names,
node_size = n_obs, # number of OTUs
node_color = log2_median_ratio, # difference between groups
node_color_interval = c(-15, 15), # symmetric interval
node_color_range = c("cyan", "gray", "magenta"), # diverging colors
node_size_axis_label = "OTU count",
node_color_axis_label = "Log 2 ratio of median counts",
layout = "da", initial_layout = "re",
title = "Open vs Mat samples")
then I get this error:
Error in layout$fun(graph = list(1598, TRUE, c(0, 0, 0, 0, 0, 0, 0, 0, :
At rinterface_extra.c:82 : The value 10.642051692927977 is not representable as an integer. Invalid value
Any thoughts on how to fix this please?
Darryl
The text was updated successfully, but these errors were encountered: