Tabular data in reply to a post

  • Thread starter gmax137
  • Start date
7 replies · 1K views · last reply
Science Advisor
Education Advisor
Messages
3,215
Reaction score
3,849
I wanted to include a table of values in a reply. Is this possible? I had a table in Word; when I cut & pasted into the PF reply the formatting was lost completely.
Thanks
 
You can make a LaTeX table.

$$\begin{pmatrix}
1 & 2 & 3 & 4\\
a & b & c & d\\
x & y & z & w
\end{pmatrix}$$

You can format it within [code[/color]] tags:
Code:
here           spaces are conserved
which allows   tables, sort oft

Or convert the table to an image and include that.
 
You can build tables in Latex:
\begin{array}{|c|c|c|c|c|}
\hline \text{Column 1} & \text{Column 2}&\text{Column 3} &\text{Column 4} &\text{Column 5} \\
\hline 0&0&1&0&1\\
\hline 1 & 1 & 0 & 1 & 0\\
\hline
\end{array}
Right click on the figure to see the LaTeX.
 
  • Like
Likes   Reactions: Greg Bernhardt
LCKurtz said:
Right click on the figure to see the LaTeX.
Or click "Reply" to see the LaTeX. :smile:
 
What is weird is that I think I forgot to put either the ## or $$ tags in that post and it printed the latex anyway.
 
LCKurtz said:
What is weird is that I think I forgot to put either the ## or $$ tags in that post and it printed the latex anyway.
The system we have in place here at PF automatically recognizes certain environments, such as array (that you used) and bmatrix, pmatrix, and vmatrix, and maybe some others as well. You don't need to surround these known enviromments with [tex]or [itex]tags, or the easier to use (IMO) $$ or ## tags. <br /> Bracketed matrix (bmatrix)<br /> \begin{bmatrix} 1 & 0 \\ 0 & 1\end{bmatrix}<br /> Parenthesized matrix (pmatrix)<br /> \begin{pmatrix} 1 & 0 \\ 0 & 1\end{pmatrix}<br /> Vertical bars matrix (vmatrix)<br /> \begin{vmatrix} 1 & 0 \\ 0 & 1\end{vmatrix}[/itex][/tex]