Open roelicaal opened 2 years ago
My hunch is that it is confused that you are using integer vertex ids, but they don't correspond the 'index' id of vertex ids. i.e. the first vertex has id 80, and it created a network with 4036 vertices in order to include the largest id. I think the network constructors can do some conversion from labels to ids, so could try converting the vertex.id column to character before constructing the network? otherwise, I think you need to replace each value in your edgelist with the index of the node that has that label.
Thank you!
Converting the vertex.id column does not work (the networkDynamic function does not accept values other than numeric) but I solved it by replacing the ids with consecutive values.
Thank you!
Converting the vertex.id column does not work (the networkDynamic function does not accept values other than numeric) but I solved it by replacing the ids with consecutive values.
Thank you very much, that was very useful! I think it should be possible to have node.ids that are non-consecutive
Hi! I am having issues loading a dynamic network. I am on Windows 11, run R 4.2.1 and the latest versions of the network- and networkDynamic packages installed using devtools::install_github and auto-compiled using rtools4.2.
Loading a static network works I am able to load a static network:
`
My data look like this:
`
Network characteristics are as follows:
`
I can't load a dynamic network I can't seem to load a dynamic network by using the static networks as a base.
`
When I try to load the network only using the spell data frames, then it seem to load but incorrectly, imputing the number of nodes from the highest numeric value in my vertex.ids (which is 4036).
`
`
I double checked my data and that seems to be fine:
`
`
When looking at the code of the networkDynamic package, it seems to go wrong at lines 470-490 where it does not take the maximum number of vertexes to check data validity, but the maximum value among the vertexes.
Which makes me wonder: is this a bug or am I doing something wrong?
`
`