[Tex/LaTex] how to scale each dimension of an image with different ratio


I would like to scale an image file for each dimension differently for example 50% of the x dimension or 25% of the y dimension. Thank you very much.

Best Answer

There are several ways to go about this.

In the graphicx package you can specify:

\includegraphics[width=<dim>,height=<dim>]{<file name>}

You can also use

\scalebox{<horizontal scale factor>}[<vertical scale factor>]{\includegraphics{<file name>}}

Also there's

\resizebox{<horizontal dimension>}{<vertical dimension>}{\includegraphics{<file name>}}