The new forums will be named Coin Return (based on the most recent vote)! You can check on the status and timeline of the transition to the new forums here.
The Guiding Principles and New Rules document is now in effect.

Latex Code?

DJ-99DJ-99 Registered User regular
edited March 2007 in Help / Advice Forum
I have this Latex code for a table. Unfortunately, I have no idea how to get the code to print in a usable format, because I don't really know what Latex is.
{
\def\sep{0.5em}
\def\fns{\footnotesize}
\def\onepc{$^{\ast\ast}$} \def\fivepc{$^{\ast}$}
\def\tenpc{$^{\dag}$}
\def\legend{\multicolumn{2}{l}{\footnotesize{Significance levels
:\hspace{1em} $\dag$ : 10\% \hspace{1em}
$\ast$ : 5\% \hspace{1em} $\ast\ast$ : 1\% \normalsize}}}
\begin{table}[htbp]\centering
 \caption{Estimation results : regress
\label{tabresult regress}}
\begin{tabular}{l c  }\hline\hline 
\multicolumn{1}{c}
{\textbf{Variable}}
 & \textbf{Coefficient} \\& \fns{(Std. Err.)} \\ \hline
gdp  & 0.000\fivepc \\ & \fns{(0.000)}\\[\sep]
gdpgrowth  & -1.611\fivepc \\ & \fns{(0.706)}\\[\sep]
inflation  & -0.332\tenpc \\ & \fns{(0.185)}\\[\sep]
Intercept  & 85.761\onepc \\ & \fns{(5.290)}\\[\sep]
\hline
\multicolumn{2}{c}{}\\
\hline N & \multicolumn{1}{c}{67}\\
R$^{2}$ & \multicolumn{1}{c}{0.289}\\
F $ _{(3,63)}$ & \multicolumn{1}{c}{8.531}\\
\hline
\end{tabular}
\end{table}
}

What do I do to make this table look like a table, and not code?

Thanks for any help.

DJ-99 on

Posts

  • edited March 2007
    This content has been removed.

  • RocketScienceRocketScience Registered User regular
    edited March 2007
    LaTeX is used for typesetting documents, it works kind of like HTML. It's best for writing reports with lots of equations in them. Unless you're going to be doing a lot of that I wouldn't really bother with it.

    You're going to need to install a TeX editor and compiler. If you've got a Mac there's a good all in one thing called TeXShop

    For Windows, I've had the most luck with MikTeX, and used WinEdt until the shareware runs out. I think you also need ghostscript.

    If you manage to get that installed with all the necessary packages, you have to start a file with (from memory)
    \documentclass{article}
    \begin{document}

    ...

    \end{document}


    Paste your table in the middle of that, hit a button and it should spit out a PDF of a nicely typeset table.

    There are lots of online guides for learning the syntax, but If you want a quick fix hopefully someone here has already got it installed and can just generate the PDF/DVI file for you.

    RocketScience on
  • edited March 2007
    This content has been removed.

  • DJ-99DJ-99 Registered User regular
    edited March 2007
    mcdermott wrote: »
    Fuck, if you just need this table and aren't wanting to actually learn/install LaTeX in general, I could just generate a PDF for you. In fact, I went ahead and did. Give me a second to put it somewhere you can access it, and I'll post a link.

    Here ya go...

    Of course, if you're going to be running into more of these you may want to fuck around and get LaTeX installed.

    EDIT: And yes, TexShop is nice. LaTeX Equation Editor is better if that's all you need to do, though.

    Thanks a lot for that PDF. That's all I needed for today, although in the future I need to make a bunch of them.

    What program did you use to generate that? Is it available for free off the internet?

    But yeah, I don't care about actually learning about Latex, just generating tables just like that one given pre-existing code.

    I guess I have Miktex as part of my school's software, and I have the Yap .dvi viewer. How do I go about creating a .dvi from a .tex file?

    DJ-99 on
  • edited March 2007
    This content has been removed.

  • DJ-99DJ-99 Registered User regular
    edited March 2007
    mcdermott wrote: »
    DJ-99 wrote: »
    mcdermott wrote: »
    Fuck, if you just need this table and aren't wanting to actually learn/install LaTeX in general, I could just generate a PDF for you. In fact, I went ahead and did. Give me a second to put it somewhere you can access it, and I'll post a link.

    Here ya go...

    Of course, if you're going to be running into more of these you may want to fuck around and get LaTeX installed.

    EDIT: And yes, TexShop is nice. LaTeX Equation Editor is better if that's all you need to do, though.

    Thanks a lot for that PDF. That's all I needed for today, although in the future I need to make a bunch of them.

    What program did you use to generate that? Is it available for free off the internet?

    But yeah, I don't care about actually learning about Latex, just generating tables just like that one given pre-existing code.

    I guess I have Miktex as part of my school's software, and I have the Yap .dvi viewer. How do I go about creating a .dvi from a .tex file?

    *shrug* Hell if I know...I used TexShop (I'm on a Mac). I'm guessing it's off to do some reading for you (those two links I gave higher up ought to be a good start).

    All right, I have TexShop. So I have the code in the editor, and...what do I do next? I could probably figure it out but I gotta go to class, and if you could tell me really easily that would be great. If not I'll figure it out this afternoon. Thanks a lot for all your help.

    DJ-99 on
Sign In or Register to comment.