Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Trouble with setting up markstat to PDF

    Hi everyone! I am struggling to properly setup markstat by German Rodriguez to generate PDF file from my analysis. I followed his instructions carefully, installed both Pandoc and MiKTex, as well as stata.sty files. Despite it when I run the command on a test file, the program gets stuck on a "Running Latex" phase; the cmd console opens up, Stata freezes and I have to shut down the cmd. Stata produces this line:

    Running Latex
    C:\Users\cwiek\AppData\Local\Programs\MiKTeX\mikte x\bin\x64\pdflatex.exe
    This is pdfTeX, Version 3.141592653-2.6-1.40.26 (MiKTeX 24.4) (preloaded format=pdflatex.fmt)
    restricted \write18 enabled.
    entering extended mode
    (test.tex
    LaTeX2e <2024-11-01>
    L3 programming layer <2024-11-02>
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/base\article.cls
    Document Class: article 2024/06/29 v1.4n Standard LaTeX document class
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/base\size10.clo))
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/xcolor\xcolor.sty
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/graphics-cfg\color.cfg)

    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/graphics-def\pdftex.def
    )
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/graphics\mathcolor.ltx)
    ) (stata.sty
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/base\alltt.sty)
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/tools\calc.sty)
    (C:\Users\cwiek\AppData\Local\Programs\MiKTeX\tex/latex/base\ifthen.sty)
    ! Undefined control sequence.
    l.51 \ifluatex

    ? ^C
    file test.pdf not found
    I couldn't find any solution to this, has anyone had such problem and knows the way around?


  • #2
    I would start by confirming that you can complete each step outside of Stata, just to be sure if it's a markstat / Stata problem or a more basic problem with your Pandoc / MikTeX setup.

    So create a very very simple tex file, make sure you can compile it, then check that Pandoc is handling markdown -> tex -> PDF correctly, then add stata.sty to the mix, etc.

    Once you are sure that everything is working outside of Stata, it should be easier to isolate any problem with markstat / Stata per se.

    My guess from your log-file is that there is a problem with your LaTex setup, and markstata / Stata are not the issue:

    ! Undefined control sequence.
    l.51 \ifluatex

    Comment


    • #3
      Jakub Cwieka please report back with your results in case future Statalisters have a similar issue.

      Comment

      Working...
      X