# Edit AxesLabel from an existing plot

I have a really complex function that takes a few hours to plot as a function of a parameter. Few days later I realised that I named the axes wrong. Is there an easy way to edit the AxesLabels without running the plot again? (it takes too long!!) I tried Show[%, AxesLabel-> {newname, newname2}] but it doesn't change anything...

-

Very straightforward:

plot = Plot[Sin[x], {x, 0, 2 Pi}];

plot /. (AxesLabel -> _) -> (AxesLabel -> {"x", "y"})

-
Ah, proofs I still have a lot to learn ;) Thanks man! –  Sibylle Apr 28 '13 at 20:47
You can copy and paste your graphic, add /. {"oldName1" -> "newName1", "oldName2" -> "newName2"} after it, and evaluate :
g = Plot[Sin[x], {x, 0, 2 \[Pi]}]