In ggplot 2, how to connect the start and the end points in geom_line
<p>I want to connect three dots "a", "b" and "c" using geom_line, but it only connects "ab" and "bc", but not "ca", how can I achieve that using geom_line or geom_path, rather than geom_polygon?</p>

<pre><code>library(ggplot2)
df &lt;- data.frame (line =c ("a", "b", "c"), x = c(1, 2, 3), y = c(5, 2, 5))

ggplot() +
geom_path(data = df, aes (x = x, y = y, color = line))
</code></pre>