Resizing Matlab plots for publication purposes (LaTeX)

版本 1.0.0.0 (4.8 KB) 作者: Jinyu
This function will resize the plot to the proper size based on the figure width and font size.
1.3K 次下载
更新时间 2012/4/30

查看许可证

latex_fig.m is the function file which will automatically adjust the plot size according to the specification: font_size and f_width. It will save your time on tuning font size and figure window size.

function latex_fig(font_size, f_width, f_height)
% font_size: the font size used in the paper;
% f_width: the figure width (in inches, same as the number used in the LaTeX file, for example, \includegraphics[width=3in]{myfigure})
% f_height: the figure height (in inches)

latex_fig_demo.m is the demo file which will show you how to call the function.

After resizing, you can save the figure file to the EPS format, for example, myfigure.eps.

In LaTeX file, the figure can be included as:
\begin{figure}[!t]
\centering
\includegraphics[width=3in]{myfigure}
\caption{Simulation Results}
\label{fig_sim}
\end{figure}

引用格式

Jinyu (2024). Resizing Matlab plots for publication purposes (LaTeX) (https://www.mathworks.com/matlabcentral/fileexchange/36439-resizing-matlab-plots-for-publication-purposes-latex), MATLAB Central File Exchange. 检索来源 .

MATLAB 版本兼容性
创建方式 R2011b
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Printing and Saving 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
版本 已发布 发行说明
1.0.0.0