[O] Export properties as (csv) table
Dear all, Let's say I have the following entries and their associated properties. Is there an easy way to export these information as csv formated table? * Marc, Mart :Mart_Marc:: :PROPERTIES: :name: Marc, Mart :typ: diss :empirisch: ja :status: angemeldet :END: * Marc, Mart2 :Mart_Marc2: :PROPERTIES: :name: Marc, Mart2 :typ: diss :empirisch: ja :status: angemeldet :END: The final csv table would look like this: name, typ, empirisch, status Mart, Marc; diss; ja; angemeldet Mart2, Marc; diss; ja; angemeldet I played around with dynamic blocks and spent some time trying to understand the property API but since my elips skills are very (very) limited to no avail... Thanks, Bernd
Re: [O] Export properties as (csv) table
On 04.09.2012 21:26, Nick Dokos wrote: [...] Perhaps a combination of a columnview dblock[fn:1] to produce a table and then a radio table with a translation function[fn:2]: [...] Thanks, Nick! Works like a charm! Bernd
Re: [O] Running org-babel-tangle and/or org-export-as-pdf in Emacs batch mode
On 11.04.2012 16:14, Eric Schulte wrote: [...] Hi Bernd, I can't recreate this hanging issue locally (I don't have access to a windows box). This sounds like an ESS issue to me since ESS seems to be the hanging process. Perhaps a good first step would be to try to evaluate (require 'ess) (R) in a batch Emacs session without Emacs hanging. Once this is working then it should be clear how to run ESS sessions from code blocks. Eric, Thanks for your answer! I am not sure if you had the following in mind but it again causes Emacs to hang: emacs -batch -l e:/config/.emacs --visit test.R --eval=(progn (require 'ess) (R) (ess-eval-buffer)) This is test.R test.R -- pdf(testplot.pdf) hist(rnorm(100)) dev.off() test.R -- I wrote another email to the ESS list, which is currently awaiting moderator approval. However, I am still wondering that I seem to be the first person to stumble upon this problem... Thanks, Bernd
[O] Running org-babel-tangle and/or org-export-as-pdf in Emacs batch mode
Dear all, I am not sure if this an orgmode-, an ESS- or an Emacs-related question. I am working on an orgmode-file with embedded R code. Since I am using a build tool called waf, I would like to call Emacs from command line like this: emacs --batch --load e:/config/.emacs --visit test.org --funcall org-export-as-pdf (or call org-babel-tangle) However, it stops with Type C-h m for help on ESS version 12.03. If I remove the R part (#+begin_src etc.), everything works as expected. This is my (hopefully) minimal example, the command line output and the orgmode related infos. Thanks, Bernd ---minimal example: test.org--- # Babel settings #+PROPERTY: session *R* #+PROPERTY: tangle test.R #+PROPERTY: comments yes #+PROPERTY: results output #+PROPERTY: exports both #+BEAMER_FRAME_LEVEL: 1 #+startup: beamer #+LaTeX_CLASS: beamer #+LaTeX_CLASS_OPTIONS: [bigger] #+latex_header: %%\modebeamer{\usetheme{Madrid}} * test heading lsals #+begin_src R 1+1 #+end_src ---minimal example: text.org--- ---cl-output-- wmx336@fi-weiss-50 /cygdrive/e/projects/software/ps2012r_intro/test $ emacs --batch --load e:/config/.emacs --visit test.org --funcall org-export-as-pdf customizing GNU Emacs customizing GNU Emacs for Win 7 Loading e:/config/.recentf... Cleaning up the recentf list... Cleaning up the recentf list...done (0 removed) Loading tex-mik... Ido mode enabled Source file `d:/programme/emacs/site-lisp/org-mode/contrib/lisp/org-contacts.el' newer than byte-compiled file Ido mode enabled Loading d:/programme/emacs/site-lisp/color-theme/themes/color-theme-example.el (source)... Loading d:/programme/emacs/site-lisp/color-theme/themes/color-theme-example.elc... Loading d:/programme/emacs/site-lisp/color-theme/themes/color-theme-library.el (source)... Loading d:/programme/emacs/site-lisp/color-theme/themes/color-theme-library.elc... Loading d:/programme/emacs/site-lisp/color-theme/themes/color-theme-tango.el (source)... Loading d:/programme/emacs/site-lisp/color-theme/themes/color-theme-tango.elc... [yas] warning: keybinding (rinari-minor-mode-map . C-c C-c C-r) invalid for snippet #+begin_src R...#+end_ since keymap rinari-minor-mode-map does not (yet?) exist. [yas] warning: keybinding (rinari-minor-mode-map . C-c C-c C-b) invalid for snippet beamer_envargs since keymap rinari-minor-mode-map does not (yet?) exist. Loading d:/programme/emacs/site-lisp/graphviz-dot-mode.el (source)... OVERVIEW Local Ispell dictionary set to nil Starting new Ispell process [default] ... File mode specification error: (error d:\\programme\\Aspell\\bin\\aspell.exe did not output version line) Loading vc-git... Exporting to PDF... Exporting to LaTeX... Local Ispell dictionary set to nil Automatic display of crossref information was turned on Applying style hooks... Applying style hooks... done Local Ispell dictionary set to nil Local Ispell dictionary set to nil executing R code block... Type C-h m for help on ESS version 12.03 ---cl-output-- ---org-related-infos--- Emacs : GNU Emacs 23.3.1 (i386-mingw-nt5.1.2600) of 2011-03-10 on 3249CTO Package: Org-mode version 7.8.06 (release_7.8.06.180.g22bfd) current state: == (setq org-export-preprocess-before-backend-specifics-hook '(org-inlinetask-export-handler) org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars) org-export-latex-listings t org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-agenda-custom-commands '((c conferences ((tags CONFERENCE)) ((org-tags-match-list-sublevels nil)) ((org-columns-default-format %DATE %LOCATION))) (d Upcoming deadlines agenda ((org-agenda-time-grid nil) (org-deadline-warning-days 365) (org-agenda-entry-types (quote (:deadline) (W Weekly Review ((agenda ((org-agenda-ndays 14))) (todo WRITING org-agenda-files '(e:/projects/habilitation/org/prHabilitation.org e:/projects/org/agendas/2011fall.org e:/projects/org/agendas/2011springterm.org e:/projects/org/agendas/SynRG.org e:/projects/org/agendas/capture.org e:/projects/org/agendas/d_2011a.org e:/projects/org/agendas/prDAAD-ipd-ma-divorce.org e:/projects/org/agendas/prDAAD-ma-simulation.org e:/projects/org/agendas/privat.org e:/projects/org/agendas/pu2012bbbook_basic_meta-analysis.org e:/projects/org/agendas/te2012sose.org e:/projects/org/agendas/te2012spring.org e:/projects/org/agendas/work.org) org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent) org-src-fontify-natively t org-babel-load-languages '((emacs-lisp . t) (maxima . t) (R . t) (python . t)
[O] [babel] Cannot use R and sh
Hi all, when using R and shell commands, the shell commands are sent to the R buffer. I guess this has something to do with the session argument?! # test.org # #+property: session *R* #+BEGIN_SRC R ## comment 1+1 #+END_SRC #+results: : 2 #+BEGIN_SRC sh ls -a #+END_SRC #+results: : Error: object 'a' not found # test.org # Thanks, Bernd Org-mode version 7.7 (release_7.7.393.g8caa)
Re: [O] [babel] Cannot use R and sh
On 20.10.2011 14:49, Nick Dokos wrote: [...] AFAIK, the syntax is (note the BABEL and the :session) #+BABEL: :session *R* With that, I can certainly reproduce what you get and it is indeed the global session that causes it. If you want a global session for all the other code blocks but want to override it for the single shell block, you can do: #+BEGIN_SRC sh :session *SH* ls -a #+END_SRC Thanks, Nick, for your reply! I hadn't thought about overriding the R session. Good idea! With respect to the #+BABEL... syntax, I vaguely remember that this is deprecated. The Org Mode Manual, however, (still) mentions both ways... http://orgmode.org/org.html#Header-arguments-in-Org_002dmode-properties. Again, thanks, Bernd
Re: [O] [babel] Specifying buffer-wide header arguments: #+property vs #+babel (was: Cannot use R and sh)
On 20.10.2011 14:58, Bernd Weiss wrote: [...] With respect to the #+BABEL... syntax, I vaguely remember that this is deprecated. The Org Mode Manual, however, (still) mentions both ways... http://orgmode.org/org.html#Header-arguments-in-Org_002dmode-properties. Earlier this year, Dan Davison wrote: Please note that it is possible to make an equivalent setting using #+PROPERTY: session *R* In fact, I suspect we are going to drop #+BABEL entirely, so please consider it deprecated and use this form instead. http://lists.gnu.org/archive/html/emacs-orgmode/2011-02/msg00672.html I am wondering if this statement still holds true? Bernd
Re: [O] [babel] Maxima code blocks do not work
Am 27.06.2011 04:34, schrieb Eric S Fraga: Bernd Weiss bernd.we...@uni-koeln.de writes: Dear all, The follwing Maxima code block does not work: #+begin_src maxima 1+1; #+end_src #+results: #+begin_example incorrect syntax: / is not a prefix operator incorrect syntax: GuM is not an infix operator parser: incomplete number; missing exponent? -- an error. To debug this try: debugmode(true); incorrect syntax: Too many )'s incorrect syntax: Premature termination of input at $. Maxima encountered a Lisp error: parser: end of file while scanning expression. Automatically continuing. To enable the Lisp debugger set *debugger-hook* to nil. #+end_example Strange. I don't get this at all. In fact, I get no output at all with your example. If I change the code to: Hi Eric, Thanks for your answer! #+begin_src maxima a: 1+1; print(a); #+end_src then I get: #+results: : 2 Package: Org-mode version 7.5 (release_7.5.435.gd3100) I am running a newer version of org than you are so maybe update? I am also on emacs 24. I updated org (again, now it's Org-mode version 7.5 (release_7.5.461.g6d18)), I switched to Emacs 24 but to no avail. I also tried to use the debugger but this does not seem to be an error... Debug on Error enabled globally executing Maxima code block... executing Maxima source code block maxima --very-quiet -r 'batchload(c:/Users/weiss/AppData/Local/Temp/babel-209000BH/maxima-20900VN1)$' nil Code block evaluation complete. I also realized that the 'error message' changes every time I try to run the code block: #+results: : incorrect syntax: / is not a prefix operator : incorrect syntax: aLH is not an infix operator : incorrect syntax: hCp is not an infix operator : incorrect syntax: Premature termination of input at $. : Maxima encountered a Lisp error: : parser: end of file while scanning expression. : Automatically continuing. : To enable the Lisp debugger set *debugger-hook* to nil. This message is 'related' (see lines 3 aLH is not an infix operator and 4 hCp is not an infix operator) to the following Maxima call (aLH/maxima-17716hCp): maxima --very-quiet -r 'batchload(c:/Users/weiss/AppData/Local/Temp/babel-17716aLH/maxima-17716hCp)$' nil Unfortunately, my elisp knowledge is too low to understand what's going on in ob-maxima.el. Is it a MS-Windows-thing ('/' vs '\')? To be honest, running Maxima in org in not so important for me. As long as R works, everything is fine :-) Thanks, Bernd
Re: [O] [babel] Maxima code blocks do not work
Am 27.06.2011 10:32, schrieb Eric S Fraga: Bernd Weiss bernd.we...@uni-koeln.de writes: [...] #+results: : incorrect syntax: / is not a prefix operator : incorrect syntax: aLH is not an infix operator : incorrect syntax: hCp is not an infix operator : incorrect syntax: Premature termination of input at $. : Maxima encountered a Lisp error: : parser: end of file while scanning expression. : Automatically continuing. : To enable the Lisp debugger set *debugger-hook* to nil. This message is 'related' (see lines 3 aLH is not an infix operator and 4 hCp is not an infix operator) to the following Maxima call (aLH/maxima-17716hCp): maxima --very-quiet -r 'batchload(c:/Users/weiss/AppData/Local/Temp/babel-17716aLH/maxima-17716hCp)$' nil The error messages look like maxima is trying to evaluate the actual string within double quotes! Unfortunately, my elisp knowledge is too low to understand what's going on in ob-maxima.el. Is it a MS-Windows-thing ('/' vs '\')? Good question. Has anybody else used maxima with org babel on Windows? I don't even have such a system to try... My guess would be that the shell command required to invoke maxima on Windows needs to be significantly different than what we are using here (which works on Linux). Then again, I've never really used Windows (beyond starting Word on somebody else's document on somebody else's machine... ;-) so I don't have a clue what Windows expects... Hi Eric, Again, thanks a lot for your help! Okay, it definitely is a Windows problem. If I run the following command in a cygwin shell, everything works as expected: maxima --very-quiet -r 'batchload(c:/Users/weiss/AppData/Local/Temp/babel-17716aLH/maxima-17716hCp)$' nil However, it does not work in a Windows shell. But this is no longer an org issue. Bernd
[O] [babel] Maxima code blocks do not work
Dear all, The follwing Maxima code block does not work: #+begin_src maxima 1+1; #+end_src #+results: #+begin_example incorrect syntax: / is not a prefix operator incorrect syntax: GuM is not an infix operator parser: incomplete number; missing exponent? -- an error. To debug this try: debugmode(true); incorrect syntax: Too many )'s incorrect syntax: Premature termination of input at $. Maxima encountered a Lisp error: parser: end of file while scanning expression. Automatically continuing. To enable the Lisp debugger set *debugger-hook* to nil. #+end_example Thanks, Bernd Emacs : GNU Emacs 23.3.1 (i386-mingw-nt6.1.7600) of 2011-03-10 on 3249CTO Package: Org-mode version 7.5 (release_7.5.435.gd3100) current state: == (setq org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars) org-export-latex-listings t org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-agenda-custom-commands '((c conferences ((tags CONFERENCE)) ((org-tags-match-list-sublevels nil)) ((org-columns-default-format %DATE %LOCATION))) (d Upcoming deadlines agenda ((org-agenda-time-grid nil) (org-deadline-warning-days 365) (org-agenda-entry-types (quote (:deadline ) (W Weekly Review ((agenda ((org-agenda-ndays 14))) (todo WRITING))) ) org-agenda-files '(e:/projects/org/agendas/) org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent) org-src-fontify-natively t org-babel-load-languages '((emacs-lisp . t) (maxima . t) (R . t) (python . t) (latex . t) (dot . t) (sh . t)) org-metaup-hook '(org-babel-load-in-session-maybe) org-after-todo-state-change-hook '(org-clock-out-if-current) org-babel-tangle-lang-exts '((latex . tex) (python . py) (emacs-lisp . el)) org-edit-src-content-indentation 0 org-export-blocks-postblock-hook '(org-exp-res/src-name-cleanup) org-export-latex-format-toc-function 'org-export-latex-format-toc-default org-tab-first-hook '(org-hide-block-toggle-maybe org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe) org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-confirm-shell-link-function 'yes-or-no-p org-export-first-hook '(org-beamer-initialize-open-trackers) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-export-latex-packages-alist '(( color) ( listings)) org-default-notes-file e:/projects/org/agendas/capture.org org-directory e:/projects/org/ org-babel-pre-tangle-hook '(save-buffer) org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-export-preprocess-before-normalizing-links-hook '(org-remove-file-link-modifiers) org-mode-hook '(org-mode-reftex-setup #[nil \300\301\302\303\304$\207 [org-add-hook change-major-mode-hook org-show-block-all append local] 5] #[nil \300\301\302\303\304$\207 [org-add-hook change-major-mode-hook org-babel-show-result-all append local] 5] org-babel-result-hide-spec org-babel-hide-all-hashes turn-on-org-cdlatex turn-on-auto-fill turn-on-font-lock turn-on-visual-line-mode) org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe) org-confirm-elisp-link-function 'yes-or-no-p org-export-interblocks '((lob org-babel-exp-lob-one-liners) (src org-babel-exp-inline-src-blocks)) org-enforce-todo-dependencies t org-occur-hook '(org-first-headline-recenter) org-from-is-user-regexp nil org-export-preprocess-before-selecting-backend-code-hook '(org-beamer-select-beamer-code) org-confirm-babel-evaluate nil org-hierarchical-checkbox-statistics nil org-src-tab-acts-natively t org-export-latex-final-hook '(org-beamer-amend-header org-beamer-fix-toc org-beamer-auto-fragile-frames org-beamer-place-default-actions-for-lists) org-metadown-hook '(org-babel-pop-to-session-maybe) org-export-blocks '((src org-babel-exp-src-block nil) (comment org-export-blocks-format-comment t) (ditaa org-export-blocks-format-ditaa nil) (dot org-export-blocks-format-dot nil)) )
[O] [bug] Symbol's function definition is void: when-let
Hi all, after updating to the most recent version of org-mode, I cannot longer export to LaTeX/PDF. It stops with Symbol's function definition is void: when-let, i.e. Fontifying org-src-fontification:emacs-lisp-mode... (regexps...) Symbol's function definition is void: when-let Everything works as expected when I go back in time (e.g. three commits), using Git's checkout HEAD^^^ . My current HEAD refers to commit 72c154e38e526b5f8bb5f200fb31bc6fec145ba6 Please find below the output of M-x org-submit-bug-report and backtrace (which I shortend a bit). Thanks for your help, Bernd Emacs : GNU Emacs 23.3.1 (i386-mingw-nt6.1.7600) of 2011-03-10 on 3249CTO Package: Org-mode version 7.5 (release_7.5.285.g72c1) current state: == (setq org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars) org-export-latex-listings t org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-agenda-custom-commands '((c conferences ((tags CONFERENCE)) ((org-tags-match-list-sublevels nil)) ((org-columns-default-format %DATE %LOCATION))) ) org-agenda-files '(e:/projects/org/article/p_UnemploymentIntentionChild.org e:/projects/org/lehre/2011springterm.org e:/projects/org/projects/prDAAD-ipd-ma-divorce.org e:/projects/org/projects/prDAAD-ma-simulation.org e:/projects/publicat/book/b2012meta-analyse/doc/b2010meta-analyse.org e:/projects/org/projects/prDFG-Scheidung.org e:/projects/org/article/ar2010dyad.org e:/projects/org/article/ar2010dr.org e:/projects/org/privat.org e:/projects/org/work.org) org-src-fontify-natively t org-babel-load-languages '((emacs-lisp . t) (R . t) (python . t) (latex . t) (dot . t) (sh . t)) org-metaup-hook '(org-babel-load-in-session-maybe) org-after-todo-state-change-hook '(org-clock-out-if-current) org-babel-tangle-lang-exts '((latex . tex) (python . py) (emacs-lisp . el)) org-edit-src-content-indentation 0 org-export-blocks-postblock-hook '(org-exp-res/src-name-cleanup) org-export-latex-format-toc-function 'org-export-latex-format-toc-default org-tab-first-hook '(org-hide-block-toggle-maybe org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe) org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-confirm-shell-link-function 'yes-or-no-p org-export-first-hook '(org-beamer-initialize-open-trackers) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-export-latex-packages-alist '(( color) ( listings)) org-default-notes-file e:/projects/org//notes.org org-directory e:/projects/org/ org-babel-pre-tangle-hook '(save-buffer) org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-export-latex-classes '((per-file-class \\documentclass{article}\n [NO-DEFAULT-PACKAGES]\n [EXTRA] (\\section{%s} . \\section*{%s}) (\\subsection{%s} . \\subsection*{%s}) (\\subsubsection{%s} . \\subsubsection*{%s}) (\\paragraph{%s} . \\paragraph*{%s}) (\\subparagraph{%s} . \\subparagraph*{%s})) (article \\documentclass[11pt]{article} (\\section{%s} . \\section*{%s}) (\\subsection{%s} . \\subsection*{%s}) (\\subsubsection{%s} . \\subsubsection*{%s}) (\\paragraph{%s} . \\paragraph*{%s}) (\\subparagraph{%s} . \\subparagraph*{%s})) (report \\documentclass[11pt]{report} (\\part{%s} . \\part*{%s}) (\\chapter{%s} . \\chapter*{%s}) (\\section{%s} . \\section*{%s}) (\\subsection{%s} . \\subsection*{%s}) (\\subsubsection{%s} . \\subsubsection*{%s})) (book \\documentclass[11pt]{book} (\\part{%s} . \\part*{%s}) (\\chapter{%s} . \\chapter*{%s}) (\\section{%s} . \\section*{%s}) (\\subsection{%s} . \\subsection*{%s}) (\\subsubsection{%s} . \\subsubsection*{%s})) (beamer \\documentclass{beamer} org-beamer-sectioning)) org-export-preprocess-before-normalizing-links-hook '(org-remove-file-link-modifiers) org-mode-hook '(org-mode-reftex-setup (lambda nil (org-add-hook (quote change-major-mode-hook) (quote org-show-block-all) (quote append) (quote local))) (lambda nil (org-add-hook (quote change-major-mode-hook) (quote org-babel-show-result-all) (quote append) (quote local)) ) org-babel-result-hide-spec org-babel-hide-all-hashes turn-on-org-cdlatex turn-on-auto-fill
Re: [O] [bug] Symbol's function definition is void: when-let
Am 19.05.2011 13:06, schrieb Eric Schulte: Oh! My fault, `when-let' is defined locally on my Emacs, but apparently is not an official Emacs function, careless committing on my part. I've just pushed up a fix. Thanks for fixing that! Everything works fine now! Bernd
[O] Referencing a footnote (LaTeX export)
Hi all, This is hopefully a simple question, but I am stuck: How can I reference a footnote (see example below)? Since I am exporting my org-file to LaTeX, I am using something like \ref{???} but what can I use as footnote label? Chapter 2.10 of the manual introduces the 'named footnote reference' [fn:name] and my first idea was that I could use 'name' as label (and I changed my footnote to [fn:fn1]) but that didn't work. -- Lorem ipsum dolor sit amet, consectetur adipiscing elit.[fn:1] Fusce vestibulum tempor lobortis. Pellentesque lacinia faucibus augue, ultrices elementum tortor condimentum id. Maecenas scelerisque mattis odio, eget porttitor erat cursus eu. Duis porta porttitor diam, eget dapibus lorem malesuada eget. Morbi sed orci vitae libero pharetra congue (see footnote \ref{???}). [fn:1] My first footnote -- Thanks for your help, Bernd
Re: [O] Referencing a footnote (LaTeX export)
Am 07.05.2011 16:07, schrieb Matt Lundin: Bernd Weissbernd.we...@uni-koeln.de writes: This is hopefully a simple question, but I am stuck: How can I reference a footnote (see example below)? Since I am exporting my org-file to LaTeX, I am using something like \ref{???} but what can I use as footnote label? Chapter 2.10 of the manual introduces the 'named footnote reference' [fn:name] and my first idea was that I could use 'name' as label (and I changed my footnote to [fn:fn1]) but that didn't work. [...] AFAIK, org-mode does not convert footnote labels (named references) to LaTeX labels. But if you are only exporting to LaTeX, you could use the following syntax: --8---cut here---start-8--- Lorem ipsum dolor sit amet, consectetur adipiscing elit.[fn:1] Fusce vestibulum tempor lobortis. Pellentesque lacinia faucibus augue, ultrices elementum tortor condimentum id. Maecenas scelerisque mattis odio, eget porttitor erat cursus eu. Duis porta porttitor diam, eget dapibus lorem malesuada eget. Morbi sed orci vitae libero pharetra congue (see footnote \ref{firstfootnote}). [fn:1] My first footnote.\label{firstfootnote} --8---cut here---end---8--- Hi Matt, That makes sense and works. Thanks, Bernd
Re: [O] Specifying \institute[short]{long] in Beamer presentations
Am 24.03.2011 04:59, schrieb PASZTOR Miklos: On Wed, Mar 23, 2011 at 07:18:45PM -0400, Bernd Weiss wrote: I am currently preparing a Beamer presentation and I would like to include \institute[short]{long} into my org-file; This works for me: #+BEAMER_HEADER_EXTRA: \institute{My insitute} Cool, thanks a lot! That solved all my problems. Bernd
Re: [O] Specifying \institute[short]{long] in Beamer presentations
Am 23.03.2011 22:51, schrieb Suvayu Ali: On Wed, 23 Mar 2011 19:18:45 -0400 Bernd [...] I am currently preparing a Beamer presentation and I would like to include \institute[short]{long} into my org-file; it is important that I am able to define a short and a long entry for institute. How can I do this? Let me reword your issue, but my understanding of LaTeX is limited so please correct me if I am wrong. You want to specify your affiliation with the institute command. AFAIU the \institute command is declared in the header of a tex file. So I am a little confused by your use of properties in org. Shouldn't something like this after the #+NAME: and #+AUTHOR: directives work fine? #+LaTeX_HEADER: \institute[short name]{My awesome institute} Oh, yes, that helps and I cannot believe that I didn't realize it before. Thanks, Bernd
Re: [O] Specifying \institute[short]{long] in Beamer presentations
Am 24.03.2011 05:42, schrieb Camille persson: Hi, I'm not sure but maybe you could declare it in your org file as: #+MACRO: BEAMERINSTITUTELONG My long and detailed Institute #+MACRO: BEAMERINSTITUTESHORT Short Institute And change the export code as follows: \\institute[beamerinstituteshort]beamerinstitutelong\n But I didn't tested it, it is just an idea that comes up reading your mail. Hi Camille, Thanks for your answer! That would not solve my problem since it blocks the functionality of frame :PROPERTIES: . I was simply looking for #+BEAMER_HEADER_EXTRA: \institute{My insitute} or #+LaTeX_HEADER: \institute[short name]{My awesome institute} Thanks, Bernd
Re: [O] Customizing LaTeX-export, Beamer, \institute, and BEAMER_envargs
Am 24.03.2011 05:16, schrieb Eric S Fraga: Bernd Weissbernd.we...@uni-koeln.de writes: Dear all, I am preparing a Beamer presentation and I am having some trouble with side effects (?) due to my attempt to customize the LaTeX-export. My minimum example can be found below. The default LaTeX-export does not recognise the '\institute'-option (I mean, as far as I know). For that reason, I run (add-to-list org-export-latex-classes ...). Unfortunately, the export-function does no longer recognice :BEAMER_envargs: [plain] (or :BEAMER_envargs: [shrink=5])[1]. yes, that is correct. the default entry uses =org-beamer-sectioning= which is where headings are translated to latex section or frame or block etc entries *and* where the special beamer properties are processed. As you have replaced the sectioning section of =org-export-latex-classes= with your own, you have lost all of that functionality. You seem to want to achieve two things: 1. added your macros into the latex preamble, and 2. add the [fragile] option to each frame. I would suggest you do 1 as you have done but keep org-beamer-sectioning as the second argument for the org-export-latex-classes entry. To add [fragile] to each frame, I would recommend, instead, using some automated form of input, such as a yasnippet snippet like this one (untested): --8---cut here---start-8--- #name : frame # -- ** ${1:frame title} :PROPERTIES: :BEAMER_envargs: ${2:[fragile]} :END: $0 --8---cut here---end---8--- so that typing frame followed by TAB would define a new headline, prompting for the title and possible arguments (with defaults). Hi Eric, Thanks for your help! Unfortunately, that's not what I was looking for and, therefore, rephrased my unclear question (Specifying \institute[short]{long] in Beamer presentations). As pointed out by Miklós or Suvayu, the solution was embarrassingly simpel: Just include #+BEAMER_HEADER_EXTRA: \institute{My insitute} or #+LaTeX_HEADER: \institute[short name]{My awesome institute} Anyway, I really appreciate your help! Bernd
[O] Specifying \institute[short]{long] in Beamer presentations
Dear all, I assume that my first email[1], which I sent yesterday, was not clear enough to draw any/enough attention. I am currently preparing a Beamer presentation and I would like to include \institute[short]{long} into my org-file; it is important that I am able to define a short and a long entry for institute. How can I do this? NB: Modifying (add-to-list 'org-export-latex-classes '(beamer ... (see [1]), causes org-mode to ignore any :PROPERTIES: :BEAMER_env: frame :BEAMER_envargs: [...] :END: statements. Thanks, Bernd [1] Customizing LaTeX-export, Beamer, \institute, and BEAMER_envargs http://www.mail-archive.com/emacs-orgmode@gnu.org/msg39705.html
[O] Customizing LaTeX-export, Beamer, \institute, and BEAMER_envargs
Dear all, I am preparing a Beamer presentation and I am having some trouble with side effects (?) due to my attempt to customize the LaTeX-export. My minimum example can be found below. The default LaTeX-export does not recognise the '\institute'-option (I mean, as far as I know). For that reason, I run (add-to-list 'org-export-latex-classes ...). Unfortunately, the export-function does no longer recognice :BEAMER_envargs: [plain] (or :BEAMER_envargs: [shrink=5])[1]. Thanks, Bernd [1] Which is obviously due to \\begin{frame}[fragile]\\frametitle{%s} #+begin_src emacs-lisp :results silent :exports none (add-to-list 'org-export-latex-classes ;; beamer class, for presentations '(beamer \\documentclass[11pt]{beamer}\n [NO-DEFAULT-PACKAGES] [EXTRA] \\mode{{{beamermode}}}\n \\usethemebeamertheme\n \\institutebeamerinstitute\n \\subjectbeamersubject\n (\\section{%s} . \\section*{%s}) (\\begin{frame}[fragile]\\frametitle{%s} \\end{frame} \\begin{frame}[fragile]\\frametitle{%s} \\end{frame}))) #+end_src #+LaTeX_CLASS: beamer #+MACRO: BEAMERMODE presentation #+MACRO: BEAMERTHEME Madrid #+MACRO: BEAMERINSTITUTE Research Institute for ??? #+TITLE: #+AUTHOR: Arthur Mueller #+DATE: March, 28th 2011 #+BEAMER_FRAME_LEVEL: 2 #+latex_header: \modebeamer{\usetheme{Madrid}} * Introduction ** A simple slide :PROPERTIES: :BEAMER_env: frame :BEAMER_envargs: [plain] :END: This slide consists of some text with a number of bullet points: - the first, very @important@, point! - the previous point shows the use of the special markup which translates to the Beamer specific /alert/ command for highlighting text. The above list could be numbered or any other type of list and may include sub-lists.
[Orgmode] [Babel][R] buffer-wide and code block specific use of :session
Org-mode version 7.4 (release_7.4.348.g6132) Dear all, I am preparing a document which contains text and R code/output. In particular, I'd like to print out a (correlation) matrix. This is my org-mode document (I intentionally have two code blocks): #-- #+ Does not work #+BABEL: :session *R* #+BEGIN_SRC R :results silent :tangle simcorrdata.R cormat - c(1.0, 0.2, 0.4, 0.2, 1.0, -0.3, 0.4, -0.3, 1.0) cormat - matrix(cormat, ncol = 3, byrow = TRUE) #+END_SRC So, the correlation matrix looks as follows: #+BEGIN_SRC R :exports both :tangle simcorrdata.R print(cormat) #+END_SRC #-- Since I have two code blocks, I need to use :session. If I define :session buffer-wide as #+BABEL: :session *R* then the matrix cormat is unknown within the second code block (object 'cormat' not found). However, if I specify :session for each code block seperately then it works as expected. #-- #+ Does work #+BEGIN_SRC R :session :results silent :tangle simcorrdata.R cormat - c(1.0, 0.2, 0.4, 0.2, 1.0, -0.3, 0.4, -0.3, 1.0) cormat - matrix(cormat, ncol = 3, byrow = TRUE) #+END_SRC So, the correlation matrix looks as follows: #+BEGIN_SRC R :session :exports both :tangle simcorrdata.R print(cormat) #+END_SRC #-- Does this happen due to my poor understanding of the :session argument? Or is this a bug? Thanks for your help, Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: [Babel][R] buffer-wide and code block specific use of :session
Am 12.02.2011 13:30, schrieb Dan Davison: Bernd Weissbernd.we...@uni-koeln.de writes: [...] Since I have two code blocks, I need to use :session. If I define :session buffer-wide as #+BABEL: :session *R* then the matrix cormat is unknown within the second code block (object 'cormat' not found). However, if I specify :session for each code block seperately then it works as expected. Hi Bernd, The above does work for me. Some things to check: 1. After altering the #+BABEL line, it's necessary to refresh Org's file-local options, for example with C-c C-c on the #+BABEL line. (Same is true for #+OPTIONS, #+PROPERTY, etc) 2. I've just fixed a bug which was causing it to fail to work on the first attempt... But it did work on second and subsequent attempts. Please note that it is possible to make an equivalent setting using #+PROPERTY: session *R* In fact, I suspect we are going to drop #+BABEL entirely, so please consider it deprecated and use this form instead. After evaluating the first block, an ESS R buffer named *R* should exist, in which the variable cormat should be defined. Let me know if your problem persists. Hi Dan, Thanks for your reply. Using #+PROPERTY: session *R* (and running another =git pull origin master=) solved all my problems. Thanks, Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [Babel] Finished my presentation on R using org-mode and Babel
Dear all, I appologize for this slightly off-topic mail but I wanted to let you know that -- after asking many questions -- I finally finished my first org-mode- and Babel-based presentation. If you are interested in my slides or the source code, feel free to download it from my github repository: https://github.com/berndweiss/r_meta-analysis_intro. I am also interested in any comments or criticism. Finally, I would like to thank (again) Eric Schulte and Dan Davison who created this great piece of software and kindly answered all my question. Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Re: [Babel] R, multiple lines #+results, LaTeX-export
Am 03.12.2010 03:41, schrieb Sébastien Vauban: [...] I am using Org-mode version 7.3 (release_7.01h.1081.gcfd7.dirty) That sounds weird to me: version 7.3 and a 7.01 tag!? Hi Sébastien, That's what I get when I run Show Version: release_7.01h-1081-gcfd7 Org-mode version 7.3 (release_7.01h.1081.gcfd7.dirty) Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] [Babel] R, multiple lines #+results, LaTeX-export
Am 03.12.2010 09:14, schrieb Eric Schulte: Hi Bernd, Bernd Weissbernd.we...@uni-koeln.de writes: [...] (2) The results-block is complex insofar as it has multiple lines. If I choose export as LaTeX and process to PDF (I corrected the wrong #+end_example line manually), the resulting PDF file only shows the code but not the results. However, this behaviour is only related to my meta-analysis example. If I use, for example, summary(lm(rnorm(100)~1)), the resulting PDF file shows code + results. [...] This is odd, could you send a self-contained org-mode file which reproduces this error? Hi Eric, I just updated my org-mode repository and now everything works fine. Thanks a lot, Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Re: [Babel] R, multiple lines #+results, LaTeX-export
Am 03.12.2010 10:05, schrieb Nick Dokos: Bernd Weissbernd.we...@uni-koeln.de wrote: Am 03.12.2010 03:41, schrieb S=C3=A9bastien Vauban: [...] I am using Org-mode version 7.3 (release_7.01h.1081.gcfd7.dirty) That sounds weird to me: version 7.3 and a 7.01 tag!? Hi S=C3=A9bastien, That's what I get when I run Show Version: release_7.01h-1081-gcfd7 Org-mode version 7.3 (release_7.01h.1081.gcfd7.dirty) You are probably missing the 7.3 tag, so it has to go back all the way to 7.01h to find a starting point: you are 1081 commits past 7.01h. Mine says Org-mode version 7.3 (release_7.3.148.gc3b7e.dirty) so I'm 148 commits past 7.3, so I'd expect roughly 930 commits between 7.01h and 7.3 (roughly, because we probably don't have the same HEAD). I get $ git log --oneline release_7.01h..release_7.3 | wc -l 917 so it checks out. Do ``git tag'' to make sure the relase_7.3 tag is missing. Then do ``git fetch --tags'' and check with ``git tag'' again. If the tag shows up, org-version should then show you 7.3 as the starting point. Nick Hi Nick, Thanks! git fetch --tags was what I was missing. I simply (naively?) assumed that git pull origin master would be sufficient. Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] [org-babel] R, :session and empty line in #+results
Am 01.12.2010 02:19, schrieb Thomas S. Dye: Aloha Bernd, On Nov 30, 2010, at 1:23 PM, Bernd Weiss wrote: Dear all, I would like to use R objects across/among code blocks. Therefore, I included the header argument :session which then produces the following results: #+BEGIN_SRC R :results output :session x - 1 x x + 1 #+END_SRC #+results: : : [1] 1 : [1] 2 #+BEGIN_SRC R :results output :session x #+END_SRC #+results: : [1] 1 How can I get rid of the first line of the first #+results-block? BTW: if I remove the :session argument this empty line disappears. #+BEGIN_SRC R x - 1 x x + 1 #+END_SRC #+results: : 2 Hi Tom, Thanks for your reply! I should have noted that I am preparing a beamer presentation and I need all the code and the results. So, your answer does not solve my problem. Maybe this is another information I should have given: To control org-babel's behaviour, I am defining the following buffer-wide header arguments: #+BABEL: :results output replace :exports both :comments both :session Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] [org-babel] R, :session and empty line in #+results
Am 01.12.2010 10:01, schrieb Eric Schulte: Hi Bernd, I've just pushed up a change which should remove these empty lines. Just updated my org-mode repository and it works great. Thanks a lot! Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [org-babel] R, :session and empty line in #+results
Dear all, I would like to use R objects across/among code blocks. Therefore, I included the header argument :session which then produces the following results: #+BEGIN_SRC R :results output :session x - 1 x x + 1 #+END_SRC #+results: : : [1] 1 : [1] 2 #+BEGIN_SRC R :results output :session x #+END_SRC #+results: : [1] 1 How can I get rid of the first line of the first #+results-block? BTW: if I remove the :session argument this empty line disappears. Thanks for your help, Bernd P.S. As far as I can see my question is not related to Dr. Bate's question on Removing the blank lines between code and results blocks in LaTeX export http://www.mail-archive.com/emacs-orgmode@gnu.org/msg29957.html ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: [org-babel] Using the power of ESS inside an R source code block
Am 26.10.2010 10:05, schrieb Dan Davison: [...] Am 24.10.2010 05:44, schrieb Bernd Weiss: [...] Dear all, Yesterday, I spent some time (re-)discovering the power of org-babel and R. Everything works well but there is one issue that I find somewhat annoying (I apologise if this word is too rude). Not at all. Good to know what drawbacks users are encountering. I'm happy to report that all three of the things you mention are now possible in the Org buffer. You will need to be using a recent version of Org-mode (i.e. from within the last few weeks). Hi Dan Eric, Again (and now on-list), thanks a lot for your reply and your help! As a long-time ESS user I wish that I could use things like ESS syntax highlighting, This, as Eric mentioned, is turned on with `org-src-fontify-natively'. However from your config below it seems you have set this variable. So that requires some explanation -- please let us know if syntax highlighting in the Org buffer is working for you or not. Yes, syntax highlighting seems to be work as expected. indentation Setting `org-src-tab-acts-natively' causes TAB to have the indenting effect that you would get in an ESS buffer.[2] That also works. I only have a very (very) basic knowledge of elips. So, I guess it is possible to change the depth of indentation. The current indentation behaviour is as follows: #+BEGIN_SRC R :results output :exports results library(MASS) plot(1,1) for(i in 1:10){ print(i) } [...] However, I would prefer... #+BEGIN_SRC R :results output :exports results library(MASS) plot(1,1) for(i in 1:10){ print(i) } [...] Beyond these two variables, there is a general method that addresses the issues you are raising. It involves using the function `org-babel-do-key-sequence-in-edit-buffer'. For example, here is how to make C-M-\ perform language-specific indentation on the active region in the source block: (defun dan/org-indent-region () (interactive) (or (org-babel-do-key-sequence-in-edit-buffer \C-\M-\\) (indent-region))) (define-key org-mode-map \C-\M-\\ 'dan/org-indent-region) or some keybindings (e.g. for -) inside an R source code block. This one can be done with (defun dan/org-underscore-command () (interactive) (or (org-babel-do-key-sequence-in-edit-buffer _) (org-self-insert-command 1))) (define-key org-mode-map _ 'dan/org-underscore-command) And another one that you may like is for commenting code: (defun dan/org-comment-dwim (optional arg) (interactive P) (or (org-babel-do-key-sequence-in-edit-buffer \M-;) (comment-dwim arg))) (define-key org-mode-map \M-; 'dan/org-comment-dwim) I hope the above supplies the missing functionality. Dan Puh, as I told you I only have a very basic understanding of elisp... If I do a simple copy and paste, I see this error: Symbol's value as variable is void: org-mode-map. I also guess that I should change dan/org-underscore-command... However, you should not care about my little elips problems. You were really helpful in solving my most important problems! Thanks, Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] [org-babel] Using the power of ESS inside an R source code block
Dear all, Yesterday, I spent some time (re-)discovering the power of org-babel and R. Everything works well but there is one issue that I find somewhat annoying (I apologise if this word is too rude). As a long-time ESS user I wish that I could use things like ESS syntax highlighting, indentation or some keybindings (e.g. for -) inside an R source code block. However, with respect to an e-mail from Eric Schulte http://www.mail-archive.com/emacs-orgmode@gnu.org/msg22301.html (or this one: https://stat.ethz.ch/pipermail/ess-help/2009-September/005544.html ) this seems to be a feature wich is hard to realise inside org-babel. Is this (still) correct? Or is it a problem with my installation/initialisation of org-mode/org-babel?[1] Thanks, Bernd [1] This is the org-mode part in my .emacs: ;; The following lines are always needed. Choose your own keys. (add-to-list 'auto-mode-alist '(\\.org\\' . org-mode)) (global-set-key \C-cl 'org-store-link) (global-set-key \C-ca 'org-agenda) (global-set-key \C-cb 'org-iswitchb) (global-font-lock-mode 1) ; for all buffers (add-hook 'org-mode-hook 'turn-on-font-lock) ; Org buffers only ;;(setq org-ditaa-jar-path D:/programme/emacs/site-lisp/org-mode/contrib/scripts/ditaa.jar) (setq org-directory e:/projects/org/) (setq org-confirm-babel-evaluate nil) ;; active Babel languages (setq org-babel-load-languages (quote ((emacs-lisp . t) (R . t) (python . t) ) ) ) (setq org-src-fontify-natively t) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Custom agenda view: Select specific tag (or category) + display timestamps
Dear all, I'm having trouble with agenda customization. I have a couple of entries (+ timestamp) which are tagged with 'conference' and I'd like to have a list of conferences + timestamps. (setq org-agenda-custom-commands '( (c conferences ((tags CONFERENCE)) ) ) ) Many thanks in advance for your help, Bernd ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode