[英]Parse Python Output in OrgMode to a table
我現在嘗試了一個小時,但沒有得到預期的結果,所以我需要在這里問您:
實際上,我嘗試通過orgmode將python輸出解析為表:
#+begin_src python :session :results output table :exports results
print("|Example|")
print("|--------|")
print("|One example entry|")
#+end_src
當我將緩沖區導出到pdf / html時,我希望有一張表。
但是,這不會發生。
誰能修復我的代碼並告訴我,為什么我的代碼不起作用?
提前致謝!
將raw
添加到您的:results
標頭參數中:
#+begin_src python :session :results output table raw :exports results
print("|Example|")
print("|--------|")
print("|One example entry|")
#+end_src
從文檔中 :
raw
結果被解釋為原始Org模式代碼,並直接插入到緩沖區中。 如果結果看起來像一張桌子,它們將按組織模式進行對齊。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.