# linegraph in igraph-python

**URL:** <https://igraph.discourse.group/t/linegraph-in-igraph-python/622>\
**Category:** Usage\
**Tags:** Python\
**Created:** [10 February 2021 13:02 UTC](https://igraph.discourse.group/t/linegraph-in-igraph-python/622 "2021-02-10T13:02:42Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sid](https://yyz2.discourse-cdn.com/free1/user_avatar/igraph.discourse.group/sid/32/451_2.png) [@sid](https://igraph.discourse.group/u/sid)\
**Post date:** [10 February 2021 13:02 UTC](https://igraph.discourse.group/t/linegraph-in-igraph-python/622/1 "2021-02-10T13:02:42Z")

</div>

I was hoping to use linegraph to get a graph of nodes becoming edges and vice-versa. But, igraph python version can not find a function called linegraph, though it is explicitly mentioned in the manual. Any pointers will be appreciated. I am using python-igraph version ‘0.7.1’. By the way it exists in R as line.graph . None of line\_graph, line.graph or linegraph work in Python-igraph.

Thank you in advance for any pointers.

---

<div class="post-metadata">

**Author:** ![szhorvat](https://yyz2.discourse-cdn.com/free1/user_avatar/igraph.discourse.group/szhorvat/32/3_2.png) [@szhorvat](https://igraph.discourse.group/u/szhorvat)\
**Post date:** [11 February 2021 09:29 UTC](https://igraph.discourse.group/t/linegraph-in-igraph-python/622/2 "2021-02-11T09:29:56Z")

</div>

You can search the documentation [here](https://igraph.org/python/doc/igraph-module.html). (See “Indices” link.)

`linegraph` is here: [https://igraph.org/python/doc/igraph.GraphBase-class.html#linegraph](https://igraph.org/python/doc/igraph.GraphBase-class.html#linegraph) Note that it is a method of graph objects, not a standalone function.

> [@sid](#):
>
> I am using python-igraph version ‘0.7.1’.

Is there any reason why you want to use such an outdated version instead of the latest, much improved one? 0.8.3 is available in PyPI as well as conda-forge. Installation instructions are here: [python-igraph manual](https://igraph.org/python/#startpy)
