1
$\begingroup$

I read the thread How to make the Show function work in this case?. I think I have the same problem as discussed there. But when I try the to evaluate

Show[Plot[x^2, {x, 2, 10}], Plot[1 - x, {x, 1, -10}], 
  PlotRange -> All]

it doesn't work. The output:

looks like it did nothing?.

How can I fix it?


Update: This comes afterClear["*", All];. Clear["*", All]; Show[Plot[x^2, {x, 2, 10}], Plot[1 - x, {x, 1, -10}], PlotRange -> All] makes it failed.

$\endgroup$
7
  • 1
    $\begingroup$ Have you played with $DisplayFunction? What if you evaluate $DisplayFunction = Identity? $\endgroup$
    – Kuba
    Commented Jul 15, 2016 at 6:04
  • $\begingroup$ @Kuba Now I can't reproduce it after restart Mathematica for several times... Why should I evaluate $DisplayFunction = Identity? What's Identity? I have never heard it before. $\endgroup$ Commented Jul 15, 2016 at 6:40
  • $\begingroup$ Both of those symbols can be looked up by pressing F1. $\endgroup$
    – Kuba
    Commented Jul 15, 2016 at 6:43
  • 1
    $\begingroup$ I'm voting to close this question as off-topic because the problem the user is experiencing can not be reproduced by others. $\endgroup$
    – m_goldberg
    Commented Jul 15, 2016 at 6:58
  • 1
    $\begingroup$ @m_goldberg I know what I did. Add Clear["*", All]; before the command can reproduce it. I can't see why Claer makes it failed. $\endgroup$ Commented Jul 15, 2016 at 7:10

1 Answer 1

4
$\begingroup$

Clear["*"] clears every symbol found on $ContextPath which is not Protected. So many System` symbols too...

Moreover, unless you want to double clear System`All, Clear["*", All] is made up syntax.

What you probably want is Clear["Global`*"] or ClearAll["Global`*"]

Weren't you warned by:

enter image description here

$\endgroup$
1
  • 1
    $\begingroup$ Ergo, Show appeared to be broken because the OP broke it. $\endgroup$
    – m_goldberg
    Commented Jul 15, 2016 at 7:29

Not the answer you're looking for? Browse other questions tagged or ask your own question.