npround (seems to) destroy rules for caption in table

I'm struggling with this one. In essence, I would like to place the caption above the table but also to have the 'Table 1' appear at the beginning and on the same line as the caption. Finally, I would like to have that the caption is left justified (as usual) instead of being centred (as now).

Now, normally, I know how to do these things, but the inclusion of the numprint package seems to make all my rule of thumbs useless: regardless of where I put the \begin{center} \end{center}, the caption is centred. The caption also always appears one line below the 'Table 1' text.

\usepackage{numprint}
\npdecimalsign{.}
\nprounddigits{1}
\begin{table}[ht]
\centering
\begin{tabular}{|r| n{3}{1}  n{3}{1} l| n{3}{1} n{3}{1} l| n{3}{1} n{3}{1} l|}
\hline
& \multicolumn{2}{c|}{\textbf{e1}}&\multicolumn{2}{ c| }{\textbf{e2}} &\multicolumn{2}{c|}{\textbf{e3}}\\
\hline
\textbf{e1}&&&1.712682&(0.9381452)&2.768738&(1.646461)\\
\textbf{e2}&0.5613594&(0.4711274)&&&1.959158&(1.001164)\\
\textbf{e3}&185.9336662&(2.1302318)&140.417800&(1.797353)&&\\
\hline
\end{tabular}
\label{tab:tab1}
\caption{this data table}
\end{table}
\npnoround


Not sure if this is what you mean... I place a textwidth rule, to show the margin extent, and create a command \leftcaption to place the caption there. I had no problems with the word "Table 1" and the caption being on the different lines.

\documentclass{article}

\usepackage{calc}
\usepackage{numprint}
\newcommand\leftcaption[1]{\caption{#1\protect\rule{\textwidth-\widthof{#1}}{0in}}}
\begin{document}

\noindent\rule{\textwidth}{.1ex}

\npdecimalsign{.}
\nprounddigits{1}
\begin{table}[ht]
\leftcaption{this data table}
\centering
\begin{tabular}{|r| n{3}{1}  n{3}{1} l| n{3}{1} n{3}{1} l| n{3}{1} n{3}{1} l|}
\hline
& \multicolumn{2}{c|}{\textbf{e1}}&\multicolumn{2}{ c| }{\textbf{e2}} &\multicolumn{2}{c|}{\textbf{e3}}\\
\hline
\textbf{e1}&&&1.712682&(0.9381452)&2.768738&(1.646461)\\
\textbf{e2}&0.5613594&(0.4711274)&&&1.959158&(1.001164)\\
\textbf{e3}&185.9336662&(2.1302318)&140.417800&(1.797353)&&\\
\hline
\end{tabular}
\label{tab:tab1}
\end{table}
\npnoround

\end{document}


• do you think the table1 bein on a different line could be causes by the imsart env? If yes, would you know how I can switch this particular behavior off? – user1933 Jun 24 '13 at 17:32
• @user1933 I can't say I understand your questions. I can only say that the above code I provide compiles on my system using pdflatex. The fact that your "Table 1" and its caption appeared on different lines when you presented your original question is disconcerting. – Steven B. Segletes Jun 24 '13 at 17:35
• sorry. So your code runs, but it now prints the caption on the left of the table (still below the Table 1 titles). Would you know how to remove the 'Table 1' altogether? – user1933 Jun 24 '13 at 17:42
• @user1933 Well, you could say \newcommand\leftcaption[1]{#1\protect\rule{\textwidth-\widthof{#1}}{0in}} instead of the way I show it in my example. However, if you don't use the \caption feature, it will not show up in the list of tables. – Steven B. Segletes Jun 24 '13 at 17:46
• @user1933 Excellent. Glad to have spurred your thoughts. – Steven B. Segletes Jun 24 '13 at 17:49