How to set fix node positions with ggnet2
up vote
0
down vote
favorite
I am using ggnet2 to visualize networks and I was wondering whether anyone is aware of a way to fix the node positions as it is possible with e.g. igraph (as explained e.g. here How to control the igraph plot layout with Fixed Positions?)
Thanks,
Chris
r ggplot2
add a comment |
up vote
0
down vote
favorite
I am using ggnet2 to visualize networks and I was wondering whether anyone is aware of a way to fix the node positions as it is possible with e.g. igraph (as explained e.g. here How to control the igraph plot layout with Fixed Positions?)
Thanks,
Chris
r ggplot2
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I am using ggnet2 to visualize networks and I was wondering whether anyone is aware of a way to fix the node positions as it is possible with e.g. igraph (as explained e.g. here How to control the igraph plot layout with Fixed Positions?)
Thanks,
Chris
r ggplot2
I am using ggnet2 to visualize networks and I was wondering whether anyone is aware of a way to fix the node positions as it is possible with e.g. igraph (as explained e.g. here How to control the igraph plot layout with Fixed Positions?)
Thanks,
Chris
r ggplot2
r ggplot2
edited Nov 6 at 21:32
asked Nov 6 at 20:22
ChriiSchee
302612
302612
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
1
down vote
I had the same problem myself and fixed it by setting the random seed. Apparently ggnet2 randomly distributes the nodes in line with the selected algorithm-mode.
So to get reproducible that is to say identical plots just always use set.seed()
before every plot.
e.g.:
set.seed(1)
ggnet2(net)
New contributor
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
I had the same problem myself and fixed it by setting the random seed. Apparently ggnet2 randomly distributes the nodes in line with the selected algorithm-mode.
So to get reproducible that is to say identical plots just always use set.seed()
before every plot.
e.g.:
set.seed(1)
ggnet2(net)
New contributor
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
add a comment |
up vote
1
down vote
I had the same problem myself and fixed it by setting the random seed. Apparently ggnet2 randomly distributes the nodes in line with the selected algorithm-mode.
So to get reproducible that is to say identical plots just always use set.seed()
before every plot.
e.g.:
set.seed(1)
ggnet2(net)
New contributor
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
add a comment |
up vote
1
down vote
up vote
1
down vote
I had the same problem myself and fixed it by setting the random seed. Apparently ggnet2 randomly distributes the nodes in line with the selected algorithm-mode.
So to get reproducible that is to say identical plots just always use set.seed()
before every plot.
e.g.:
set.seed(1)
ggnet2(net)
New contributor
I had the same problem myself and fixed it by setting the random seed. Apparently ggnet2 randomly distributes the nodes in line with the selected algorithm-mode.
So to get reproducible that is to say identical plots just always use set.seed()
before every plot.
e.g.:
set.seed(1)
ggnet2(net)
New contributor
New contributor
answered Nov 19 at 12:25
Fabian Sky
111
111
New contributor
New contributor
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
add a comment |
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
Thanks @Fabian Sky, I actually used the same hack ... would thus still be helpful to truly fix the node positions
– ChriiSchee
20 hours ago
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53179442%2fhow-to-set-fix-node-positions-with-ggnet2%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown