# Combining Plot and ListPlot using appropriate colours [closed]

I have Plot and ListPlot and I want to combine the using Show:

plt = Plot[{Cos[x], Sin[x]}, {x, 0, 2}];
plt2 = ListPlot[{{1, 1}, {0.5, 0.5}}];
plt3 = ListPlot[{{0.4, 1}, {0.2, 0.5}}];
Show[plt, plt2, plt3]


But the problem is with colouring the ListPlots. Let's say I would like plt2 markers have the same colour as Cos[x] and plt3 the same colour as Sin[x]. How would I do it?

## closed as off-topic by Mr.Wizard♦Jul 22 '15 at 6:09

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – Mr.Wizard
If this question can be reworded to fit the rules in the help center, please edit the question.

• Why not put the two ListPlot[]s together? plt2 = ListPlot[{{{1, 1}, {0.5, 0.5}}, {{0.4, 1}, {0.2, 0.5}}}];? – J. M. is away Jul 22 '15 at 5:10
• You could also specify PlotStyle colors manually if needed for some reason. If you wish to match the defaults see (54629) – Mr.Wizard Jul 22 '15 at 6:09
• I am sorry, I wanted an automated solution. I know how to do it manually, but such a solution is rather clumsy and yes, that is trivial. But what I want is a nice automated solution (like use the same colour for listplot as you used for plot). – leosenko Jul 22 '15 at 6:18
• In that case, you need to explicitly set PlotStyle. Mr. Wizard has already linked you to the thread on how the default colors are generated. – J. M. is away Jul 22 '15 at 7:00

plt = Plot[{Cos[x], Sin[x]}, {x, 0, 2}