[Tex/LaTex] Beamer: Prevent/disable appearing individual subsection titles before actual content

beamer

Recently I started to question my decision to enable the appearance of individual subsection titles before actual content. I still want to show the outline of the upcoming section once before the section's content, however I feel that showing the same outline with an upcoming subsection title emphasized is an overkill (IMHO this approach produces too many extra slides).

Therefore, while I'm still finalizing my decision, I'd like to have an option to switch my Beamer presentation's current behavior for section outline management, controlled by the following code. What should be changed in the code for the above-mentioned alternative behavior?

\AtBeginSubsection[]
{
  \begin{frame} %<beamer>
    \frametitle{Outline}
    \setcounter{tocdepth}{2}
    \tableofcontents[
      currentsection,
      currentsubsection,
      sectionstyle=show/hide,
      subsectionstyle=show/shaded/hide
    ]
  \end{frame}
}

Best Answer

I've already figured out my problem. The reason of the undesired behavior was that I was using two methods of section outline management simultaneously: manual (via \tableofcontents) and automatic (via \AtBeginSection). The following MWE with fix - disabling the automatic control code - illustrates the situation.

\documentclass[12pt]{beamer}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{graphicx}
\usepackage{booktabs}
\usepackage{tikz}
\usetikzlibrary{mindmap, trees, shadows, shapes, backgrounds, calc, fadings, positioning, decorations.pathreplacing, intersections, fit}
\usepackage{smartdiagram}

\usepackage{palatino}

\usetheme{Boadilla}
\usecolortheme{orchid}
\useinnertheme{rectangles}
\beamertemplateshadingbackground{gray!5}{gray!20}
\setbeamertemplate{navigation symbols}{}

% THE FIX -- LEFT FOR ILLUSTRATION -- TO BE DELETED
%\AtBeginSection[]
%{
%  \begin{frame} %<beamer>
%    \frametitle{Outline}
%    \setcounter{tocdepth}{2}
%    \tableofcontents[
%    currentsection,
%    currentsubsection,
%    sectionstyle=show/hide,
%    subsectionstyle=show/shaded/hide
%    ]
%  \end{frame}
%}

\begin{document}

% Produce top-level TOC
\frame{\tableofcontents[hideallsubsections]}

\section{Introduction}
\frame[shrink=10]{\tableofcontents[currentsection,hideothersubsections]}

\subsection{Background and Problem}
\subsection{Research Goals and Questions}
\subsection{Relevance and Significance}
% Other subsections here

\section{Existing Research}
\frame[shrink=10]{\tableofcontents[currentsection,hideothersubsections]}

\subsection{Information Systems Success}
\subsection{Free/Libre and Open Source Software (FLOSS)}
\subsection{The Success of FLOSS}
% Other subsections here

\section{Methodology}
\frame[shrink=10]{\tableofcontents[currentsection,hideothersubsections]}

\subsection{Research Design}
\subsection{Measurement of Variables}
\subsection{Data Analysis}
% Other subsections here

\section{Results}
\frame[shrink=10]{\tableofcontents[currentsection,hideothersubsections]}

\subsection{Research Workflow: Reproducible Research Approach}
\subsection{Design of Research Software}
\subsection{Reformulated Hypotheses}
% Other subsections here

\section{Conclusions}
\frame[shrink=10]{\tableofcontents[currentsection,hideothersubsections]}

\subsection{Discussion}
\subsection{Implications}
\subsection{Limitations}
\subsection{Future Research}
\subsection{Summary}

\end{document}