I am combining the plot of 1/x with some of the points on that line. Here is the data
sdata = { {-5, -0.2}, {-2, -0.5}, {-1, -1}, {-1/2, -2}, {-0.2, -5},
{0.2, 5}, {0.5, 2}, {1, 1}, {2.0, 0.5}, {5.0, 0.2} }
This graphs all ten points.
ListPlot[{sdata}, Joined -> False]
When I use Show to combine the Plot of 1/x with the Graphics, it works great except the last two points don't appear.
Show[
Plot[{0 , 1/x}, {x, -7, 7}, PlotRange -> {{-7, 7}, {-7, 7}}],
Graphics[{PointSize[Medium], Blue, Point[sdata]}]
]
How do I get the last two points to show up?
PlotwithEpilog, e.g.,Plot[{0, 1/x}, {x, -7, 7}, PlotRange -> {{-7, 7}, {-7, 7}}, Epilog -> {PointSize[Medium], Blue, Point[sdata]}]– Bob Hanlon Sep 10 '23 at 20:55,PlotRange -> AllafterGraphics[..]before the last].Show[]uses the settings from the first plot. It does not try to combine the options. – Michael E2 Sep 10 '23 at 21:25