I am making a density plot with ggplot
of a dataframe (datf) composed of several time series.the command I am using is:
ggplot (melt (datf), mapping = aes (fill = variable, x = value)) + geom_density (alpha = .5)+ xlim(0,45)
and I am getting this graph:
enter image description here There are 2 things wrong, 1: The lengend is obviously big and showing the info I don't want to show (I would like to use names stored in a vector "v") 2: The plot is actually wrong, a correct one should show a shape like that:
enter image description here I checked other similar questions but I got confused of how to give the right command. how the right command should look?