1

I'm a little embarrassed asking such a simple question, but it's a problem I'm having since a long time. I want to e.g. have a plot beside some text. Now, I want that the top line of the plot and the top line of the text are at the same hight. I can't get this to work. When I use Alignment -> Top the text is always aligned at the middle and I don't know why. This sounds all very simple, so any help is appreciated. E.g.

Row[{ListPlot[{1, 2, 1, 3}, Joined -> True, Frame -> True,ImageSize -> 400], "    ", Framed@Grid[{{"test"}, {"test2"}}]}, Alignment -> Top]

The result is>

enter image description here

So top line of plot and of text not at the same height.

Mockup Dungeon
  • 1,854
  • 12
  • 16
  • Use Grid[{{...}},Alignment->{Center,Top}]. p.s. Spacer is neater than " ". – Kuba Jan 16 '14 at 20:44
  • I tried this, but then the text is below the plot. I want it beside the plot, but so that the lines at the top of the plot and that of the text are aligned. So, the text needs to go higher. – Thanks for the 'Spacer' tip, though. – Mockup Dungeon Jan 16 '14 at 20:52
  • I believe you are talking about Grid[{{...},{...}}]. It's not what I meant, the answer of PatoCorillo is. – Kuba Jan 16 '14 at 21:06
  • Yes, I have it now. Thanks. I didn't realise this doesn't work with Row. – Mockup Dungeon Jan 16 '14 at 21:08

1 Answers1

1
Grid[{{ListPlot[{1, 2, 1, 3}, Joined -> True, Frame -> True, 
    ImageSize -> 400], Framed@Grid[{{"test"}, {"test2"}}]}}, 
 Alignment -> Top]
Zviovich
  • 9,308
  • 1
  • 30
  • 52