# How to adjust the size of a FrameLabel that consists of a picture or an object from MaTeX?

I want to plot a figure with $$\LaTeX$$ formulas as labels. A simple example looks like the following:

<<MaTeX
Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True, FrameLabel -> (MaTeX /@ {"x", "\\rm{sin}(x)"})]


However, the labels sin(x) and x are too small in the figure for me and I want larger ones. How can I adjust their sizes?

In another case if the label is a figure, like

fig = Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True];
Export["test.pdf", fig];
lab = Import["test.pdf"] // First;
DeleteFile["test.pdf"];
Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True, FrameLabel -> {None, lab}]


Again, how do I adjust the label size?

• You can set the font size for MaTeX, Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True, FrameLabel -> MaTeX[{"x", "\\sin x"}, FontSize -> 18]]. \sin x is better than using \rm. – Szabolcs Apr 25 at 15:21

According to the documentation, there are two options that will affect the size of labels; you can also adjust the size of the plot to have the labels appear larger.

<< MaTeX
SetOptions[MaTeX, "FontSize" -> 14, "Magnification" -> 1.2];
Plot[Sin[x], {x, 0, 2 \[Pi]},
Frame -> True, FrameLabel -> (MaTeX /@ {"x", "\\rm{sin}(x)"}),
ImageSize -> 250] For your second example just use ImageSize when creating the label.

fig = Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True, ImageSize -> 120];
Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True,
FrameLabel -> {None, fig}]


Again, if your label is any image object you can use Show with a size option:

pic = (* some picture goes here *)
Plot[Sin[x], {x, 0, 2 \[Pi]}, Frame -> True,
FrameLabel -> {None, Show[pic, ImageSize -> Small]}] • What if the figure is the photo from my cellphones or any other source? I know that I can use ImageSize to control the label size in the wolfram system but I want to know how to deal with a general case. – Jie Zhu Apr 25 at 9:47
• @Jie see my edit – A.G. Apr 25 at 12:26