igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [igraph] plot.igraph and x-axis


From: Hermann Norpois
Subject: Re: [igraph] plot.igraph and x-axis
Date: Tue, 26 Nov 2013 16:26:00 +0100

I am sorry I did not get it.
If I use rescale=FALSE my plot is empty.

Actually I would like to change the rescale parameters. Is that possible, i.e.
rescaleparameters = V(gs)$x

My try:
plot (gs, vertex.size=2, vertex.label=NA,rescale=FALSE, edge.width= (E(gs)$weight)^6, layout=cbind (V(gs)$x, V(gs)$y))

> dput (gs)
structure(list(2, FALSE, 1, 0, 0, 0, c(0, 0, 1), c(0, 1, 1),
    list(c(1, 0, 1), structure(list(), .Names = character(0)),
        structure(list(name = c("rs744016", "rs763273"), x = c(27042106L,
        27043594L), y = c(0.6445235948615, 0.6229189950958)), .Names = c("name",
        "x", "y")), structure(list(weight = 0.986597, y = 0.7704755,
            color = "red"), .Names = c("weight", "y", "color"
        )))), class = "igraph")
> class (gs)
[1] "igraph"
>  plot (gs, vertex.size=2, vertex.label=NA,rescale=FALSE, edge.width= (E(gs)$weight)^6, layout=cbind (V(gs)$x, V(gs)$y))
> axis (1, at=1:10) # Does not change anything.
>  plot (gs, vertex.size=2, vertex.label=NA, edge.width= (E(gs)$weight)^6, layout=cbind (V(gs)$x, V(gs)$y))
>


2013/11/26 Gábor Csárdi <address@hidden>
Hi,

no, this is an igraph thing, igraph rescales layouts to (-1, 1),
unless you specify the rescale=FALSE:

http://igraph.sourceforge.net/doc/R/plot.common.html

Gabor

On Tue, Nov 26, 2013 at 9:53 AM, Hermann Norpois <address@hidden> wrote:
> Hello,
>
> I want to have an x-axis with x-values refering to V(g)$x.
>
> How does this work?
>
> I tried
> axis (1, at=V(g)$x) without an effect.
>
> dput (axis (1)) has the following output:
> c(-1, -0.5, 0, 0.5, 1)
>
> How can I change this? I guess it is more a classical R-question ...
>
> thanks
> Hermann
>
>
> _______________________________________________
> igraph-help mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/igraph-help
>

_______________________________________________
igraph-help mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/igraph-help


reply via email to

[Prev in Thread] Current Thread [Next in Thread]