1

A minimum working example on Overleaf of my code looks like this:

\documentclass[11pt]{article}

\usepackage[margin=0.5in]{geometry} \usepackage[utf8x]{inputenc} \usepackage{booktabs} \usepackage{tabularx} \usepackage{threeparttable} \usepackage{caption} \usepackage{graphicx} \usepackage{verbatim} \usepackage{hyperref} \usepackage{amsmath}

\title{Title} \date{\today}

\begin{document}

\begin{table}[!h] \centering \captionsetup{skip=1.5pt} \caption{Tablename} \scalebox{.8}{ \begin{threeparttable} \begin{tabular}{lccccccc} \midrule\midrule\addlinespace & \multicolumn{4}{c}{\textit{Outcome}} \ \cmidrule{2-5} & (1) & (2) & (3) & (4) \ \midrule\addlinespace Panel A: \ \midrule\addlinespace \input{file_1.tex} \addlinespace\midrule\addlinespace \end{tabular} \begin{tablenotes}[flushleft] \item \textit{Notes:} Surveillance capacity panel above/below median dummy. Events are carried out by non-governmental actors. Observation at the prefecture - semiyear level. \end{tablenotes} \end{threeparttable} } \end{table}

\end{document}

where file_1.tex contains:

Variable       &       1.283** &       1.474***&       0.296   &       0.369   \\
                    &     (0.531)   &     (0.551)   &     (2.610)   &     (2.528)   \\

For some reason, this same code (with files placed in the same folder etc.) does not work when I try running it with TeXShop on my computer. Specifically, the console produces these logs:

This is pdfTeX, Version 3.14159265-2.6-1.40.21 (TeX Live 2020) (preloaded format=pdflatex)
 restricted \write18 enabled.
entering extended mode
(./filename.tex
LaTeX2e <2020-10-01> patch level 4
L3 programming layer <2021-02-18>
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/base/article.cls
Document Class: article 2020/04/10 v1.4m Standard LaTeX document class
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/base/size11.clo))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/geometry/geometry.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/graphics/keyval.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/iftex/ifvtex.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/iftex/iftex.sty)))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/base/inputenc.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/ucs/utf8x.def))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/ucs/ucs.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/ucs/data/uni-global.def))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/booktabs/booktabs.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/tools/tabularx.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/tools/array.sty))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/threeparttable/threeparttabl
e.sty) (/usr/local/texlive/2020basic/texmf-dist/tex/latex/caption/caption.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/caption/caption3.sty))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/graphics/graphicx.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/graphics/graphics.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/graphics/trig.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/graphics-cfg/graphics.cfg)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/graphics-def/pdftex.def)))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/tools/verbatim.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/hyperref/hyperref.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/ltxcmds/ltxcmds.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/pdftexcmds/pdftexcmds.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/infwarerr/infwarerr.sty))
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/kvsetkeys/kvsetkeys.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/kvdefinekeys/kvdefinekeys.
sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/pdfescape/pdfescape.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/hycolor/hycolor.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/letltxmacro/letltxmacro.sty)
 (/usr/local/texlive/2020basic/texmf-dist/tex/latex/auxhook/auxhook.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/kvoptions/kvoptions.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/hyperref/pd1enc.def)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/hyperref/hyperref-langpatche
s.def) (/usr/local/texlive/2020basic/texmf-dist/tex/generic/intcalc/intcalc.sty
) (/usr/local/texlive/2020basic/texmf-dist/tex/generic/etexcmds/etexcmds.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/hyperref/puenc.def)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/url/url.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/bitset/bitset.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/bigintcalc/bigintcalc.sty)
) (/usr/local/texlive/2020basic/texmf-dist/tex/latex/base/atbegshi-ltx.sty))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/hyperref/hpdftex.def
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/base/atveryend-ltx.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/rerunfilecheck/rerunfilechec
k.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/uniquecounter/uniquecounte
r.sty))) (/usr/local/texlive/2020basic/texmf-dist/tex/latex/amsmath/amsmath.sty
For additional information on amsmath, use the `?' option.
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/amsmath/amstext.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/amsmath/amsgen.sty))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/amsmath/amsbsy.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/amsmath/amsopn.sty))
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/l3backend/l3backend-pdftex.d
ef)
No file filename.aux.
*geometry* driver: auto-detecting
*geometry* detected driver: pdftex
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/ucs/ucsencs.def)
(/usr/local/texlive/2020basic/texmf-dist/tex/context/base/mkii/supp-pdf.mkii
[Loading MPS to PDF converter (version 2006.09.02).]
)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/epstopdf-pkg/epstopdf-base.s
ty (/usr/local/texlive/2020basic/texmf-dist/tex/latex/grfext/grfext.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg
)) (/usr/local/texlive/2020basic/texmf-dist/tex/latex/hyperref/nameref.sty
(/usr/local/texlive/2020basic/texmf-dist/tex/latex/refcount/refcount.sty)
(/usr/local/texlive/2020basic/texmf-dist/tex/generic/gettitlestring/gettitlestr
ing.sty)) (./file_1.tex)
./filename.tex:39: Misplaced \noalign.
\addlinespace ->\noalign 
                         {\ifnum 0=`}\fi \@ifnextchar [{\@addspace }{\@addsp...
l.39    }

Oddly enough, directly copying and pasting the contents of file_1.tex in place of the \input produces the intended output on both Overleaf and TeXShop, which goes against my understanding of how input works. It's unfortunately not practical to copy and paste everything for the project that I am working on, given the number of instances in which input occurs. Finally, this same code was also working in TeXShop a few days ago, but I've done a few things in the meantime and I'm not sure what exactly broke the process down -- these include updating files with tlmgr as well as doing a fresh install of threeparttable and ucs (for utf8x) when the .sty for these packages apparently could not be found.

I'm a bit lost as to figuring out how this might have happened, and would appreciate any help!

  • 2
    unrelated to the question but avoid doing this \scalebox{.8}{ applying scaling to tables produces font and rules inconsistent with the rest of the document. – David Carlisle Mar 29 '21 at 19:25
  • @PhelypeOleinik yes, that fixed my problem - I'm guessing it was the same update that caused the issue. Thanks! – Reliably Sourced Mar 29 '21 at 19:47

0 Answers0