Skip to content
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 with dplyr::bind_rows() #125

Closed
emafin opened this issue Jan 30, 2024 · 1 comment
Closed

Error with dplyr::bind_rows() #125

emafin opened this issue Jan 30, 2024 · 1 comment

Comments

@emafin
Copy link

emafin commented Jan 30, 2024

I am trying to estimate centrality statistics but I keep getting the error:

in `dplyr::bind_rows()`:
! Can't combine `..1$node2` <integer> and `..3$node2` <character>.

I have re-installed both dplyr/tidyverse and bootnet (including the latest version from github) and I am currently running v. 1.5.6, but the error is still there. I am including a reproducible example, below. Thank you in advance for any help you may be able to offer.

# Load packages
library(bootnet)
library(tidyverse)

# Estimate network
net <- mtcars %>% 
  select(disp, hp, drat, wt) %>% 
  estimateNetwork(., default = "EBICglasso", threshold = TRUE, corMethod = "spearman")

# Centrality statistics
centr <-
  net %>%
  bootnet(.,
          nBoots = 100,
          default = "EBICglasso",
          type = "nonparametric",
          labels = colnames(.),
          statistics = "all",
          useCommunities = "all",
          communities = c("A", "A", "B", "B"))
@emafin emafin closed this as completed Jan 30, 2024
@emafin
Copy link
Author

emafin commented Jan 30, 2024

Sorry, the problem was colnames(.) from a previous run, removing it solved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant