Mathematica Asked on November 29, 2020
I need to fix the following code
Plot[V[x], {x, -3, 3}, PlotRange -> {-3, 1}, PlotTheme -> "Detailed",
PlotStyle -> Automatic, AxesLabel -> Automatic, Frame -> True,
FrameLabel -> {Style["x", FontSize -> 22, Bold],
Style["V(x)", FontSize -> 22, Bold]}, ImageSize -> Large]
to remove the "—V(x)" right next to the Plot. It makes no sense because it’s the only function being plotted.
Thanks in advance.
An alternative approach to remove the legend: Take the first Part
of Plot
output:
plot = Plot[Sin[x] - 1, {x, -3, 3}, PlotRange -> {-3, 1},
PlotTheme -> "Detailed", PlotStyle -> Automatic,
AxesLabel -> Automatic, Frame -> True,
FrameLabel -> {Style["x", FontSize -> 22, Bold], Style["V(x)", FontSize -> 22, Bold]},
ImageSize -> Large]
First @ plot
Correct answer by kglr on November 29, 2020
As @kglr stated, this will do:
Plot[V[x], {x, -3, 3}, PlotRange -> {-3, 1}, PlotTheme -> "Detailed",
PlotStyle -> Automatic, AxesLabel -> Automatic, Frame -> True,
FrameLabel -> {Style["x", FontSize -> 22, Bold],
Style["V(x)", FontSize -> 22, Bold]}, ImageSize -> Large,
PlotLegends -> None]
and the Plot is fixed.
Answered by holahola on November 29, 2020
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP