library
(
"ggplot2"
)
gfg1 < -
data.frame
(x=
c
(4, 5, 1, 7, 8),
y=
c
(1, 4, 8, 6, 9))
gfg2 < -
data.frame
(x=
c
(5, 1, 4, 3, 7),
y=
c
(7, 8, 9, 1, 2))
gfg3 < -
data.frame
(x=
c
(4, 8, 6, 3, 5),
y=
c
(3, 4, 5, 8, 7))
gfg4 < -
data.frame
(x=
c
(8, 6, 7, 2, 1),
y=
c
(8, 6, 4, 1, 9))
gfg5 < -
data.frame
(x=
c
(6, 1, 6, 5, 4),
y=
c
(6, 8, 7, 6, 4))
gfg_plot < -
ggplot
(
NULL
,
aes
(x, y)) +
geom_line
(data=gfg1, col=
"green"
) +
geom_line
(data=gfg2, col=
"blue"
)+
geom_line
(data=gfg3, col=
"red"
)+
geom_point
(data=gfg4, col=
"purple"
) +
geom_point
(data=gfg5, col=
"black"
)
gfg_plot