如何向上移动图像以适合幻灯片

如何向上移动图像以适合幻灯片

我有这个例子

\documentclass{beamer}

\mode<presentation>
{
  \usetheme{Boadilla}     
  \usecolortheme{wolverine}
  \usefonttheme{structurebold}  
  \setbeamertemplate{navigation symbols}{}
  \setbeamertemplate{caption}[numbered]
\setbeamertemplate{itemize items}[ball]
} 

\usepackage{array,amsmath,booktabs}
\usepackage{amsmath}
\usepackage[version=4]{mhchem}
\usepackage{mathtools}
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage{mwe} % for blindtext and example-image-a in example
\usepackage{wrapfig}


\begin{document}


\begin{frame}{Inference}

\begin{itemize}
\item Independent gamma priors:
\end{itemize}
\begin{gather*}
 \pi(c) = \prod\limits_{j=1}^v \pi(c_j), \quad c_j \sim Ga(a_j, b_j), \; j=1,...,v
\end{gather*}
\begin{itemize}
\item Prior combined with our likelihood gives us updated posteriors:
\end{itemize}
\begin{gather*}
c_j|\mathbf {x} \sim Ga\Big(a_j+r_j,b_j+\int_0^Tg_j(x(t))\,dt \Big), \; j=1,..,v
\end{gather*}
\begin{columns}
 \column{0.5\textwidth}\centering
\begin{itemize}
\item Simulate our system to get perfect information
\item Graph shows simulated data for 300 reactions of our Micahelis-Menten model
\end{itemize}
 \column{0.5\textwidth}\centering
\begin{figure}
\includegraphics[width=0.8\linewidth]{C:/Users/Acer/Desktop/PresentationGraphics/Simulateddatagraph.pdf}
%  \captionof{figure}{Simulated data for 300 reactions\label{fig:boat1}}
\end{figure}
\end{columns}
\end{frame}

 \end{document}

我的图片不适合幻灯片。我不想缩小图片,因为这样别人就看不到它了。

我尝试过用文字环绕图像,但似乎也不起作用。

我也尝试过寻找类似的问题但我确实找不到任何有帮助的东西。

答案1

看来您的图像达到了高度...通过graphicx包中的示例图像并重写您的框架,我设法在幻灯片上显示完整的图像:

在此处输入图片描述

\documentclass{beamer}

\mode<presentation>
{
  \usetheme{Boadilla}
  \usecolortheme{wolverine}
  \usefonttheme{structurebold}
  \setbeamertemplate{navigation symbols}{}
  \setbeamertemplate{caption}[numbered]
\setbeamertemplate{itemize items}[ball]
}

\usepackage{array,amsmath,booktabs}
\usepackage{amsmath}
\usepackage[version=4]{mhchem}
\usepackage{mathtools}
\usepackage{subcaption}
%\usepackage{mwe} % for blindtext and example-image-a in example
\usepackage{wrapfig}

\begin{document}

\begin{frame}{Inference}
    \begin{itemize}% <--- changed
\item Independent gamma priors:
\[
 \pi(c) = \prod\limits_{j=1}^v \pi(c_j), \quad c_j \sim Ga(a_j, b_j), \; j=1,...,v
\]
\item Prior combined with our likelihood gives us updated posteriors:
\[
c_j|\mathbf {x} \sim Ga\Big(a_j+r_j,b_j+\int_0^Tg_j(x(t))\,dt \Big), \; j=1,..,v
\]
    \end{itemize}

\begin{columns}
 \column{0.5\textwidth}\centering
    \begin{itemize}
\item Simulate our system to get perfect information
\item Graph shows simulated data for 300 reactions of our Micahelis-Menten model
    \end{itemize}
 \column{0.5\textwidth}\centering
\begin{figure}
\includegraphics[width=0.8\linewidth]{example-image-a}%{C:/Users/Acer/Desktop/PresentationGraphics/Simulateddatagraph.pdf}
%  \captionof{figure}{Simulated data for 300 reactions\label{fig:boat1}}
\end{figure}
\end{columns}

\end{frame}
\end{document}

答案2

您可以在图形前添加负 \vspace 以将其向上移动:

\documentclass{beamer}

\mode<presentation>
{
  \usetheme{Boadilla}
  \usecolortheme{wolverine}
  \usefonttheme{structurebold}
  \setbeamertemplate{navigation symbols}{}
  \setbeamertemplate{caption}[numbered]
\setbeamertemplate{itemize items}[ball]
}

\usepackage{array,amsmath,booktabs}
\usepackage{amsmath}
\usepackage[version=4]{mhchem}
\usepackage{mathtools}
\usepackage{graphicx}
\usepackage{subcaption}
\usepackage{mwe} % for blindtext and example-image-a in example
\usepackage{wrapfig}


\begin{document}


\begin{frame}{Inference}

\begin{itemize}
\item Independent gamma priors:
\end{itemize}
\begin{gather*}
 \pi(c) = \prod\limits_{j=1}^v \pi(c_j), \quad c_j \sim Ga(a_j, b_j), \; j=1,...,v
\end{gather*}
\begin{itemize}
\item Prior combined with our likelihood gives us updated posteriors:
\end{itemize}
\begin{gather*}
c_j|\mathbf {x} \sim Ga\Big(a_j+r_j,b_j+\int_0^Tg_j(x(t))\,dt \Big), \; j=1,..,v
\end{gather*}
\begin{columns}
 \column{0.5\textwidth}\centering
\begin{itemize}
\item Simulate our system to get perfect information
\item Graph shows simulated data for 300 reactions of our Micahelis-Menten model
\end{itemize}
 \column{0.5\textwidth}\centering
\begin{figure}
\vspace{-10cm}%adapt
\includegraphics[width=0.8\linewidth]{example-image-a}
%  \captionof{figure}{Simulated data for 300 reactions\label{fig:boat1}}
\end{figure}
\end{columns}
\end{frame}
\end{document}

相关内容