[Tex/LaTex] How to change table numbers in the title

counterstables

\documentclass{article}
\usepackage{booktabs}
\usepackage{dcolumn}

\begin{document}
\setcounter{page}{3}
% Table generated by Excel2LaTeX from sheet 'nipo'
\begin{table}[htbp]
\centering
\caption{Statistics of Initial Public Offering}
\begin{tabular}{rrr}
\toprule
    Year  & Frequency & \% \\
\midrule
1975  & 10    & 0,1 \\
1976  & 27    & 0,3 \\
1977  & 17    & 0,2 \\
1978  & 21    & 0,3 \\
1979  & 47    & 0,6 \\
1980  & 69    & 0,8 \\
1981  & 183   & 2,2 \\
1982  & 80    & 1,0 \\
1983  & 524   & 6,4 \\
1984  & 219   & 2,7 \\
1985  & 258   & 3,1 \\
1986  & 523   & 6,3 \\
1987  & 383   & 4,6 \\
1988  & 161   & 2,0 \\
1989  & 161   & 2,0 \\
1990  & 146   & 1,8 \\
1991  & 334   & 4,1 \\
1992  & 459   & 5,6 \\
1993  & 557   & 6,8 \\
1994  & 457   & 5,5 \\
1995  & 479   & 5,8 \\
1996  & 635   & 7,7 \\
1997  & 443   & 5,4 \\
1998  & 273   & 3,3 \\
1999  & 401   & 4,9 \\
2000  & 340   & 4,1 \\
2001  & 83    & 1,0 \\
2002  & 68    & 0,8 \\
2003  & 65    & 0,8 \\
2004  & 179   & 2,2 \\
2005  & 180   & 2,2 \\
2006  & 191   & 2,3 \\
2007  & 236   & 2,9 \\
2008  & 29    & 0,4 \\

Sum   & 8238  & 100,0 \\
N     & 34    &  \\
\bottomrule
\end{tabular}%
\label{tab:addlabel}%
\end{table}%

\end{document}

How do you change the "Table 1" in the title to example "Table 2" or "Panel A" or something else?

I'm very new to producing LaTex tables, and I realize that the answer to my question is probably very simple.

Best Answer

\documentclass{article}
\usepackage{booktabs}
\usepackage{dcolumn}

\begin{document}
\setcounter{page}{3}
% Table generated by Excel2LaTeX from sheet 'nipo'
\setcounter{table}{1}
\renewcommand{\tablename}{Panel} % Set the tablename to Panel, instead of Table
\renewcommand{\thetable}{\Alph{table}} % Setting the table number output to letters 
\begin{table}[htbp]
\centering
\caption{Statistics of Initial Public Offering}
\begin{tabular}{rrr}
\toprule
    Year  & Frequency & \% \\
\midrule
1975  & 10    & 0,1 \\
1976  & 27    & 0,3 \\
1977  & 17    & 0,2 \\
1978  & 21    & 0,3 \\
1979  & 47    & 0,6 \\
1980  & 69    & 0,8 \\
1981  & 183   & 2,2 \\
1982  & 80    & 1,0 \\
1983  & 524   & 6,4 \\
1984  & 219   & 2,7 \\
1985  & 258   & 3,1 \\
1986  & 523   & 6,3 \\
1987  & 383   & 4,6 \\
1988  & 161   & 2,0 \\
1989  & 161   & 2,0 \\
1990  & 146   & 1,8 \\
1991  & 334   & 4,1 \\
1992  & 459   & 5,6 \\
1993  & 557   & 6,8 \\
1994  & 457   & 5,5 \\
1995  & 479   & 5,8 \\
1996  & 635   & 7,7 \\
1997  & 443   & 5,4 \\
1998  & 273   & 3,3 \\
1999  & 401   & 4,9 \\
2000  & 340   & 4,1 \\
2001  & 83    & 1,0 \\
2002  & 68    & 0,8 \\
2003  & 65    & 0,8 \\
2004  & 179   & 2,2 \\
2005  & 180   & 2,2 \\
2006  & 191   & 2,3 \\
2007  & 236   & 2,9 \\
2008  & 29    & 0,4 \\

Sum   & 8238  & 100,0 \\
N     & 34    &  \\
\bottomrule
\end{tabular}%
\label{tab:addlabel}%
\end{table}%

\end{document}

Explanation

Each time \begin{table} is called, it advances the table number by 1, so if the first table should get the number 2 actually, the table number must be initially set to 1, this is done by \setcounter{table}{1}.

The screen shot contains only the upper part of the table.

enter image description here

Related Question