\documentclass[12pt, a4paper]{article}
% Packages to use:
\usepackage{afterpage}
\usepackage{algorithm}
\usepackage{algorithmicx}
\usepackage{algpseudocode}
%\usepackage{apacite} % Didn't work
\usepackage{authblk}
\usepackage{amsmath}
\usepackage[title]{appendix}
\usepackage{amsfonts}
\usepackage{booktabs} % For \toprule, \midrule, \botrule
\usepackage[citestyle = apa, bibstyle=apa, maxbibnames=20]{biblatex}
\usepackage[font=small,labelfont=bf, hypcap=false]{caption} %\caption
\usepackage{chngcntr}
\usepackage{comment} %large comment
\usepackage{csquotes} % Include csquotes
\usepackage{csvsimple} % CSV to latex
\usepackage{diagbox}
\usepackage{enumitem}
\usepackage{eqnarray}
\usepackage{float} % for customizing caption position
\usepackage[T1]{fontenc} % Font encoding
\usepackage{geometry}
\usepackage{graphicx}
\usepackage[colorlinks=true, allcolors=blue]{hyperref}
\usepackage[none]{hyphenat} % Hyphonate
\usepackage{lineno} % Add the lineno package
\usepackage{listings}
\usepackage{lipsum}
\usepackage{longtable}
\usepackage{lscape}
\usepackage{mathrsfs}
\usepackage{multirow}
\usepackage{orcidlink}
\usepackage{pdflscape}
\usepackage[]{ragged2e}
\usepackage{subcaption}
\usepackage{setspace} % Customize line spacing
\usepackage{threeparttable} %For table footnotes
\usepackage{tabularray}
\usepackage{titlesec} % Redefine (sub)section numbering
% ---- References & citations ---
% Your reference file:
\addbibresource{refs.bib} % Your.bib file
%\bibliographystyle{apa}
% Set page size and margins
\geometry{a4paper,
top=1in,
bottom=1in,
left=1in,
right=1in,
marginparwidth=0.5in
}
\onehalfspacing % 1.5 line spacing
\titleformat{\section} % Redefine section numbering format
{\normalfont\Large\bfseries}{\thesection.}{1em}{}
% Line Numbering:
\renewcommand\linenumberfont{\normalfont\scriptsize\sffamily\color{blue}}
\linenumbers % Enable line numbering
\rightlinenumbers % Right-align; comment this line for left alignment.
% Define a new command for the fourth-level title.
\newcommand{\subsubsubsection}[1]{%
\vspace{\baselineskip} % Add some space
\noindent\textbf{#1\\}\quad % Adjust formatting as needed
}
% Change the position of the table caption above the table
\captionsetup[table]{position=top} % caption position for tables
% Define the unnumbered list
\makeatletter
\newenvironment{unlist}{%
\begin{list}{}{%
\setlength{\labelwidth}{0pt}%
\setlength{\labelsep}{0pt}%
\setlength{\leftmargin}{2em}%
\setlength{\itemindent}{-2em}%
\setlength{\topsep}{\medskipamount}%
\setlength{\itemsep}{3pt}%
}%
}{%
\end{list}%
}
\makeatother
% Suppress the warning about \@parboxrestore
%\pdfsuppresswarningpagegroup=1
%-------------------------------------------
% Paper Head
%-------------------------------------------
\title{\textbf{Title Here}}
\author[1, 2, *]{\small FirstName MiddleName LastName \orcidlink{xxxx-xxxx-xxxx-xxxx}}
\author[2]{\small FirstName MiddleName LastName}
\author[3]{\small FirstName MiddleName LastName \orcidlink{xxxx-xxxx-xxxx-xxxx}}
\affil[1]{\small{Name of the Department, Organization, City, State, Zip Code}}
\affil[2]{\small{Name of the Department, Organization, City, State, Zip Code}}
\affil[3]{\small{Name of the Department, Organization, City, State, Zip Code}}
\affil[*]{Corresponding author: \href{mailto:email@mail.com}{email@mail.com}; \href{mailto:email@mail.edu}{email@mail.edu}}
\date{}
\begin{document}
\newpage
\maketitle
\begin{abstract}
{Abstract here}
\end{abstract}
\noindent\textbf{Keywords}: 5-6 Keywords \\
\noindent\textbf{JEL Codes}: For economics articles only \hspace*{\fill}
\newpage
%-------------------------------------------
% Paper Body
%-------------------------------------------
\newpage
\section*{Highlights}
\begin{itemize}
\item Problem and solution
\item Method
\item Result 1 / Recommendations / Policy Implications
\item Result 2 / Recommendations / Policy Implications
\item Result 3 / Recommendations / Policy Implications / Conclusion
\end{itemize}
\newpage
\section{Introduction}
\begin{itemize}
\item \verb|\parencite[]{yang2024soil}| gives \parencite[]{yang2024soil}
\item \verb|\enquote{\$6 fee}| gives \enquote{\$6 fee}
\item \verb|\cite{yang2024soil}| gives \cite{yang2024soil}
\item \verb|\ref{tab:Demog}| gives \ref{tab:Demog}
\item \verb|\ref{Figure: Push}| gives \ref{Figure: Push}
\item \verb|\textcite{yang2024soil}| gives \textcite{yang2024soil}
\item First format table according to your need and use \href{https://www.tablesgenerator.com/}{table generator for latex} for efficient table building.
\end{itemize}
\begin{center}
\includegraphics[scale = 0.39, trim ={0.2cm, 0.2cm, 0.2cm, 0.2cm}, clip] {figures/Push.png}
\captionof{figure}{\small Caption of figure}
\label{Figure: Push}
\end{center}
\section{Theoretical Foundation}
\section{Method}
\subsection{Subsection}
\noindent The probability of ... was estimated as
\begin{multline}\label{Prob}
P_{BW}(rr' = 1|\textbf{X}_{itk}) = \beta_{{CAN}}{{CAN}_{itk}} + \\ \lambda_{{NSFP}}{{NSFP}_{itk}} +
\lambda_{{SFP}}{{SFP}_{itk}} + \epsilon_{{itk}}
\end{multline}
\noindent where the $\beta$s are ..., $\lambda$s are ..., and $\epsilon_{i}$ is stochastic error term.
\section{Results and Discussion}
\begin{longtable}[c]{rcccccc}
\caption{Demographics}
\label{tab:Demog} \\
\toprule
\multicolumn{1}{c}{\textbf{Demographic Variables}} & \textbf{N} & \textbf{Mean} & \textbf{Std. Dev.} & \textbf{Median} & \textbf{Min} & \textbf{Max} \\
\midrule
\multicolumn{1}{l}{Agricultural Cropland (Acres)} & 134 & 196.47 & 513.36 & 80 & 0 & 5,500 \\
\multicolumn{1}{l}{Rangeland (Acres)} & 224 & 475.01 & 529.19 & 282.50 & 0 & 3,000 \\
\multicolumn{1}{l}{Forests (Acres)} & 200 & 209.56 & 417.49 & 100 & 0 & 3,500\\
\bottomrule
\multicolumn{7}{l}{\textbf{Notes:}}\\
\multicolumn{7}{l}{.....} \\
\end{longtable}
\begin{table}[htbp]
\caption{Profits from TAVs producing 1,360 25-lb cartoons of tomato (benchmark yield) at various solar densities, panel heights, array types, geographical regions, and REAP compensation.}
\resizebox{\columnwidth}{!}{%
\begin{tabular}{rrclllllllllllcll}
\hline
\multicolumn{2}{r}{\textbf{\begin{tabular}[c]{@{}r@{}}Solar Proportion \\ (Total Panels) →\end{tabular}}} & \multicolumn{3}{c}{\textbf{0\% Solar}} & \multicolumn{3}{c}{\textbf{\begin{tabular}[c]{@{}c@{}}25 \% Solar \\ (177 Panels)\end{tabular}}} & \multicolumn{3}{c}{\textbf{\begin{tabular}[c]{@{}c@{}}50\% Solar \\ (413 Panels)\end{tabular}}} & \multicolumn{3}{c}{\textbf{\begin{tabular}[c]{@{}c@{}}75\% Solar \\ (590 Panels)\end{tabular}}} & \multicolumn{3}{c}{\textbf{\begin{tabular}[c]{@{}c@{}}100\% Solar \\ (885 Panels)\end{tabular}}} \\ \hline
\multicolumn{2}{r}{\textbf{Solar Panel Height (ft.) →}} & \multicolumn{3}{c}{\textbf{}} & \multicolumn{1}{c}{\textbf{4.6}} & \multicolumn{1}{c}{\textbf{6.4}} & \multicolumn{1}{c}{\textbf{8.2}} & \multicolumn{1}{c}{\textbf{4.6}} & \multicolumn{1}{c}{\textbf{6.4}} & \multicolumn{1}{c}{\textbf{8.2}} & \multicolumn{1}{c}{\textbf{4.6}} & \multicolumn{1}{c}{\textbf{6.4}} & \multicolumn{1}{c}{\textbf{8.2}} & \textbf{4.6} & \multicolumn{1}{c}{\textbf{6.4}} & \multicolumn{1}{c}{\textbf{8.2}} \\
\textbf{Regions ↓} & \textbf{Array ↓} & \multicolumn{15}{c}{\textbf{}} \\
\textbf{North} & \textbf{Fixed} & \multicolumn{3}{c}{9619.38} & 13054.61 & 13053.07 & 13050.18 & 17633.19 & 17629.59 & 17622.85 & 22212.66 & 22207.00 & 22196.42 & 26792.08 & 26784.36 & 26769.93 \\
\textbf{Central} & \textbf{Tracking} & \multicolumn{3}{c}{9619.38} & 13737.71 & 13736.58 & 13735.44 & 19227.70 & 19225.06 & 19222.42 & 24718.03 & 24713.87 & 24709.72 & 30208.38 & 30202.72 & 30197.05 \\
\textbf{Black Belt} & \textbf{Tracking} & \multicolumn{3}{c}{9619.38} & 13829.87 & 13828.74 & 13827.60 & 19442.68 & 19440.04 & 19437.40 & 25055.89 & 25051.73 & 25047.58 & 30669.06 & 30663.40 & 30657.73 \\
\textbf{South} & \textbf{Tracking} & \multicolumn{3}{c}{9619.38} & 13886.75 & 13885.62 & 13884.48 & 19575.40 & 19572.76 & 19570.12 & 25264.45 & 25260.29 & 25256.14 & 30953.46 & 30947.80 & 30942.13 \\ \hline
\end{tabular}%
}
\begin{tablenotes}[para, flushleft]
\item Notes: Profits from TAVs producing 1,360 25-lb cartoons of tomato (benchmark yield) at various .................................. \\
\end{tablenotes}
\label{tab:TAVProfit}
\end{table}
\begin{table*}[!ht]
\caption{Caption \label{Table: Labels}}
\tabcolsep=0pt
\begin{threeparttable}
\begin{tabular*}{\textwidth}{@{\extracolsep{\fill}}lccc@{\extracolsep{\fill}}}
\toprule
\multicolumn{1}{c}{Site } & \multicolumn{1}{c}{Marginal(\$)} & \multicolumn{1}{c}{$p > |z|$} & \multicolumn{1}{c}{95\% CI} \\
\multicolumn{1}{c}{Attributes} & \multicolumn{1}{c}{(Std. Err.)} & & \multicolumn{1}{c}{Lower, Upper} \\
\midrule
ABC & -0.96 (0.81) & 0.235 & -2.53, 0.62 \\
DEF & -0.71 (0.71) & 0.317 & -2.11, 0.69 \\
\bottomrule
\end{tabular*}
\begin{tablenotes}[para, flushleft]
\item Profits from TAVs producing 1,360 25-lb cartoons of tomato (benchmark yield) at various solar .................... \\
\end{tablenotes}
\end{threeparttable}
\end{table*}
\begin{table}[htbp]
\caption{Profit from SBAVs at benchmark yield and price}
%\tabcolsep=0pt
%\begin{threeparttable}
\resizebox{\columnwidth}{!}{%
\begin{tabular}{@{}lccllllllllllll@{}}
\toprule
\multicolumn{1}{c}{} & \multicolumn{2}{c}{Solar Proportion →} & \multicolumn{3}{c}{25\% Solar (177 Panels)} & \multicolumn{3}{c}{50\% Solar (413 Panels)} & \multicolumn{3}{c}{75\% Solar (590 Panels)} & \multicolumn{3}{c}{100\% Solar (885 Panels)} \\ \midrule
& \multicolumn{2}{c}{Solar Panel Height (ft.) →} & \multicolumn{1}{c}{4.6} & \multicolumn{1}{c}{6.4} & \multicolumn{1}{c}{8.2} & \multicolumn{1}{c}{4.6} & \multicolumn{1}{c}{6.4} & \multicolumn{1}{c}{8.2} & \multicolumn{1}{c}{4.6} & \multicolumn{1}{c}{6.4} & \multicolumn{1}{c}{8.2} & \multicolumn{1}{c}{4.6} & \multicolumn{1}{c}{6.4} & \multicolumn{1}{c}{8.2} \\
\midrule
REAP ↓ & Regions ↓ & Array ↓ & \multicolumn{12}{c}{Profit from SBAV with given specifications ↓} \\
\midrule
50\% & North & Fixed & 13,190 & 12,690 & 11,756 & 16,186 & 15,020 & 12,840 & 19,184 & 17,352 & 13,926 & 22,181 & 19,683 & 15,011 \\
50\% & South & Tracking & 14,211 & 13,845 & 13,478 & 18,570 & 17,715 & 16,859 & 22,930 & 21,586 & 20,241 & 27,289 & 25,456 & 23,623 \\ \midrule
25\% & Black Belt & Tracking & 10,537 & 9,781 & 9,025 & 9,997 & 8,233 & 6,468 & 9,458 & 6,685 & 3,912 & 8,919 & 5,138 & 1,356 \\
25\% & South & Tracking & 10,626 & 9,870 & 9,113 & 10,204 & 8,439 & 6,675 & 9,782 & 7,009 & 4,236 & 9,361 & 5,579 & 1,798 \\ \bottomrule
\end{tabular}%
}
\begin{tablenotes}[para, flushleft]
\item Note: Benchmark profit from SBAV producing 3,075 4-quart buckets of strawberries (benchmark yield) per acre. Source: Authors. \\
\end{tablenotes}
%\end{threeparttable}
\label{tab:SBAVProfit}
\end{table}
\newpage
\printbibliography
\newpage
%-------------------------------------------
% Appendix
%-------------------------------------------
\renewcommand\theequation{\Alph{section}\arabic{equation}} %Redefine equation numbering format
\counterwithin*{equation}{section} % Number equations within sections
\renewcommand\thefigure{\Alph{section}\arabic{figure}} % Redefine equation numbering format
\counterwithin*{figure}{section} % Number equations within sections
\renewcommand\thetable{\Alph{section}\arabic{table}} % Redefine equation numbering format
\counterwithin*{table}{section} % Number equations within sections
\section{Publications in Table}
\thispagestyle{empty}
\newgeometry{left=0.25cm,right=0.25cm,top=0.25cm,bottom=0.25cm}
\begin{landscape}
\begin{longtable}%{|*{5}{p{0.19\textwidth}|}}
{|p{0.20\textwidth}|p{0.20\textwidth}|p{0.30\textwidth}|p{0.30\textwidth}|p{0.30\textwidth}|} \hline
\textbf{Citation} & \textbf{Dependent Variable} & \textbf{Independent Variables} & \textbf{Method} & \textbf{Remarks} \\ \hline \endfirsthead
\textbf{Citation} & \textbf{Dependent Variable} & \textbf{Independent Variables} & \textbf{Method} & \textbf{Remarks} \\ \hline \endhead
Row 1, Col 1 & Row 1, Col 2 & Row 1, Col 3 & Row 1, Col 4 & Row 1, Col 5 \\ \hline
Row 2, Col 1 & Row 2, Col 2 & Row 2, Col 3 & Row 2, Col 4 & Row 2, Col 5 \\ \hline
Row 3, Col 1 & Row 3, Col 2 & Row 3, Col 3 & Row 3, Col 4 & Row 3, Col 5 \\ \hline
\end{longtable}
\end{landscape}
\newpage
\begin{appendices}
\section*{Appendix A: }
\section*{Appendix B:}
\end{appendices}
\end{document}