Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I would like to draw the blue guide lines as shown spanning between the top and bottom graphs. Any help is appreciated. Thanks!

share|improve this question
    
Please add any germane code to generate the graphs and clarify precisely how these "guide lines" are defined. –  rasher Jun 1 at 22:27
    
Kuba answered. (Graph is generated in xmgrace and not mathematica.) –  Ari Jun 1 at 22:55

1 Answer 1

up vote 4 down vote accepted

The key is PlotRangeClipping-> False:

With[{stdopt = 
   Sequence[Frame -> True, Axes -> False, ImageSize -> 300, PlotRangeClipping -> False,
            PlotStyle -> {Red, Thick}]},
 Column[{
   Plot[x, {x, 0, Pi/2}, Epilog -> {Thick, Blue, Line[{{.5, .5}, {.5, -1}}]}, stdopt],
   Plot[Sin[x], {x, 0, Pi/2}, stdopt, Epilog -> {Thick, Blue, Line[{{0, Sin@.5}, 
                                                 {.5, Sin@.5}, {.5, 5}}]}]
   }, Spacings -> 0]]

enter image description here

share|improve this answer
    
You may be also interested in PlotRangePadding->0. –  Kuba Jun 1 at 21:52
    
It's the Epilog which did the trick. Very nice! –  Ari Jun 1 at 22:52

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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