Re: [O] org tables into R?

2015-01-06 Thread Rainer M Krug
 is passed to the (format) function and one might be able to change
something there.

Cheers,

Rainer

>
>
> And finally, here is my R session, when I step through the code:
>
>
> R version 3.1.2 (2014-10-31) -- "Pumpkin Helmet"
> Copyright (C) 2014 The R Foundation for Statistical Computing
> Platform: x86_64-apple-darwin10.8.0 (64-bit)
>
> R is free software and comes with ABSOLUTELY NO WARRANTY.
> You are welcome to redistribute it under certain conditions.
> Type 'license()' or 'licence()' for distribution details.
>
>   Natural language support but running in an English locale
>
> R is a collaborative project with many contributors.
> Type 'contributors()' for more information and
> 'citation()' on how to cite R or R packages in publications.
>
> Type 'demo()' for some demos, 'help()' for on-line help, or
> 'help.start()' for an HTML browser interface to help.
> Type 'q()' to quit R.
>
>> > options(STERM='iESS', str.dendrogram.last="'", editor='emacsclient', 
>> > show.error.locations=TRUE)
>> data.table <- local({
> +  con <- textConnection(
> +"\"A\"   \"B\"   \"C\"
> + \"115\" \"76\"  \"60\"
> + \"124\" \"78\"  \"55\"
> + \"118\" \"73\"  \"65\"
> + \"114\" \"75\"  \"61\"
> + \"108\" \"74\"  \"82\""
> +  )
> +  res <- utils::read.table(
> +con,
> +header= TRUE,
> +row.names = NULL,
> +sep   = "\t",
> +as.is = TRUE
> +  )
> +  close(con)
> +  res
> +})
>> names(data.table)
> [1] "A...B...C"
>> head(data.table)
>A...B...C
> 1 115 76  60
> 2 124 78  55
> 3 118 73  65
> 4 114 75  61
> 5 108 74  82
>
>
> Regards,
> Andreas
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Efficiency of Org v. LaTeX v. Word

2014-12-27 Thread M



> Von: Paul Rudin 
> Datum: Sat, 27 Dec 2014 10:05:19 +
> An: 
> Betreff: Re: [O] Efficiency of Org v. LaTeX v. Word
> 
> Ken Mankoff  writes:
> 
>> People here might be interested in a publication from [2014-12-19 Fri]
>> available at http://dx.doi.org/10.1371/journal.pone.0115069
>> 
>> Title: An Efficiency Comparison of Document Preparation Systems Used
>> in Academic Research and Development
>> 
>> Summary: Word users are more efficient and have less errors than even
>> experienced LaTeX users.
>> 
>> Someone here should repeat experiment and add Org into the mix, perhaps
>> Org -> ODT and/or Org -> LaTeX and see if it helps or hurts. I assume
>> Org would trump LaTeX, but would Org -> ODT or Org -> X -> DOCX (via
>> pandoc) beat straight Word?
>> 
> 
> No mention of emacs... who uses anything else to prepare their LaTeX?
> 
Did you forget the " ;-)" or are you serious?

Emacs is for sure a very good one, but there are a lot of popular
alternatives, if you have a look at the (for sure not representative) voting
on the answers of this discussion here:

http://tex.stackexchange.com/questions/339/latex-editors-ides

(It's clear, that people may have voted for several of those editors, so
that no valid statistics at all, but at least an idea...)

Is there any real survey result about which editors LaTeX users use?

Martin





Re: [O] org-mode in teaching

2014-12-20 Thread Marvin M. Doyley
Thanks John,
I am sure this will be better than blackboard. I will give it a try :)
Cheers 
M

Sent from my iPhone
** May contain typos**


> On Dec 20, 2014, at 5:48 PM, John Kitchin  wrote:
> 
> All of the code is here:
> https://github.com/jkitchin/jmax/tree/master/techela
> 
> and there is some documentation in the README.
> 
> I am not sure how much work it would take to try it yourself though. You
> need to setup a gitolite server (that is described in the README), and
> more importantly figure out how to get this in your student's hands. For
> windows users, they can just clone jmax, and it should run out of the
> box (it has an emacs in it).
> 
> "Marvin M. Doyley"  writes:
> 
>> Very cool indeed.
>> I would love to try this for a small course that I will be teaching in the 
>> spring semester.
>> Is your code available?
>> Cheers,
>> M
>> Sent from my iPad
> 
> -- 
> ---
> John Kitchin
> Professor
> Doherty Hall A207F
> Department of Chemical Engineering
> Carnegie Mellon University
> Pittsburgh, PA 15213
> 412-268-7803
> http://kitchingroup.cheme.cmu.edu



Re: [O] org-mode in teaching

2014-12-20 Thread Marvin M. Doyley

Very cool indeed.
I would love to try this for a small course that I will be teaching in the 
spring semester.
Is your code available?
Cheers,
M
Sent from my iPad


[O] KEybinding for Re: Naming of (indirect?) buffers opened by C-'

2014-12-19 Thread Rainer M Krug
Rainer M Krug  writes:
Followup:

I would now bing=t =this function to C-c ' - how can I do this without
interfering with the general operation of C-c ' which calls
org-edit-special?

Rainer

> Grant Rettke  writes:
>
>> (defun gcr/org-edit-src-code-plus-name ()
>>   "Edit the well-described source code block.
>>
>> Attribution: URL
>> `https://lists.gnu.org/archive/html/emacs-orgmode/2014-09/msg00778.html'"
>>   (interactive)
>>   (let* ((eop  (org-element-at-point))
>>  (name (or (org-element-property :name (org-element-context eop))
>>   "ॐ"))
>>  (lang (org-element-property :language eop))
>>  (buff-name (concat "*Org Src " name "[" lang "]*")))
>> (org-edit-src-code nil nil buff-name)))
>>
>
> Thanks - that is exactly what I was looking for. But I had to change the
> last line to
>
> ,
> | (org-edit-src-code nil buff-name)))
> `
>
> as it seems that in my version of org
>
> ,
> | Org-mode version 8.3beta (release_8.3beta-660-g389274 @ 
> /Users/rainerkrug/.emacs.d/org-mode/lisp/)
> `
>
> the function org-edit-src-code only takes two arguments:
>
> ,
> | org-edit-src-code is an interactive compiled Lisp function in
> | `org-src.el'.
> | 
> | (org-edit-src-code &optional CODE EDIT-BUFFER-NAME)
> | 
> | Edit the source or example block at point.
> | 
> | The code is copied to a separate buffer and the appropriate mode
> | is turned on.  When done, exit with M-x org-edit-src-exit.  This
> | will remove the original code in the Org buffer, and replace it
> | with the edited version.  See `org-src-window-setup' to configure
> | the display of windows containing the Org buffer and the code
> | buffer.
> | 
> | When optional argument CODE is a string, edit it in a dedicated
> | buffer instead.
> | 
> | When optional argument EDIT-BUFFER-NAME is non-nil, use it as the
> | name of the sub-editing buffer.
> `
>
> Thanks a lot,
>
> Rainer
>
>
>> On Thu, Dec 18, 2014 at 5:00 AM, Rainer M Krug  wrote:
>>> Hi
>>>
>>> I remember there was a discussion recently about the naming of the
>>> indirect buffers of source code block opened with C-' but I can't find
>>> it at the moment. Was there a solution on giving these buffers a
>>> useful name, i.e. the name of the code block?
>>>
>>> If this is included in org, it does not seem to be working for me?
>>>
>>> Thanks,
>>>
>>> Rainer
>>>
>>> --
>>> Rainer M. Krug
>>> email: Rainerkrugsde
>>> PGP: 0x0F52F982

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Naming of (indirect?) buffers opened by C-'

2014-12-19 Thread Rainer M Krug
Grant Rettke  writes:

> (defun gcr/org-edit-src-code-plus-name ()
>   "Edit the well-described source code block.
>
> Attribution: URL
> `https://lists.gnu.org/archive/html/emacs-orgmode/2014-09/msg00778.html'"
>   (interactive)
>   (let* ((eop  (org-element-at-point))
>  (name (or (org-element-property :name (org-element-context eop))
>   "ॐ"))
>  (lang (org-element-property :language eop))
>  (buff-name (concat "*Org Src " name "[" lang "]*")))
> (org-edit-src-code nil nil buff-name)))
>

Thanks - that is exactly what I was looking for. But I had to change the
last line to

,
| (org-edit-src-code nil buff-name)))
`

as it seems that in my version of org

,
| Org-mode version 8.3beta (release_8.3beta-660-g389274 @ 
/Users/rainerkrug/.emacs.d/org-mode/lisp/)
`

the function org-edit-src-code only takes two arguments:

,
| org-edit-src-code is an interactive compiled Lisp function in
| `org-src.el'.
| 
| (org-edit-src-code &optional CODE EDIT-BUFFER-NAME)
| 
| Edit the source or example block at point.
| 
| The code is copied to a separate buffer and the appropriate mode
| is turned on.  When done, exit with M-x org-edit-src-exit.  This
| will remove the original code in the Org buffer, and replace it
| with the edited version.  See `org-src-window-setup' to configure
| the display of windows containing the Org buffer and the code
| buffer.
| 
| When optional argument CODE is a string, edit it in a dedicated
| buffer instead.
| 
| When optional argument EDIT-BUFFER-NAME is non-nil, use it as the
| name of the sub-editing buffer.
`

Thanks a lot,

Rainer


> On Thu, Dec 18, 2014 at 5:00 AM, Rainer M Krug  wrote:
>> Hi
>>
>> I remember there was a discussion recently about the naming of the
>> indirect buffers of source code block opened with C-' but I can't find
>> it at the moment. Was there a solution on giving these buffers a
>> useful name, i.e. the name of the code block?
>>
>> If this is included in org, it does not seem to be working for me?
>>
>> Thanks,
>>
>> Rainer
>>
>> --
>> Rainer M. Krug
>> email: Rainerkrugsde
>> PGP: 0x0F52F982

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


[O] Naming of (indirect?) buffers opened by C-'

2014-12-18 Thread Rainer M Krug
Hi

I remember there was a discussion recently about the naming of the
indirect buffers of source code block opened with C-' but I can't find
it at the moment. Was there a solution on giving these buffers a
useful name, i.e. the name of the code block?

If this is included in org, it does not seem to be working for me?

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Open all #+INCLUDED:d files?

2014-12-12 Thread Rainer M Krug
Rasmus  writes:

> Rainer M Krug  writes:
>
>> Is there an easy way of opening all INCLUDEd files in an org document,
>> i.e. a single command or an easy way of doing it via some elisp code?
>
> Oh, sorry, I didn't see the "all".

No problem - so I learned about C-c & - very useful.

> But yeah, it should be easy with org-element-map.  Map over all
> keywords, ensure they are INCLUDE keywords, move point to their :begin
> and call org-edit-special or similar.  You could use save-excursion,
> save-window-excursion to make it not suck.  You'd might have to widen
> first, then you could use save-restriction.

OK - I might look into it when I get to annoyed by the manual approach.

Thanks,

Rainer


>
> Hope it helps,
> Ramsus

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


[O] Open all #+INCLUDED:d files?

2014-12-12 Thread Rainer M Krug
Hi

Is there an easy way of opening all INCLUDEd files in an org document,
i.e. a single command or an easy way of doing it via some elisp code?

Thanks,

Rainer


-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


[O] #+INCLUDE: without file extension

2014-12-12 Thread Rainer M Krug
Hi

In the following example (assuming the three text files exist):

--8<---cut here---start->8---
* example for include
When doing C-' on these INCLUDEs, the file opens, but not as expected:

#+INCLUDE: ./testfile.txt

Opens in emacs (expected).

#+INCLUDE: ./testfile.xyz

Tries to open externally but does not work as no viewer is available for
.xyz files (kind of expected)

#+INCLUDE: ./testfile

Opens externally (not expected)
--8<---cut here---end--->8---

I assume this is caused by my ~/mailcap file
,
| application/pdf; open %s
| application/*; open %s
`
Which I have for gnus.

Is there a way to specify the viewer / editor when using C-' on an
INCLUDEd file? As they are all test files, I would like to open all of
the INCLUDEd files in emacs.

I am on a Mac, Yosemite, with:
,
| GNU Emacs 24.4.1 (x86_64-apple-darwin14.0.0, Carbon Version 157 AppKit
| 1343.16) of 2014-11-24 on Rainers-MacBook-Pro-4.local
| 
| Org-mode version 8.3beta (release_8.3beta-603-g9aa58f @
| /Users/rainerkrug/.emacs.d/org-mode/lisp/)
`

Any suggestion?

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Bug: addt'l multiple property drawers situations when org-log-done set to 'note [8.3beta (release_8.3beta-621-gf212f7) @ /path/to/org-mode/lisp/]

2014-12-08 Thread Bradley M. Kuhn
Nicolas Goaziou wrote:
> This is a recent change in master. PROPERTIES drawer is only recognized as
> such when at the top of the section, possibly after a planning info line.

I apologize for not reading ORG-NEWS before reporting the bug... er,
feature. ;)


> You may want to look into ORG-NEWS file, there's a function to help you
> fix old documents.

Thanks for taking the time to tell me where to look!  Yes, it was right
there. I'm sorry for taking up your time with pointing me to the obvious
place. :)


   -- bkuhn



[O] Bug: addt'l multiple property drawers situations when org-log-done set to 'note [8.3beta (release_8.3beta-621-gf212f7) @ /path/to/org-mode/lisp/]

2014-12-07 Thread Bradley M. Kuhn
Nicolas,

Thanks for fixing that bug so quickly.  I grabbed the lastest master
and it seems the bug is definitely fixed.

I however still have a related bug:  I have many entries where the PROPERTIES
drawer is at the bottom of a long set of TODO notes.  Mine look like this:

** TODO Monthly Accounting: Reconcile Payment report.
   SCHEDULED: <2014-10-07 Tue 08:00 ++1m>
   - State "DONE"   from "TODO"   [2014-09-05 Fri 19:12] \\
 Finished through <2014-09-02 Tue>
   - State "DONE"   from "TODO"   [2014-06-16 Mon 09:28] \\
 Did this through <2014-05-30 Fri>.
   - State "TODO"   from ""   [2014-06-12 Thu 22:40] \\
 The monthly payment report can be downloaded.
   :PROPERTIES:
   :LAST_REPEAT: [2014-09-05 Fri 19:12]
   :END:

I still get a second property drawer when I cycle these repeating TODOs, if I
have:

(setq org-log-done 'note)

Same happens with ones like this, BTW::

* TODO Testing.
  SCHEDULED: <2014-12-28 Sun ++1w>
  - CLOSING NOTE [2014-12-07 Sun 19:25]
  - CLOSING NOTE [2014-12-07 Sun 19:25]
  :PROPERTIES:
  :LAST_REPEAT: [2014-12-07 Sun 19:25]
  :END:

It seems the new code intends to keep properties draw at the top of an entry,
but shouldn't it respect the positioning of the PROPRIETIES draw regardless
of where it is in the entry?

Thanks again for your responsiveness!

   -- bkuhn



Re: [O] Suggestion about ":session"

2014-12-02 Thread Rainer M Krug
abonnements  writes:

> Hello everybody,
> reading the manual (Release 8.2.10), I wonder if the syntax of
> ":session" header may not be changed in the way of  ":tangle" or
> ":noweb" (sorry for the frenchy expression). I mean :
>
>  * :session yes (now :session)
>  * :session no  (now :session none)
>  * :session name (now :session name)
>
> It seems to be more homogeneous.

+1

Consistency would be a big plus.

>
> THierry
>
> PS: Of course the old syntax must be supported.

This would mean, that

| new syntax| old syntax|
|---+---|
| :session yes  | :session  |
| :session none | :session no   |
| :session whatever | :session whatever |
|   |   |

Am I correct?

I think that should not cause any problems. 

Cheers,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Large LaTeX project in single file or using publishing

2014-11-27 Thread Rainer M Krug
Jacob Gerlach  writes:

> Hello list,
>
> I'm starting writing my thesis, for which I hope to remain in org-mode
> rather than regular LaTeX.
>
> I am working on adapting a thesis LaTeX template into org-mode. The
> template is set up with a main.tex having several individual files
> (chapters, appendices, etc) \include'd.
>
> I believe that I could parallel this using org's publishing mechanism. An
> alternate approach would be to use one single file, since I can simply fold
> chapters to focus my workflow.
>
> My first concern is losing the ability to use internal links if I use
> separate files. Another thought is compilation time if I use one file and
> must always run pdflatex over the entire document. I'm sure there are
> pitfalls either way that I'm not yet aware of.

Don't forget latexmk [1] which runns in an emacs shell or even a
different terminal, monitors file changes, and if a file changes
compiles the latex file - so exporting from org is exporting to latex
only, and the pdf is creqated in the background.

I use it daily and it works perfectly.

Cheers,

Rainer

>
> Any input or advice you can provide would be greatly appreciated.
>
> Regards,
> Jake


Footnotes: 
[1]  http://users.phys.psu.edu/~collins/software/latexmk-jcc/

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Subfloats in org - easier way?

2014-11-21 Thread Rainer M Krug
Rasmus  writes:

> Hi,
>
> Rainer M Krug  writes:
>
>> I want to include in a document, exported to LaTeX, a subfigure. and
>> followed the blog entry [1]. This works, but
>>
>> 1) is cumbersome and extemely LaTex - I can live with this, but is
>>there a more org-modeisch solution?
>> 2) I cant use the link (Figure [[fig:ventLEL]]) as they got not replaced
>>by the correct LaTeX commands. This is obvious (as I did not
>>use #+CAPTION: for the caption), but is there a way, apart from
>>using the LaTeX code for these links, to get the links into the
>>document?
>
> I don't think there's an "official" way to do this.  Presumably it
> /could/ use the same mechanisms as when concatenating tables into an
> equation of matrices, but at the moment there's nothing like it.
>
> I don't know if this is much better. It would probably require some
> effort to make it work in other backends than latex and it's pretty
> verbose.
>
> #+LATEX_HEADER: \usepackage{subcaption}
>
> #+CAPTION: Main caption
> #+begin_figure
> #+ATTR_LATEX: :options [t]{.45\textwidth}
> #+CAPTION: subcaption 1
> #+BEGIN_subfigure
> #+BEGIN_CENTER
> #+ATTR_LATEX: :width 3cm 
> [[file:tmpEOCX1p.jpg]]
> #+END_CENTER
> #+end_subfigure
> #+ATTR_LATEX: :options [t]{.45\textwidth} :width 2cm 
> #+CAPTION: subcaption 2
> #+begin_subfigure
> #+BEGIN_CENTER
> #+ATTR_LATEX: :width 3cm :center t
> [[file:tmpEOCX1p.jpg]]
> #+END_CENTER
> #+end_subfigure
> #+end_figure
>
> Hope it helps,


Thanks - it definitely does - even with labels and links.

Thanks a lot,

Rainer

Here my solution including the links to subfigures:

,
| A comparative plot of the matlab script and the R script shows that
| these two algorithms give the same results when using the same
| parameter (Figure [[fig:ventLEL]], matlab [[fig:ventLEL_matlab]], R  
[[fig:ventLEL_matlab_R]]).
| 
| A comparative plot of the matlab script and the R script shows that
| these two algorithms give the same results when using the same
| parameter (Figure [[fig:ventLEL]], matlab [[fig:ventLEL_matlab]], R  
[[fig:ventLEL_matlab_R]]).
| 
| #+CAPTION: Plot of the wind profile from the matlab script using the 
Log-Exp-Log profile
| #+LABEL: fig:ventLEL
| #+begin_figure
|   #+ATTR_LATEX: :options [t]{.45\textwidth}
|   #+CAPTION: Matlab script vent5
|   #+LABEL: fig:ventLEL_matlab
|   #+BEGIN_subfigure
| #+BEGIN_CENTER
|   [[file:inst/matlab/plots/vent5.pdf]]
| #+END_CENTER
|   #+end_subfigure
|   #+ATTR_LATEX: :options [t]{.45\textwidth}
|   #+CAPTION: R function uLEL()
|   #+LABEL: fig:=ventLEL_R
|   #+begin_subfigure
| #+BEGIN_CENTER
|   #+begin_src R :exports results :file rVentLEL.pdf :results graphics
| plot(runif(100))
|   #+end_src
|   #+RESULTS:
|   [[file:rVentLEL.pdf]]
| #+END_CENTER
|   #+end_subfigure
| #+end_figure
`



> Rasmus

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


[O] Subfloats in org - easier way?

2014-11-21 Thread Rainer M Krug

Hi

I want to include in a document, exported to LaTeX, a subfigure. and
followed the blog entry [1]. This works, but

1) is cumbersome and extemely LaTex - I can live with this, but is
   there a more org-modeisch solution?
2) I cant use the link (Figure [[fig:ventLEL]]) as they got not replaced
   by the correct LaTeX commands. This is obvious (as I did not
   use #+CAPTION: for the caption), but is there a way, apart from
   using the LaTeX code for these links, to get the links into the
   document?

Thanks,

Rainer

* The example
#+LATEX: \begin{figure}\centering
#+LATEX: \subfloat[matlab]{\label{fig:matlabVentLEL}
#+ATTR_LATEX: :height 0.45\textwidth
[[file:inst/matlab/plots/vent5.pdf]]
#+LATEX: } 
#+LATEX: \subfloat[R]{\label{fig:rVentLEL}

#+begin_src R :exports results :file rVentLEL.pdf :results graphics
plot(runif(10))
#+end_src
#+ATTR_LATEX: :height 0.45\textwidth
#+RESULTS:
[[file:rVentLEL.pdf]]

#+LATEX: }\caption{Plot of the wind profile from the matlab script using the 
Log-Exp-Log profile}\label{fig:ventLEL}
#+LATEX: \end{figure}



Footnotes: 
[1]  
http://draketo.de/light/english/emacs/write-multiple-images-single-page-org-mode

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Tangling src blocks to files as part of export

2014-11-14 Thread Rainer M Krug
Michael Weylandt  writes:

>> On Nov 13, 2014, at 10:54 AM, Michael Weylandt  
>> wrote:
>> 
>> Is it possible to have certain blocks tangled as part of export so
>> that they are available as input files to later source blocks?
>> 
>> E.g.,
>> 
>> #+BEGIN_SRC python :tangle hello.py
>> print "Hello World"
>> #+END_SRC
>> 
>> #+BEGIN_SRC sh
>> python hello.py
>> #+END_SRC
>> 
>> If I tangle before running, then the second code block will work; else, it 
>> fails because 'hello.py' is not found. [1]
>> 
>> I can run tangle and export in a row (and I have my own function to
>> do just that) but is there a native org way to do so?
>
> Adding org-babel-tangle to the org-export-before-processing-hook does
> the job, but I'd still be interested in knowing if there's a more
> official method.

I think this is the more-or-less official way of doing it - that's what
hooks are for: to do pre- and post-processing, which is exactly what you
want to do.

I like it actually.

Do you set the hook as a file local variable, and if yes, how?

Because this would be brilliant.

Cheers,

Rainer

>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] pdf images in html export

2014-11-12 Thread Rainer M Krug
Andreas Leha  writes:

> Hi Rainer,
>
> Rainer M Krug  writes:
>> Andreas Leha  writes:
>>
>>> Hi Marco,
>>>
>>> Marco Wahl  writes:
>>>> Andreas Leha  writes:
>>>>
>>>>> how would I export an org file containing
>>>>>
>>>>>   [[file:./myimage.pdf]]
>>>>>
>>>>> to html so that a say png version myimage.pdf is inlined in the html
>>>>> which links to the pdf?
>>>>>
>>>>> I guess it should be possible to run imagemagick on all pdf links during
>>>>> export somehow.
>>>>  
>>>> You could introduce a relation of the pdf-filenames to the respective
>>>> thumb-filenames e.g. by using the suffix '_thumb'.  Before the export
>>>> the conversion tool would create the thumbs.
>>>>
>>>> The org-file could reference the data as
>>>>
>>>> [[file:./myimage.pdf][file:myimage_thumb.png]]
>>>>
>>>> See the info page (info "(org)Images in HTML export")?
>>>>
>>>> Untested.  I just accidentially browsed that info page yesterday.
>>>>
>>>>
>>>
>>> Thanks for your thoughts.  I would like to automate all of that.  So, I
>>> guess the first question is where to put code that would trigger the
>>> conversion and how to best detect links to pdfs.
>>
>> Well - this is coming again and again - but no solution out of the
>> box. There are effectively two approaches:
>>
>> 1) Macro to change properties according to backend used.  
>>
>> One usage is changing the file name extension according to the
>> backend. This is implemented as a simplified macro below. This could
>> be done by using ~(by-backend (html "graph.png") (latex "graph.pdf") (t 
>> "graph.pdf"))~
>>  
>> See 
>> [[http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html#sec-4-3][work
>>  section ob-doc-LaTeX]] for details.
>>
>> #+begin_src emacs-lisp
>>   (setq org-babel-latex-htlatex "htlatex")
>>   (defmacro rmk-by-backend (&rest body)
>> `(case (if (boundp 'backend) (org-export-backend-name backend) nil) 
>> ,@body))
>> #+end_src
>>
>> 2) To use svg image format, which is supported by both (although has
>>it's drawbacks: slow rendering of the html, need to run external programs 
>> upon compilation)
>>
>> So the first might be the modst feasible option.
>>
>
> Thanks for this.  I am aware of how to *produce* graphics in different
> formats for different export backends.  I use your first approach,
> which I think is the better solution.

I agree with you.

>
> Here, I am after a solution, that works on images that are not produced
> but merely included via [[file:./some.pdf]].

OK - understood.

>
> I think there should be the possibility to include these into html (and
> odt) export without any user interaction.  So, I
> - do not want to write a source block just to produce the by-backend image
> - do not want to change the link manually
> - do not want to run the converter manually

I agree with you - this *should* be possible, and I assume not to
difficult to implement. In my opinion, this should also work out of the
box when enabling it e.g. via a property.

>
> I am pretty sure this should be achievable with standard orgmode tools
> (like filters, export hooks, or anything).

Yes - it should be.

>
> Since 'this is coming again and again' it seems a non-esoteric task.
> And as there is 'no solution out of the box', I assume(d) that somebody has
> written these filters already.

Unfortunately  not...

Cheers,

Rainer

>
> Regards,
> Andreas
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] pdf images in html export

2014-11-12 Thread Rainer M Krug
Andreas Leha  writes:

> Hi Marco,
>
> Marco Wahl  writes:
>> Andreas Leha  writes:
>>
>>> how would I export an org file containing
>>>
>>>   [[file:./myimage.pdf]]
>>>
>>> to html so that a say png version myimage.pdf is inlined in the html
>>> which links to the pdf?
>>>
>>> I guess it should be possible to run imagemagick on all pdf links during
>>> export somehow.
>>  
>> You could introduce a relation of the pdf-filenames to the respective
>> thumb-filenames e.g. by using the suffix '_thumb'.  Before the export
>> the conversion tool would create the thumbs.
>>
>> The org-file could reference the data as
>>
>> [[file:./myimage.pdf][file:myimage_thumb.png]]
>>
>> See the info page (info "(org)Images in HTML export")?
>>
>> Untested.  I just accidentially browsed that info page yesterday.
>>
>>
>
> Thanks for your thoughts.  I would like to automate all of that.  So, I
> guess the first question is where to put code that would trigger the
> conversion and how to best detect links to pdfs.

Well - this is coming again and again - but no solution out of the
box. There are effectively two approaches:

1) Macro to change properties according to backend used.  

One usage is changing the file name extension according to the
backend. This is implemented as a simplified macro below. This could
be done by using ~(by-backend (html "graph.png") (latex "graph.pdf") (t 
"graph.pdf"))~
 
See 
[[http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html#sec-4-3][work
 section ob-doc-LaTeX]] for details.

#+begin_src emacs-lisp
  (setq org-babel-latex-htlatex "htlatex")
  (defmacro rmk-by-backend (&rest body)
`(case (if (boundp 'backend) (org-export-backend-name backend) nil) ,@body))
#+end_src

2) To use svg image format, which is supported by both (although has
   it's drawbacks: slow rendering of the html, need to run external programs 
upon compilation)

So the first might be the modst feasible option.

Rainer


>
> Thanks,
> Andreas
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


[O] org-bibtex-yank for multiple bibtex entries - or: import .bib file

2014-11-07 Thread Rainer M Krug
Hi

I started using org-bibtex and ox-bibtex which, after a few initial
struggles got to work. I just have one question: how can I import
multiple entries from bibtex format to the org-bibtex format?

org-bibtex yank does only convert one entry, even if mulatiple entries
are selected. Is there a way of iomporting a .bib file with multiple
entries?

Thanks,

Rainer


-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


signature.asc
Description: PGP signature


Re: [O] Trouble using julia with org-babel

2014-10-31 Thread Doyley, Marvin M.
Hi Ista,

It is now working for Winston, but I am having problems with PyPlot is the case 
for you ?

thanks
M

PS this is the error that I get when trying to load PyPlot

ERROR: could not load module python: dlopen(python.dylib, 9): image not found
 in pyinitialize at /Users/doyley/.julia/v0.3/PyCall/src/PyCall.jl:456
 in pyimport at /Users/doyley/.julia/v0.3/PyCall/src/PyCall.jl:105
 in include at ./boot.jl:245
 in include_from_node1 at ./loading.jl:128
 in reload_path at loading.jl:152
 in _require at loading.jl:67
 in require at loading.jl:51
 in _start at ./client.jl:394
 in _start at /julia/usr/lib/julia/sys.dylib
while loading /Users/doyley/.julia/v0.3/PyPlot/src/PyPlot.jl, in expression 
starting on line 32





On Oct 29, 2014, at 10:53 PM, Ista Zahn  wrote:

> On Wed, Oct 29, 2014 at 10:09 PM, Doyley, Marvin M.
>  wrote:
>> I am using release-0.3.0 what version are you using. I am also using 
>> ob-julia.el
> 
> I'm using julia version 0.3.1 with GNU Emacs 24.4.1 and Org-mode
> version 8.2.10. I'm using the ob-julia.el distributed with
> org-plus-contrib.
> 
> Best,
> Ista
> 
>> Cheers,
>> M
>> 
>> Sent from my iPad
>> 
>>> On Oct 29, 2014, at 9:43 PM, Ista Zahn  wrote:
>>> 
>>> On Wed, Oct 29, 2014 at 12:35 PM, Doyley, Marvin M.
>>>  wrote:
>>>> 
>>>> Hi there,
>>>> 
>>>> I have been play  with julia the last couple of weeks and have been having
>>>> some issues when I try to use it in org-babel
>>>> 
>>>> More specifically, It get the following error
>>>> 
>>>> ERROR: unsupported or misplaced expression using
>>>> in _start at ./client.jl:394
>>>> in _start at /julia/usr/lib/julia/sys.dylib
>>>> 
>>>> 
>>>> When I execute the following code block
>>>> 
>>>> #+begin_src julia
>>>> using Winston
>>>> #+end_src
>>> 
>>> I get the same thing, though both of these variations work for me:
>>> 
>>> #+begin_src julia
>>> using Winston
>>> 1 + 1
>>> #+end_src
>>> 
>>> #+RESULTS:
>>> : 2
>>> 
>>> #+begin_src julia :results output
>>> using Winston
>>> #+end_src
>>> 
>>> Hope this helps,
>>> Ista
>>>> 
>>>> #+RESULTS:
>>>> 
>>>> I should mention, that everything works perfectly in eshell or when I
>>>> execute simple code blocks like
>>>> 
>>>> 
>>>> #+begin_src julia
>>>> linspace(0,10,5)
>>>> #+end_src
>>>> 
>>>> #+RESULTS:
>>>> |   0 |
>>>> | 2.5 |
>>>> |   5 |
>>>> | 7.5 |
>>>> |  10 |
>>>> 
>>>> 
>>>> Does Any body know how to resolve this issue.
>>>> 
>>>> Cheers,
>>>> M




Re: [O] Trouble using julia with org-babel

2014-10-29 Thread Doyley, Marvin M.
I am using release-0.3.0 what version are you using. I am also using ob-julia.el
Cheers,
M

Sent from my iPad

> On Oct 29, 2014, at 9:43 PM, Ista Zahn  wrote:
> 
> On Wed, Oct 29, 2014 at 12:35 PM, Doyley, Marvin M.
>  wrote:
>> 
>> Hi there,
>> 
>> I have been play  with julia the last couple of weeks and have been having
>> some issues when I try to use it in org-babel
>> 
>> More specifically, It get the following error
>> 
>> ERROR: unsupported or misplaced expression using
>> in _start at ./client.jl:394
>> in _start at /julia/usr/lib/julia/sys.dylib
>> 
>> 
>> When I execute the following code block
>> 
>> #+begin_src julia
>> using Winston
>> #+end_src
> 
> I get the same thing, though both of these variations work for me:
> 
> #+begin_src julia
> using Winston
> 1 + 1
> #+end_src
> 
> #+RESULTS:
> : 2
> 
> #+begin_src julia :results output
>  using Winston
> #+end_src
> 
> Hope this helps,
> Ista
>> 
>> #+RESULTS:
>> 
>> I should mention, that everything works perfectly in eshell or when I
>> execute simple code blocks like
>> 
>> 
>> #+begin_src julia
>> linspace(0,10,5)
>> #+end_src
>> 
>> #+RESULTS:
>> |   0 |
>> | 2.5 |
>> |   5 |
>> | 7.5 |
>> |  10 |
>> 
>> 
>> Does Any body know how to resolve this issue.
>> 
>> Cheers,
>> M



[O] Trouble using julia with org-babel

2014-10-29 Thread Doyley, Marvin M.

Hi there,

I have been play  with julia the last couple of weeks and have been having some 
issues when I try to use it in org-babel

More specifically, It get the following error

ERROR: unsupported or misplaced expression using
 in _start at ./client.jl:394
 in _start at /julia/usr/lib/julia/sys.dylib


When I execute the following code block

#+begin_src julia
using Winston
#+end_src

#+RESULTS:

I should mention, that everything works perfectly in eshell or when I execute 
simple code blocks like


#+begin_src julia
linspace(0,10,5)
#+end_src

#+RESULTS:
|   0 |
| 2.5 |
|   5 |
| 7.5 |
|  10 |


Does Any body know how to resolve this issue.

Cheers,
M


Re: [O] inline image size

2014-10-28 Thread Doyley, Marvin M.
Hi there,

I found the solution 
http://lists.gnu.org/archive/html/emacs-orgmode/2014-10/msg00038.html

cheers,
M
On Oct 28, 2014, at 9:16 PM, Doyley, Marvin M.  wrote:

> Hi there,
> 
> Does anybody know how to change the size of inline images in org ?
> 
> I would like to do this using something like #+attr :with 200
> 
> thanks
> M




[O] inline image size

2014-10-28 Thread Doyley, Marvin M.
Hi there,

Does anybody know how to change the size of inline images in org ?

I would like to do this using something like #+attr :with 200

thanks
M



Re: [O] [RFC] Change property drawer syntax

2014-10-15 Thread Rainer M Krug
Nicolas Goaziou  writes:

> Hello,
>
> Rainer M Krug  writes:
>
>
>>> Moreover, node properties' keys can only contain non-whitespace
>>> characters and cannot end with a plus sign (which is used for
>>> accumulation). 
>>
>> This is problematic for me, as I am using it extensively in the case
>> of :header-args.
>>
>> I set file wide header-arg and add the ones which have to change per
>> subtree / node:
>>
>> #+Property: header-args :tangle-mode (identity #o444)
>> #+PROPERTY: header-args+ :tangle no
>> #+PROPERTY: header-args+ :mkdirp yes
>> #+PROPERTY: header-args+ :exports both
>> #+PROPERTY: header-args+ :comments both
>> #+PROPERTY: header-args+ :padline no
>> #+PROPERTY: header-args+ :eval no-export
>
> I wasn't clear. A property key cannot end with a plus sign, because the
> plus sign has another meaning. IOW, "header-args+" is perfectly valid,
> but the true property key is "header-args", "+" meaning that values
> should be accumulated.

OK - thanks for the clarification.

Then I am happy with the proposal.

Rainer

>
> This behaviour is unchanged.
>
>
> Regards,

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpPWf8r6ERdD.pgp
Description: PGP signature


Re: [O] [RFC] Change property drawer syntax

2014-10-15 Thread Rainer M Krug
Nicolas Goaziou  writes:

> Hello,

Hi

I am not using org that much for schedulig, todo items, and other
similar topics, but mainly for literate programming, so I will comment
From that perspective.

>
> As discussed previously, I would like to modify property drawers syntax.
> The change is simple: they must be located right after a headline and
> its planning line, if any.  Therefore the following cases are valid
>
>   * Headline
> :PROPERTIES:
> :KEY: value
> :END:
>
>   * Headline
> SCHEDULED: <2014-10-14 mar.>
> :PROPERTIES:
> :KEY: value
> :END:
>
> but, in the following case, the scheduled keyword will not be recognized
>
>   * Headline
> :PROPERTIES:
> :KEY: value
> :END:
> SCHEDULED: <2014-10-14 mar.>
>
> When not empty, they also have to contain only node properties.

No problems so far from my side.

> Moreover, node properties' keys can only contain non-whitespace
> characters and cannot end with a plus sign (which is used for
> accumulation). 

This is problematic for me, as I am using it extensively in the case
of :header-args.

I set file wide header-arg and add the ones which have to change per
subtree / node:

--8<---cut here---start->8---
#+Property: header-args :tangle-mode (identity #o444)
#+PROPERTY: header-args+ :tangle no
#+PROPERTY: header-args+ :mkdirp yes
#+PROPERTY: header-args+ :exports both
#+PROPERTY: header-args+ :comments both
#+PROPERTY: header-args+ :padline no
#+PROPERTY: header-args+ :eval no-export

* To be tangled but *never* executed
:PROPERTIES:
:header-args+: :eval never
:END:
** some code
:PROPERTIES:
:comments: no
:header-args+: :tangle ./code.R
:header-args+: :padline no
:header-args+: :no-expand TRUE
:header-args+: :comments no
:END:
#+begin_src R 
## some code
#+end_src

* Not to be tangled but can be executed
#+begin_src R 
## some other code
#+end_src
--8<---cut here---end--->8---

So if I understand you correctly, this would break this approach, which
I think is very valuable in literate programming and reproducible research.

> Value can contain anything but a newline character.
>
> Thus, the following property drawer is invalid
>
>   * Headline
> :PROPERTIES:
> :KEY: value
> Some text.
> :END:
>
> Any invalid property drawer becomes de facto a regular drawer, with
> "PROPERTIES" as its name.
>
> Besides defining exactly the syntax of property drawers, it should also
> make the property API faster in some cases. Indeed, there's no need to
> search through entire (possibly huge) sections in order to find
> properties attached to a headline.
>
> However, it will break some Org documents. In particular, TODO-states
> changes are usually logged before any drawer, including properties
> drawers. The following function repairs them.

At the moment, I do not see any way on how I can replace the + in the
properties drawer - or am I missing something very basic here?

Cheers,

Rainer

>
>   (defun org-repair-property-drawers ()
> "Fix properties drawers in current buffer.
>   Ignore non Org buffers."
> (when (eq major-mode 'org-mode)
>   (org-with-wide-buffer
>(goto-char (point-min))
>(let ((case-fold-search t)
>  (inline-re (and (featurep 'org-inlinetask)
>  (concat (org-inlinetask-outline-regexp)
>  "END[ \t]*$"
>  (org-map-entries
>   (lambda ()
> (unless (and inline-re (org-looking-at-p inline-re))
>   (save-excursion
> (let ((end (save-excursion (outline-next-heading) (point
>   (forward-line)
>   (when (org-looking-at-p org-planning-line-re) 
> (forward-line))
>   (when (and (< (point) end)
>  (not (org-looking-at-p org-property-drawer-re))
>  (save-excursion
>(re-search-forward org-property-drawer-re end 
> t)))
> (insert (delete-and-extract-region
>  (match-beginning 0)
>  (min (1+ (match-end 0)) end)))
> (unless (bolp) (insert "\n"
>
> Internally, changes are somewhat invasive, as they include a rewrite of
> almost all the property API. They also alter clocking, tags, todo
> keywords, logging, initialization, hopefully in an invisible manner.
>
> I pushed a new branch, "top-properties" in the repository for code
> review and testing. It includes unit tests, documentation and an
> ORG-NEWS entry.
>
> Feedback welcome.
>
>
> Regards,

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpKf8kM_FDLO.pgp
Description: PGP signature


Re: [O] Make * bold?

2014-10-13 Thread Rainer M Krug
Andreas Leha  writes:

> Hi Rainer,
>
> Rainer M Krug  writes:
>
>> Andrea Rossetti  writes:
>>
>>> Rainer M Krug  krugs.de> writes:
>>>> I would like to make three stars bold - is this possible? I have the
>>>> following table and at the moment, I get what is in the latex
>>>> column. But I would like to have what is in the last column.
>>>> 
>>>> | org | latex| what I would like |
>>>> | *3.96e-21 *** * | \textbf{3.96e-21 **} *   | \textbf{3.96e-21 ***} |
>>>> ...
>>>> 
>>>> Any suggestions?
>>>
>>> Hi! using the "pretty entity" \ast{} works for me in HTML and PDF:
>>>
>>> | *3.96e-21 \ast{}\ast{}\ast{}*  |
>>>
>>> Does it work for you too? Regards, Andrea
>>
>> Thanks - it does, indeed. Strange that it works for both export
>> backends.
>>
>>
>> But there are a few formating issues with this:
>>
>> 1) in tex, the spacing between two is different to the spacing between
>> three
>> 2) in html, the asterix are at the bottom and
>> 3) it is not very readable in org.
>
> To help with 3) have a look at http://orgmode.org/manual/Special-symbols.html 
> (esp. C-c C-x \)

Thanks - good point.

Rainer

>
> Best,
> Andreas
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpWetaUzhTHC.pgp
Description: PGP signature


Re: [O] Make * bold?

2014-10-13 Thread Rainer M Krug
Andrea Rossetti  writes:

> Rainer M Krug  krugs.de> writes:
>> I would like to make three stars bold - is this possible? I have the
>> following table and at the moment, I get what is in the latex
>> column. But I would like to have what is in the last column.
>> 
>> | org | latex| what I would like |
>> | *3.96e-21 *** * | \textbf{3.96e-21 **} *   | \textbf{3.96e-21 ***} |
>> ...
>> 
>> Any suggestions?
>
> Hi! using the "pretty entity" \ast{} works for me in HTML and PDF:
>
> | *3.96e-21 \ast{}\ast{}\ast{}*  |
>
> Does it work for you too? Regards, Andrea

Thanks - it does, indeed. Strange that it works for both export
backends.


But there are a few formating issues with this:

1) in tex, the spacing between two is different to the spacing between
three
2) in html, the asterix are at the bottom and
3) it is not very readable in org.

Thanks,

Rainer

>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpCmXKOTmQdG.pgp
Description: PGP signature


[O] pgfplotstable and org -WAS: Make * bold or use colour for export to html and LaTeX

2014-10-13 Thread Rainer M Krug
Aaron Ecay  writes:

> Hi Rainer,
>
> 2014ko urriak 10an, Rainer M Krug-ek idatzi zuen:
>> 
>> Hi
>> 
>> I want to highlight the cells in the table below with "***" by using
>> color red for the font, "**' by using green for the font, ... or, if not 
>> possible, bold. Is any of this possible?
>> 
>> The table is generated in R, so the ascii package might help (just
>> thinking about it while typing)?
>
> If you’re exporting only to Latex, an option might be the pgfplotstable
> package.  Here’s some examples from tex.stackexchange:
>
> https://tex.stackexchange.com/questions/100458/pgfplotstable-conditional-post-processing-of-cell-content-on-a-per-column-basis
> https://tex.stackexchange.com/questions/126959/conditional-format-for-correlation-table
> https://tex.stackexchange.com/questions/156168/conditional-formatting-rounding-and-postprocessing-of-a-column-in-pgfplotstable

I must say pgfplotstable looks interesting but also quite complex.

Are there any examples on how I can use pgfplotstable within the org
context (apart from one huge LaTeX code block)?

Thanks,

Rainer
-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpUP97VPazet.pgp
Description: PGP signature


[O] left aligned changes to right alignment in table after adding one row - possible bug?

2014-10-13 Thread Rainer M Krug

#+PROPERTY: header-args :exports both

* Changing alignment when one row is added
Despite of all values are strings, the alignment changes in the below
example. Is this a bug or am I missing something?

Thanks,

Rainer

** Here it works
The column pm and pb are left aligned as expected for strings (correct?).

#+begin_src R :colnames yes :rownames yes 
x <- structure(c("-1.358", "-1.957", "-1.752", "-1.773", "-1.886", 
"-1.948", "-1.754", "-1.730", "-1.859", "-1.900", "4.757", "5.708", 
"5.419", "5.408", "5.493", "5.581", "5.250", "5.193", "5.329", 
"5.396", "", "*0.000 *** *", "*0.034 **", "0.411", "*0.002 ***", 
"0.376", "0.055 .", "0.134", "*0.012 **", "0.243", "", "*0.000 *** *", 
"0.072 .", "0.833", "0.228", "0.549", "0.061 .", "0.756", "0.128", 
"0.916", "", "*0.000 *** *", "*0.048 **", "0.938", "0.389", "0.640", 
"*0.044 **", "0.598", "0.217", "0.941"), .Dim = c(10L, 5L), .Dimnames = list(
c("Quercus robur - single", "Quercus robur - 95", "Quercus robur - 90", 
"Quercus robur - 85", "Quercus robur - 80", "Quercus robur - 75", 
"Quercus robur - 70", "Quercus robur - 65", "Quercus robur - 60", 
"Quercus robur - 55"), c("slope", "intercept", "p", "pm", 
"pb")))

head(x, 5)
#+end_src

#+RESULTS:
||  slope | intercept | p| pm   | 
pb   |
|++---+--+--+--|
| Quercus robur - single | -1.358 | 4.757 |  |  |   
   |
| Quercus robur - 95 | -1.957 | 5.708 | *0.000 *** * | *0.000 *** * | 
*0.000 *** * |
| Quercus robur - 90 | -1.752 | 5.419 | *0.034 **| 0.072 .  | 
*0.048 **|
| Quercus robur - 85 | -1.773 | 5.408 | 0.411| 0.833| 
0.938|
| Quercus robur - 80 | -1.886 | 5.493 | *0.002 ***   | 0.228| 
0.389|

** Here it doesn't
By adding row 6, pm and pb become right aligned. This can also be
reproduced by only using columns 5:7 (~x[5:7,]~ instead of ~head(x,6)~).

#+begin_src R :colnames yes :rownames yes 
x <- structure(c("-1.358", "-1.957", "-1.752", "-1.773", "-1.886", 
"-1.948", "-1.754", "-1.730", "-1.859", "-1.900", "4.757", "5.708", 
"5.419", "5.408", "5.493", "5.581", "5.250", "5.193", "5.329", 
"5.396", "", "*0.000 *** *", "*0.034 **", "0.411", "*0.002 ***", 
"0.376", "0.055 .", "0.134", "*0.012 **", "0.243", "", "*0.000 *** *", 
"0.072 .", "0.833", "0.228", "0.549", "0.061 .", "0.756", "0.128", 
"0.916", "", "*0.000 *** *", "*0.048 **", "0.938", "0.389", "0.640", 
"*0.044 **", "0.598", "0.217", "0.941"), .Dim = c(10L, 5L), .Dimnames = list(
c("Quercus robur - single", "Quercus robur - 95", "Quercus robur - 90", 
"Quercus robur - 85", "Quercus robur - 80", "Quercus robur - 75", 
"Quercus robur - 70", "Quercus robur - 65", "Quercus robur - 60", 
"Quercus robur - 55"), c("slope", "intercept", "p", "pm", 
"pb")))

head(x, 6)
#+end_src

#+RESULTS:
||  slope | intercept | p|   pm |   
pb |
|++---+--+--+--|
| Quercus robur - single | -1.358 | 4.757 |  |  |   
   |
| Quercus robur - 95 | -1.957 | 5.708 | *0.000 *** * | *0.000 *** * | 
*0.000 *** * |
| Quercus robur - 90 | -1.752 | 5.419 | *0.034 **|  0.072 . |   
 *0.048 ** |
| Quercus robur - 85 | -1.773 | 5.408 | 0.411|0.833 |   
 0.938 |
| Quercus robur - 80 | -1.886 | 5.493 | *0.002 ***   |0.228 |   
 0.389 |
| Quercus robur - 75 | -1.948 | 5.581 | 0.376|0.549 |   
  0.64 |




-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpwumJFT4rM9.pgp
Description: PGP signature


[O] Make * bold?

2014-10-13 Thread Rainer M Krug
Hi

I would like to make three stars bold - is this possible? I have the
following table and at the moment, I get what is in the latex
column. But I would like to have what is in the last column.

| org | latex| what I would like |
| *3.96e-21 *** * | \textbf{3.96e-21 **} *   | \textbf{3.96e-21 ***} |
| *4.11e-01   | \textbf{4.11e-01 \textbf{*}} | \textbf{4.11e-01 ***} |
| *2.07e-03 ***   | \textbf{2.07e-03 **} | \textbf{2.07e-03 **}  |
| *3.43e-02 **| \textbf{3.43e-02 *}  | \textbf{3.43e-02 *}   |

Line 1 and two are just tries to see if there iss a difference with or
without space *there is, but none works).

Line 3 and four, i.e. two and one stars, works as expected.

Any suggestions on how I can get the three stars in bold? I could
obviously use \textbf{} in the table, but I also export the document
to html - so this would not be an option.

Any suggestions?

Thanks,

Rainer
-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp4wIsWraE2x.pgp
Description: PGP signature


Re: [O] Downloadable mailing list archive?

2014-10-13 Thread Rainer M Krug
Bastien  writes:

> Hi Rainer,
>
> Rainer M Krug  writes:
>
>> is there a downloadable mailing list archive in maildir format for
>> org-mode?
>
> ftp://lists.gnu.org/emacs-orgmode/
>
> HTH,

Thanks - But as I found gmane search in gnus, I don't have to download
them anymore.

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpig6MKeQOyM.pgp
Description: PGP signature


Re: [O] Make * bold or use colour for export to html and LaTeX

2014-10-10 Thread Rainer M Krug
Andreas Leha  writes:

> Hi Rainer,
>
> Rainer M Krug  writes:
>> Hi
>>
>> I want to highlight the cells in the table below with "***" by using
>> color red for the font, "**' by using green for the font, ... or, if not 
>> possible, bold. Is any of this possible?
>>
>> The table is generated in R, so the ascii package might help (just
>> thinking about it while typing)?
>>
>> Thanks,
>>
>> Rainer 
>>
>> ||  slope | intercept | p |  
>>  pm |pb |
>> |++---+---+--+---|
>> | quercus_robur.single   | -1.358 |  4.76 |   |  
>> |   |
>> | quercus_robur.95   | -1.957 |  5.71 | 3.96e-21 ***   | 
>> 7.47e-07 *** |  7.60e-09 *** |
>> | quercus_robur.90   | -1.752 |  5.42 | 3.43e-02 *|   
>> 7.18e-02 . |4.79e-02 * |
>> | quercus_robur.85   | -1.773 |  5.41 | 4.11e-01  | 
>> 8.33e-01 |  9.38e-
>
>
> I am not sure to understand your question correctly, but if the table is
> R generated anyway, why not use R to provide the formatting for org?

You do - bold or in colour. 

>
>
> Like -- as a start -- this function, that does the simplest of those and
> replaces "***" with bold:

This looks very promising, but I would also like to keep the stars, so I
would like to have "3.96e-21 ***" in bold (or even in color`). But I am
going to start with your example.

Thanks,

Rainer
 

>
> boldpattern <- " \\*\\*\\*$"
> tbl <- apply(tbl, 2,
>  function(x) ifelse(grepl(boldpattern, x),
> paste0("*", gsub(boldpattern, "", x), "*"),
> x))
>
>
> Here as full example in action:
>
> ## -- ##
> ## create a table ##
> ## -- ##
>
> ## from ?lm
> ctl <- c(4.17,5.58,5.18,6.11,4.50,4.61,5.17,4.53,5.33,5.14)
> trt <- c(4.81,4.17,4.41,3.59,5.87,3.83,6.03,4.89,4.32,4.69)
> group <- gl(2, 10, 20, labels = c("Ctl","Trt"))
> weight <- c(ctl, trt)
> lm.D9 <- lm(weight ~ group)
> lm.D90 <- lm(weight ~ group - 1) # omitting intercept
> ## extract the coefficients
> tbl <- summary(lm.D90)$coefficients
> ## add the signif codes
> tbl[,4] <- paste(tbl[,4],
>  symnum(tbl[,4], corr = FALSE, na = FALSE, 
> cutpoints = c(0, 0.001, 0.01, 0.05, 0.1, 1), 
> symbols = c("***", "**", "*", ".", " ")))
> tbl
>
>
> ## -- ##
> ## make them 'org-bold'   ##
> ## -- ##
> boldpattern <- " \\*\\*\\*$"
> tbl <- apply(tbl, 2,
>  function(x) ifelse(grepl(boldpattern, x),
> paste0("*", gsub(boldpattern, "", x), "*"),
> x))
> tbl
>
>
> HTH,
> Andreas
>
> PS: The usual "don't use the signif.codes" applies.
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpudQua4IYue.pgp
Description: PGP signature


[O] Make * bold or use colour for export to html and LaTeX

2014-10-10 Thread Rainer M Krug
Hi

I want to highlight the cells in the table below with "***" by using
color red for the font, "**' by using green for the font, ... or, if not 
possible, bold. Is any of this possible?

The table is generated in R, so the ascii package might help (just
thinking about it while typing)?

Thanks,

Rainer 

--8<---cut here---start->8---
||  slope | intercept | p |   
pm |pb |
|++---+---+--+---|
| quercus_robur.single   | -1.358 |  4.76 |   | 
 |   |
| quercus_robur.95   | -1.957 |  5.71 | 3.96e-21 ***   | 7.47e-07 
*** |  7.60e-09 *** |
| quercus_robur.90   | -1.752 |  5.42 | 3.43e-02 *|   7.18e-02 
. |4.79e-02 * |
| quercus_robur.85   | -1.773 |  5.41 | 4.11e-01  | 
8.33e-01 |  9.38e-
--8<---cut here---end--->8---

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpT5ZXn0f3Z0.pgp
Description: PGP signature


Re: [O] [BUG][babel] Tangling into directories does not add directories to org file

2014-10-10 Thread Rainer M Krug
Aaron Ecay  writes:

> Hi Rainer,
>
> 2014ko urriak 9an, Rainer M Krug-ek idatzi zuen:
>> 
>> I'd like to ping this as I think it
>> is an important bug. It e.g. make debugging of R packages, whose source
>> is in org, more difficult, (the .R files are tangled into ./R/) as ess
>> does not find the source of the R code in R as it uses the links in the
>> comments to find the org file.
>
> FWIW, I agree with you, but personally it’s hard to see myself having
> time to address this in the near future.  Maybe you could try making a
> patch yourself.  It sounds like the sort of thing that should be
> self-contained and easy to fix (famous last words, I know...)

It looks like this - but I am always shocked by the number of brackets
in lisp.

The "problem" is in the function =defun org-babel-spec-to-string (spec)=
in the file =lisp/ob-tangle.R= in the section

#+begin_src emacs-lisp 
  (file (if org-babel-tangle-use-relative-file-links
   (file-relative-name (nth 1 spec))
 (nth 1 spec)))
 (link (let ((link (nth 2 spec)))
 (if org-babel-tangle-use-relative-file-links
 (when (string-match "^\\(file:\\|docview:\\)\\(.*\\)" link)
   (let* ((type (match-string 1 link))
  (path (match-string 2 link))
  (origpath path)
  (case-fold-search nil))
 (setq path (file-relative-name path))
 (concat type path)))
   link)))
#+end_src

the function file-relative-name (file-relative-name FILENAME &optional
DIRECTORY). If I am not mistaken, the optional argument DIRECTORY
needs to be set to the directory of the tangled file. I assume it is
not set at the moment. 

But I have no idea how to get this path and how to pass it to the function.

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpQwXXN5FTEX.pgp
Description: PGP signature


Re: [O] [BUG][babel] Tangling into directories does not add directories to org file

2014-10-10 Thread Rainer M Krug
d handed on to other users.
- documentation to the functions can be added using roxygen which can
  easily be translated into .rd files


* Final words
I hope this clarifies my approach.

For me, this is a very "natural" approach, as I like to use packages
and capsulate everything in environments / packages, and it seems very
"clean" to me to define the core of the analysis as functions in
=./R/*.R= files, the variables in =./data/*= files and the actual
analysis as mainly a few function calls.

If you have any further questions, please go on and ask.

Cheers,

Rainer





>
> Online Thu, Oct 9, 2014 at 7:37 AM, Rainer M Krug  wrote:
>>
>> I'd like to ping this as I think it
>> is an important bug. It e.g. make debugging of R packages, whose source
>> is in org, more difficult, (the .R files are tangled into ./R/) as ess
>> does not find the source of the R code in R as it uses the links in the
>> comments to find the org file.
>>
>> Temporary solution: I created a link to the org file in the ./R directory.
>>
>> Cheers,
>>
>> Rainer
>>
>> Rainer M Krug  writes:
>>
>>> When in the tangling taerget a directory is specified, this is not
>>> reflected in the comments in the tangled file when comments are set to
>>> include links:
>>>
>>> ,
>>> |* `link' The code block is wrapped in comments which contain
>>> |  pointers back to the original Org file from which the code was
>>> |  tangled.
>>> `
>>>
>>> In the org file =prodMixStands.org=:
>>>
>>> ,
>>> | :PROPERTIES:
>>> | :header-args+: :tangle ./R/update.cache.R
>>> | :END:
>>> | #+begin_src R
>>> | test
>>> | #+end_src
>>> `
>>>
>>> results in the file =update.cache.R= in a link to the file
>>> =prodMixStands.org= and not =./../prodMixstands.org=:
>>>
>>> ,
>>> |  ## [[file:prodMixStands.org::*Begin][Begin:1]]
>>> `
>>>
>>> This is particularly bad when using ess and developer mode to develop a
>>> package.
>>>
>>> Cheers,
>>>
>>> Rainer
>>
>> --
>> Rainer M. Krug
>> email: Rainerkrugsde
>> PGP: 0x0F52F982
>>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgphIVT0KQrBP.pgp
Description: PGP signature


Re: [O] [NEW PATCH] read.table in variable transfer caused sometimes "function not found" error - small change

2014-10-10 Thread Rainer M Krug
Aaron Ecay  writes:

> Hello,
>
> Thanks Rainer for this patch, and thanks Chuck for the discussion.  It
> appears that “use utils::read.table” is the official advice from
> devtools’s maintainer:
> https://github.com/hadley/devtools/issues/336#issuecomment-23517837.
>
> I’ve pushed the patch to the master branch.  

Thanks.

> I reworded the commit message slightly.  I also moved the note about
> utils:: from a docstring to a comment in the ob-R.el file.  This is
> based on a feeling that it’s an implementation detail that is less
> useful for elisp programmers (primary consumers of docstrings), but
> necessary for anyone working on ob-R’s internals (who will read the
> file itself).

I agree with this, but as an R programmer, I would rather read the
docstring via C-h v then read in the elisp code (more likely for the
elisp programmer). But Anyway - anybody who is likely to modify this
variable, likely knows what utils::read.table() means - so no objections.

But wait - I think I get your point now. You are right - the source code
may be the better place for this comment.
 
Cheers,

Rainer

>
> Thanks again,

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpn8IT77QMB9.pgp
Description: PGP signature


Re: [O] [BUG][babel] Tangling into directories does not add directories to org file

2014-10-09 Thread Rainer M Krug

I'd like to ping this as I think it
is an important bug. It e.g. make debugging of R packages, whose source
is in org, more difficult, (the .R files are tangled into ./R/) as ess
does not find the source of the R code in R as it uses the links in the
comments to find the org file.

Temporary solution: I created a link to the org file in the ./R directory.

Cheers,

Rainer

Rainer M Krug  writes:

> When in the tangling taerget a directory is specified, this is not
> reflected in the comments in the tangled file when comments are set to
> include links:
>
> ,
> |* `link' The code block is wrapped in comments which contain
> |  pointers back to the original Org file from which the code was
> |  tangled.
> `
>
> In the org file =prodMixStands.org=:
>
> ,
> | :PROPERTIES:
> | :header-args+: :tangle ./R/update.cache.R
> | :END:
> | #+begin_src R 
> | test
> | #+end_src
> `
>
> results in the file =update.cache.R= in a link to the file
> =prodMixStands.org= and not =./../prodMixstands.org=:
>
> ,
> |  ## [[file:prodMixStands.org::*Begin][Begin:1]]
> `
>
> This is particularly bad when using ess and developer mode to develop a
> package.
>
> Cheers,
>
> Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982



Re: [O] [NEW PATCH] read.table in variable transfer caused sometimes "function not found" error - small change

2014-10-09 Thread Rainer M Krug
*Please ignore the previous patch*

This updated patch contains the correct documentation and commit message

Sorry about the mistake,

From 58cb8521d4d4b620b0c5210a9b7232f99f7c720c Mon Sep 17 00:00:00 2001
From: "Rainer M. Krug" 
Date: Mon, 6 Oct 2014 13:48:49 +0200
Subject: [PATCH] ob-R.el: Add package name to read.table call

* lisp/ob-R.el:
(ob-R-transfer-variable-table-with-header): Add package name to call
of R function read.table (now utils::read.table).  This clarifies the
call as well as avoids 'could not find function' error in R under
certain conditions.

(ob-R-transfer-variable-table-without-header): Add package name to call
of R function read.table (now utils::read.table).  This clarifies the
call as well as avoids 'could not find function' error in R under
certain conditions.
---
 lisp/ob-R.el | 14 ++
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/lisp/ob-R.el b/lisp/ob-R.el
index ea33031..0b24a64 100644
--- a/lisp/ob-R.el
+++ b/lisp/ob-R.el
@@ -101,7 +101,7 @@ this variable.")
  con <- textConnection(
%S
  )
- res <- read.table(
+ res <- utils::read.table(
con,
header= %s,
row.names = %s,
@@ -112,14 +112,17 @@ this variable.")
  res
})"
   "R code used to transfer a table defined as a variable from org to R.
-This function is used when the table contains a header.")
+This function is used when the table contains a header. The usage
+of utils::read.table() ensures that the command read.table() can
+be found even in circumstances when the utils package is not in
+the search path from R.")
 
 (defconst ob-R-transfer-variable-table-without-header
   "%s <- local({
  con <- textConnection(
%S
  )
- res <- read.table(
+ res <- utils::read.table(
con,
header= %s,
row.names = %s,
@@ -132,7 +135,10 @@ This function is used when the table contains a header.")
  res
})"
   "R code used to transfer a table defined as a variable from org to R.
-This function is used when the table does not contain a header.")
+This function is used when the table does not contain a
+header. The usage of utils::read.table() ensures that the command
+read.table() can be found even in circumstances when the utils
+package is not in the search path from R.")
 
 (defun org-babel-expand-body:R (body params &optional graphics-file)
   "Expand BODY according to PARAMS, return the expanded body."
-- 
2.1.2

Rainer


Rainer M Krug  writes:

> "Charles C. Berry"  writes:
>
>> On Wed, 8 Oct 2014, Rainer M Krug wrote:
>>
>>> "Charles C. Berry"  writes:
>>>
>>>> On Wed, 8 Oct 2014, Rainer M Krug wrote:
>>>>
>>>>> "Charles C. Berry"  writes:
>>>>>
>>>>>> On Mon, 6 Oct 2014, Rainer M Krug wrote:
>>>>>>
>>>>>>> Hi
>>>>>>>
>>>>>>> The variable transfer of tables from org to R caused sometimes 'could
>>>>>>> not find function "read.table"' errors (e.g. when the file was tangled
>>>>>>> into a ./data directory which was loaded by the function
>>>>>>> devtools::load_all("./")). This can easily be fixed by adding the 
>>>>>>> package
>>>>>>> name to the call in R, i.e. replacing =read.table()= with
>>>>>>> =utils::read.table()= which is done in this patch.
>>>>>>
>>>>>> It does fix that one case.
>>>>>>
>>>>>> But I wonder if that is the best way.
>>>>>>
>>>>>> The heart of the matter is that load_all eventually calls sys.source,
>>>>>> which can be persnickety about finding objects on the search path. See
>>>>>> ?sys.source.
>>>>>>
>>>>>> If the src block you tangle to ./data/ has any code that uses any
>>>>>> other objects from utils, stats, datasets or whatever, you will be in
>>>>>> the same pickle.
>>>>>
>>>>> Exactly - that is true. But it is the same when putting this in a
>>>>> package (as far as I am aware).
>>>>>
>>>>
>>>> Do you mean that putting `x <- rnorm(10)' into a data/*.R file will
>>>> fail when you try to build and check?
>>>>
>>>> In fact, `R CMD build' will execute it and save the result as a
>>>> data/*.rda file. And check will go through.
>>>>
>>>> devtools::load_all (calling load_data) fails to do

[O] [NEW PATCH] read.table in variable transfer caused sometimes "function not found" error - small change

2014-10-09 Thread Rainer M Krug
"Charles C. Berry"  writes:

> On Wed, 8 Oct 2014, Rainer M Krug wrote:
>
>> "Charles C. Berry"  writes:
>>
>>> On Wed, 8 Oct 2014, Rainer M Krug wrote:
>>>
>>>> "Charles C. Berry"  writes:
>>>>
>>>>> On Mon, 6 Oct 2014, Rainer M Krug wrote:
>>>>>
>>>>>> Hi
>>>>>>
>>>>>> The variable transfer of tables from org to R caused sometimes 'could
>>>>>> not find function "read.table"' errors (e.g. when the file was tangled
>>>>>> into a ./data directory which was loaded by the function
>>>>>> devtools::load_all("./")). This can easily be fixed by adding the package
>>>>>> name to the call in R, i.e. replacing =read.table()= with
>>>>>> =utils::read.table()= which is done in this patch.
>>>>>
>>>>> It does fix that one case.
>>>>>
>>>>> But I wonder if that is the best way.
>>>>>
>>>>> The heart of the matter is that load_all eventually calls sys.source,
>>>>> which can be persnickety about finding objects on the search path. See
>>>>> ?sys.source.
>>>>>
>>>>> If the src block you tangle to ./data/ has any code that uses any
>>>>> other objects from utils, stats, datasets or whatever, you will be in
>>>>> the same pickle.
>>>>
>>>> Exactly - that is true. But it is the same when putting this in a
>>>> package (as far as I am aware).
>>>>
>>>
>>> Do you mean that putting `x <- rnorm(10)' into a data/*.R file will
>>> fail when you try to build and check?
>>>
>>> In fact, `R CMD build' will execute it and save the result as a
>>> data/*.rda file. And check will go through.
>>>
>>> devtools::load_all (calling load_data) fails to do that. Which is why
>>> I think this is a devtools issue.
>>
>> OK - point taken. But I still think that the =utils::read.table()= would
>> not hurt, rather make the variable transfer safer.
>>
>
> What you want to change is in a defconst. So, the user can override
> with a file-local version.
>
> So, making the change really is harmless.
>
> Maybe add a note to the docstring to say that using
> utils::read.table' assures that `read.table' always can be found just
> in case anyone ever asks.

OK - done in attached patch.

Rainer
From 1eadbf6b44b8fc2fa5af29ea483383e9d137d19e Mon Sep 17 00:00:00 2001
From: "Rainer M. Krug" 
Date: Mon, 6 Oct 2014 13:48:49 +0200
Subject: [PATCH] ob-R.el: Add package name to read.table call

* lisp/ob-R.el:
(ob-R-transfer-variable-table-with-header): Add package name to call
of R function read.table (now utils::read.table).  This clarifies the
call as well as avoids 'could not find function' error in R under
certain conditions.
---
 lisp/ob-R.el | 9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/lisp/ob-R.el b/lisp/ob-R.el
index ea33031..a64b647 100644
--- a/lisp/ob-R.el
+++ b/lisp/ob-R.el
@@ -101,7 +101,7 @@ this variable.")
  con <- textConnection(
%S
  )
- res <- read.table(
+ res <- utils::read.table(
con,
header= %s,
    row.names = %s,
@@ -112,14 +112,17 @@ this variable.")
  res
})"
   "R code used to transfer a table defined as a variable from org to R.
-This function is used when the table contains a header.")
+This function is used when the table contains a header. The usage
+of utils::read.table() ensures that the command read.table() can
+be found even in circumstances when the utils package is not in
+the search path from R.")
 
 (defconst ob-R-transfer-variable-table-without-header
   "%s <- local({
  con <- textConnection(
%S
  )
- res <- read.table(
+ res <- utils::read.table(
con,
header= %s,
row.names = %s,
-- 
2.1.2


>
> Chuck
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpxZoxdTdgd0.pgp
Description: PGP signature


Re: [O] [PATCH] read.table in variable transfer caused sometimes "function not found" error - small change

2014-10-08 Thread Rainer M Krug
"Charles C. Berry"  writes:

> On Wed, 8 Oct 2014, Rainer M Krug wrote:
>
>> "Charles C. Berry"  writes:
>>
>>> On Mon, 6 Oct 2014, Rainer M Krug wrote:
>>>
>>>> Hi
>>>>
>>>> The variable transfer of tables from org to R caused sometimes 'could
>>>> not find function "read.table"' errors (e.g. when the file was tangled
>>>> into a ./data directory which was loaded by the function
>>>> devtools::load_all("./")). This can easily be fixed by adding the package
>>>> name to the call in R, i.e. replacing =read.table()= with
>>>> =utils::read.table()= which is done in this patch.
>>>
>>> It does fix that one case.
>>>
>>> But I wonder if that is the best way.
>>>
>>> The heart of the matter is that load_all eventually calls sys.source,
>>> which can be persnickety about finding objects on the search path. See
>>> ?sys.source.
>>>
>>> If the src block you tangle to ./data/ has any code that uses any
>>> other objects from utils, stats, datasets or whatever, you will be in
>>> the same pickle.
>>
>> Exactly - that is true. But it is the same when putting this in a
>> package (as far as I am aware).
>>
>
> Do you mean that putting `x <- rnorm(10)' into a data/*.R file will
> fail when you try to build and check?
>
> In fact, `R CMD build' will execute it and save the result as a
> data/*.rda file. And check will go through.
>
> devtools::load_all (calling load_data) fails to do that. Which is why
> I think this is a devtools issue.

OK - point taken. But I still think that the =utils::read.table()= would
not hurt, rather make the variable transfer safer.

Rainer

>
> Chuck
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpcHdQDfGFOb.pgp
Description: PGP signature


[O] [BUG][babel] Tangling into directories does not add directories to org file

2014-10-08 Thread Rainer M Krug
When in the tangling taerget a directory is specified, this is not
reflected in the comments in the tangled file when comments are set to
include links:

,
|* `link' The code block is wrapped in comments which contain
|  pointers back to the original Org file from which the code was
|  tangled.
`

In the org file =prodMixStands.org=:

,
| :PROPERTIES:
| :header-args+: :tangle ./R/update.cache.R
| :END:
| #+begin_src R 
| test
| #+end_src
`

results in the file =update.cache.R= in a link to the file
=prodMixStands.org= and not =./../prodMixstands.org=:

,
|  ## [[file:prodMixStands.org::*Begin][Begin:1]]
`

This is particularly bad when using ess and developer mode to develop a
package.

Cheers,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpRXgbpkJmeP.pgp
Description: PGP signature


Re: [O] [PATCH] read.table in variable transfer caused sometimes "function not found" error - small change

2014-10-08 Thread Rainer M Krug
"Charles C. Berry"  writes:

> On Mon, 6 Oct 2014, Rainer M Krug wrote:
>
>> Hi
>>
>> The variable transfer of tables from org to R caused sometimes 'could
>> not find function "read.table"' errors (e.g. when the file was tangled
>> into a ./data directory which was loaded by the function
>> devtools::load_all("./")). This can easily be fixed by adding the package
>> name to the call in R, i.e. replacing =read.table()= with
>> =utils::read.table()= which is done in this patch.
>
> It does fix that one case.
>
> But I wonder if that is the best way.
>
> The heart of the matter is that load_all eventually calls sys.source,
> which can be persnickety about finding objects on the search path. See
> ?sys.source.
>
> If the src block you tangle to ./data/ has any code that uses any
> other objects from utils, stats, datasets or whatever, you will be in
> the same pickle.

Exactly - that is true. But it is the same when putting this in a
package (as far as I am aware).

>
> Arguably, this is a bug in devtools::load_data. And maybe it would be
> better to beg the maintainer for a fix or an extension that
> accomodates your case.

I don't know - As far as I understand, it is the same behaviour as if it
would be loaded from a package - i.e. =library()= so it would not be a
bug but it emulates the behaviour of library(), which it should.

>
>>
>> In R the calls read.table and utils::read.table are interchangeable (the
>> second one is actually preferred) so no negative effects can be
>> expected.
>
> What if the user has intentionally masked read.table or the eventual
> package provides its own read.table?

I would not go there - I see the variable as a mechanism similar to the
call to library() in R, which should behave absolutely equal everywhere,
even if functions are re-defined. If one wants to have a non standard
behaviour in this step, one could always re-define the way variables are
transferred, or, the better approach, do it afterwards.

So I think the use of =utils::read.table()= is preferable to the risky
use of only =read.table=, exactly because of the re-definition issue you
raise.

So I would opt to apply this patch as it makes the variable transfer
more stable.

Cheers,

Rainer 

>
> HTH,
>
> Chuck
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpFvwcDz40GY.pgp
Description: PGP signature


Re: [O] real-time image rendering

2014-10-06 Thread Doyley, Marvin M.
I agree controlling the refresh rate make your approach better.
Thanks,
M
> Why better?  For which reason?

> Why not this:

> --8<---cut here---start->8---
> (add-hook 'org-babel-after-execute-hook
> (lambda ()
> (org-display-inline-images nil t)))
> ; more efficient with refresh == t
--8<---cut here---end--->8---

?

Best regards,
  Seb

-- 
Sebastien Vauban




[O] org-mac-link discovered!

2014-10-06 Thread Rainer M Krug
I just discovered  org-mac-link [1] and I must say *I love it*.

Just had to share this.

Cheers,

Rainer


Footnotes: 
[1]  [[http://orgmode.org/worg/org-contrib/org-mac-link.html]]

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp13NG4KQphq.pgp
Description: PGP signature


[O] [PATCH] read.table in variable transfer caused sometimes "function not found" error - small change

2014-10-06 Thread Rainer M Krug
Hi

The variable transfer of tables from org to R caused sometimes 'could
not find function "read.table"' errors (e.g. when the file was tangled
into a ./data directory which was loaded by the function
devtools::load_all("./")). This can easily be fixed by adding the package
name to the call in R, i.e. replacing =read.table()= with
=utils::read.table()= which is done in this patch.

In R the calls read.table and utils::read.table are interchangeable (the
second one is actually preferred) so no negative effects can be
expected.

Cheers,

Rainer

From 7e43b724d9fd2557aef7440bb75de0e026a29c88 Mon Sep 17 00:00:00 2001
From: "Rainer M. Krug" 
Date: Mon, 6 Oct 2014 13:48:49 +0200
Subject: [PATCH] ob-R.el: Add package name to read.table call

* lisp/ob-R.el:
(ob-R-transfer-variable-table-with-header): Add package name to call
of R function read.table (now utils::read.table).  This clarifies the
call as well as avoids 'could not find function' error in R under
certain conditions.
---
 lisp/ob-R.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lisp/ob-R.el b/lisp/ob-R.el
index ea33031..dd0b0b9 100644
--- a/lisp/ob-R.el
+++ b/lisp/ob-R.el
@@ -101,7 +101,7 @@ this variable.")
  con <- textConnection(
%S
  )
- res <- read.table(
+ res <- utils::read.table(
con,
header= %s,
row.names = %s,
@@ -119,7 +119,7 @@ This function is used when the table contains a header.")
  con <- textConnection(
%S
  )
- res <- read.table(
+ res <- utils::read.table(
    con,
header= %s,
row.names = %s,
-- 
2.1.2



-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpRe_6szagaQ.pgp
Description: PGP signature


Re: [O] real-time image rendering

2014-10-03 Thread Doyley, Marvin M.
This works better
 (add-hook 'org-babel-after-execute-hook
  'org-display-inline-images)

https://www.mail-archive.com/emacs-orgmode@gnu.org/msg88358.html
thanks
m
On Oct 3, 2014, at 7:29 PM, Grant Rettke  wrote:

> Sorry for not discussing further:
> 
> https://urldefense.proofpoint.com/v1/url?u=https://stackoverflow.com/questions/17621495/emacs-org-display-inline-images&k=p4Ly7qpEBiYPBVenR9G2iQ%3D%3D%0A&r=Fwb4ac3v7AhcQoTcqa9wemihF49yp0vUvrJ%2BiX5Re4w%3D%0A&m=Z1cxylKq%2BcxQlQYWByza7usVlHiUrctSCJZH%2BrYsd2c%3D%0A&s=be48c9d91e056d8bd6c1d1087998c148178cd7448476c9cc4260be57508f602b
> 
> On Fri, Oct 3, 2014 at 5:12 PM, Doyley, Marvin M.
>  wrote:
>> Dear All,
>> 
>> I am currently using Org mode as a teaching tool for a course that I am 
>> teaching this semester. I would like to run some python simulations in class 
>> and save the results to a file. I would like to show the results in real 
>> time as I change various parameters.  I am using iimage-mode to display 
>> images. The only snag is that I have to toggle iimage-mode on and off to see 
>> the changes. Is there away to get iimage-mode to render in real time
>> 
>> thanks
>> M
>> 
>> Sent from my iPad
> 
> 
> 
> -- 
> Grant Rettke
> g...@wisdomandwonder.com | 
> https://urldefense.proofpoint.com/v1/url?u=http://www.wisdomandwonder.com/&k=p4Ly7qpEBiYPBVenR9G2iQ%3D%3D%0A&r=Fwb4ac3v7AhcQoTcqa9wemihF49yp0vUvrJ%2BiX5Re4w%3D%0A&m=Z1cxylKq%2BcxQlQYWByza7usVlHiUrctSCJZH%2BrYsd2c%3D%0A&s=2ffec8f094fdc2745d8be47418e74b09f151f07ccb55412fafda2a0d19534ac5
> “Wisdom begins in wonder.” --Socrates
> ((λ (x) (x x)) (λ (x) (x x)))
> “Life has become immeasurably better since I have been forced to stop
> taking it seriously.” --Thompson



Re: [O] real-time image rendering

2014-10-03 Thread Doyley, Marvin M.
Thanks
Cheers,
M

Sent from my iPad

> On Oct 3, 2014, at 7:29 PM, Grant Rettke  wrote:
> 
> Sorry for not discussing further:
> 
> https://urldefense.proofpoint.com/v1/url?u=https://stackoverflow.com/questions/17621495/emacs-org-display-inline-images&k=p4Ly7qpEBiYPBVenR9G2iQ%3D%3D%0A&r=Fwb4ac3v7AhcQoTcqa9wemihF49yp0vUvrJ%2BiX5Re4w%3D%0A&m=Z1cxylKq%2BcxQlQYWByza7usVlHiUrctSCJZH%2BrYsd2c%3D%0A&s=be48c9d91e056d8bd6c1d1087998c148178cd7448476c9cc4260be57508f602b
> 
> On Fri, Oct 3, 2014 at 5:12 PM, Doyley, Marvin M.
>  wrote:
>> Dear All,
>> 
>> I am currently using Org mode as a teaching tool for a course that I am 
>> teaching this semester. I would like to run some python simulations in class 
>> and save the results to a file. I would like to show the results in real 
>> time as I change various parameters.  I am using iimage-mode to display 
>> images. The only snag is that I have to toggle iimage-mode on and off to see 
>> the changes. Is there away to get iimage-mode to render in real time
>> 
>> thanks
>> M
>> 
>> Sent from my iPad
> 
> 
> 
> -- 
> Grant Rettke
> g...@wisdomandwonder.com | 
> https://urldefense.proofpoint.com/v1/url?u=http://www.wisdomandwonder.com/&k=p4Ly7qpEBiYPBVenR9G2iQ%3D%3D%0A&r=Fwb4ac3v7AhcQoTcqa9wemihF49yp0vUvrJ%2BiX5Re4w%3D%0A&m=Z1cxylKq%2BcxQlQYWByza7usVlHiUrctSCJZH%2BrYsd2c%3D%0A&s=2ffec8f094fdc2745d8be47418e74b09f151f07ccb55412fafda2a0d19534ac5
> “Wisdom begins in wonder.” --Socrates
> ((λ (x) (x x)) (λ (x) (x x)))
> “Life has become immeasurably better since I have been forced to stop
> taking it seriously.” --Thompson



[O] real-time image rendering

2014-10-03 Thread Doyley, Marvin M.
Dear All,

I am currently using Org mode as a teaching tool for a course that I am 
teaching this semester. I would like to run some python simulations in class 
and save the results to a file. I would like to show the results in real time 
as I change various parameters.  I am using iimage-mode to display images. The 
only snag is that I have to toggle iimage-mode on and off to see the changes. 
Is there away to get iimage-mode to render in real time

thanks
M

Sent from my iPad


Re: [O] Error Embedding SQL Source from code block into R Source of Another (noweb)

2014-09-30 Thread Rainer M Krug
Eric Brown  writes:

> Dear List:
>
> It is possible to embed SQL code as a string to be evaluated in R. I am
> interested in formatting the SQL code in its own source code block, with
> its own syntax highlighting and editing mode (C-c ').

This sounds very interesting, and I would be interested in doing thia as
well. Up to now, I was writing the sql statements in R, which is a pain
(paste, paste0, ...). But editing them in org and passing them to an R
source block as a variable sounds interestin, but I don't think this
will work. What might work is using noweb expansion, but I never used
it.

Check out the worg [1] "Simple Literate Programming Example (Noweb
syntax)"

From the page:

,
| In the Org-mode file:
| 
| #+name: hello-world-prefix
| #+begin_src sh :exports none
|   echo "/---\\"
| #+end_src
| HTML export of code: In the Org-mode file
| 
| #+name: hello-world-postfix #+begin_src sh :exports none echo
| "\---/"
| #+end_src
| 
| HTML export of code: The third code block does have a tangle header
| argument indicating the name of the file to which the tangled source
| code will be written. It also has Noweb style references to the two
| previous code blocks. These references will be expanded during
| tangling to include them in the output file as well.
| 
| In the Org-mode file:
| 
| #+name: hello-world
| #+begin_src sh :tangle hello :exports none :noweb yes
|   <>
|   echo "|   hello world |"
|   <>
| #+end_src
|
| HTML export of code: Calling org-babel-tangle will result in the following
| shell source code being written to the hello.sh file:
| 
| #!/usr/bin/env sh
| 
| # [[file:~/org/temp/index.org::*Noweb%20test][hello-world]]
| 
| echo "/---\\"
| echo "|   hello world |"
| echo "\---/"
| # hello-world ends here
|
| In addition, the following syntax can be used to insert the results of
| evaluating a code block, in this case one named example-block.
| 
| # <>
`

I guess this should work - and I will try it out - learned something.

Thanks for the question,

Rainer

>
> The first time I run the code, I am prompted for R starting directory,
> but I get an error:
>
> ---
> load ESSR: + + + Error: unexpected string constant in:
> source('~/.emacs.d/elpa/ess-20140913.1153/etc/ESSR/R/.load.R',
> local=TRUE) #define load.ESSR
> load.ESSR('"
> ---
>
> and the console locks.  I can C-g to get out of it, and then
> re-evaluate, and the code prints what I expect -- the text of the SQL
> command.
>
> Is this the right way to go about this?  Have I discovered a bug, or
> perhaps accidentally a wrong way to get the right answer?
>
> Is this an ESS problem, and not an orgmode problem, per se?  My ESS
> normally starts up fine, so I thought I would ask on this list first.
>
> A minimal example (first failing, second evaluation giving expected
> output) follows.
>
> Best regards,
>
> Eric
>
> Debian GNU/Linux (jessie)
> Emacs 24.3.93
> Org current from org repo
> ESS from MELPA (ca. 14.09)
> R 3.1.1 compiled from source
>
>
>
> - SESSION -
> #+TITLE: Test SQL Code
> #+AUTHOR: Eric Brown  
> #+EMAIL: br...@fastmail.fm
> #+PROPERTY: session *R*   
> #+PROPERTY: cache no
>
> #+name: sqlsource
> #+begin_src sql :engine postgresql :eval yes :noweb-ref sqlsrc :exports code 
> :results none
>   select 
> * 
>   from 
> t 
>   limit 
> 10
> #+end_src
>
> #+name: rsource
> #+begin_src R :noweb yes :results output :exports both
>   input <- '
>   <>
>   '
>   cat(input)
>   # dbGetQuery(connectionHandle, input)
> #+end_src
>
> #+RESULTS: rsource
> : 
> : select 
> :   * 
> : from 
> :   t 
> : limit 
> :   10
> -
>
>
>
>


Footnotes: 
[1]  http://orgmode.org/worg/org-contrib/babel/intro.html

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpXC643zqQEC.pgp
Description: PGP signature


Re: [O] Difference between eval and export

2014-09-26 Thread Rainer M Krug
Grant Rettke  writes:

> My eye is on you post about that topic because I would also like to know.

As you are using R, and if you are using sessions, what about setting
them from within R[1]?

Rainer

>
>
>
> On Fri, Sep 26, 2014 at 8:17 AM, Johannes Rainer
>  wrote:
>> thanks Grant for this information.
>>
>> I was just wondering, because it seemed to me that some environment
>> variables (from the shell) are present in the, while they some
>> (LC_ALL) are not present in the export process.
>> In my case, the export call fails with an error message, while there
>> is no problem if I evaluate source block per source block from the
>> buffer.
>>
>> At present I am therefore looking for a way to specify environment
>> variables in the export process, but I have no idea how to do
>> that...
>>
>> On 26 Sep 2014, at 15:11, Grant Rettke  wrote:
>>
>>> On Fri, Sep 26, 2014 at 5:43 AM, Johannes Rainer
>>>  wrote:
>>>> I am wondering what the difference between the eval of a source block and 
>>>> the export of a buffer is in terms
>>>> of the process in which the code is evaluated.
>>>
>>> When you evaluate a source block, it executes in the processed defined
>>> by your configuration. Then the results of that evaluation are stored
>>> according to your configuration. For example store the results in an
>>> example block.
>>>
>>> Exporting is the conversion for the org file content into and file
>>> format. During that process, you can configure whether or not you want
>>> evaluation of source blocks to occur during that process.
>>


Footnotes: 
[1]  http://stat.ethz.ch/R-manual/R-devel/library/base/html/Sys.setenv.html

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpl1UWrc6eoh.pgp
Description: PGP signature


[O] Header Arguments of Code Blocks - problems and challenges

2014-09-26 Thread Rainer M Krug

Hi

Based on several previous posts, it seems that the use of header
arguments, particularly

- different ways of setting these (from the manual)
,
|  - System-wide header arguments::  Set global default values
|  - Language-specific header arguments::  Set default values by language
|  - Header arguments in Org mode properties::  Set default values for a buffer 
or heading
|  - Language-specific header arguments in Org mode properties::  Set 
language-specific default values for a buffer or heading
|  - Code block specific header arguments::  The most common way to set values
|  - Header arguments in function calls::  The most specific level
`
- Inheritance of these
- how they interact

I now these as a problem of R, but I guess it is general for all
languages suported in org?

To make the usage of these header arguments easier, a proper outline
and description is needed how header arguments for source blocks can
be set and how these interact (inheritance, header-args versus
header-args+ at one and on different levels, different ways of setting
header arguments as above, ...). These header arguments are a *very*
powerful tool and you can do many things - but you can also break
things very easily.

In many cases, I resort to trial and error: 
- this is working, 
- now I want to have that behaviour for this code block, 
- normally I would do it like this, 
- not working,
- let's try out what is working,
- repeat from the beginning for the next change

But this is far from ideal and leads to spaghetti-code type property
setting which is quite fragile.

I don't think is it only me who has these problems.

So what could be done to remedy this?  I think a few aspects should be
tackeled (in no particular order):

1) a lot of information is in the manual - but spread out in many
   different locations / sections. The first would be to bring these
   sections together and to consolidate them into one section. I don't
   think this should go only into worg.
2) A set of simple and easily to understand examples which build on
   each other are needed. So starting with simple examples and expand
   these to complex examples.
3) These examples should be uaed as tests (maybe there are tests for
   this, but I am not at all familiar with the test framework of org).
4) based on these, the org code should be checked for
   - bugs (obviously)
   - inconsistencies in the approach used for header argument setting
 and inheritance and
   - possibly sugfgest to deprecate certain aspects to simplify it
 (but keep the flexibility which is there at the moment!
5) the property inheritance and hierarchy of different ways of setting
   these should be documented in a structured way. 

To make this happen, I would suggest to get a discussion going to

1) get a few interested users who are willing to activly participate
   in this (There is alread one: Thanks Grant!)
2) discuss how this can be tackled
3) and then, from there, get it going.

Before I end, I must thank the org developers for their hard work they
have put into org - and I am sure that the header arguments framework
has received quite a bit of attention. But (and please correct me if I
am wrong), there is a relatively small overlap between main org
developers and regular org babel users.

And this is where the babel user can contributing to org, even if
their elisp knowledge is not the best.

OK - I hope we can geth this going and make a usefull contribution to
org babel,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp56CCHrzi8L.pgp
Description: PGP signature


[O] Header Arguments of Code Blocks - problems and challenges

2014-09-26 Thread Rainer M Krug

Hi

Based on several previous posts, it seems that the use of header
arguments, particularly

- different ways of setting these (from the manual)
,
|  - System-wide header arguments::  Set global default values
|  - Language-specific header arguments::  Set default values by language
|  - Header arguments in Org mode properties::  Set default values for a buffer 
or heading
|  - Language-specific header arguments in Org mode properties::  Set 
language-specific default values for a buffer or heading
|  - Code block specific header arguments::  The most common way to set values
|  - Header arguments in function calls::  The most specific level
`
- Inheritance of these
- how they interact

I now these as a problem of R, but I guess it is general for all
languages suported in org?

To make the usage of these header arguments easier, a proper outline
and description is needed how header arguments for source blocks can
be set and how these interact (inheritance, header-args versus
header-args+ at one and on different levels, different ways of setting
header arguments as above, ...). These header arguments are a *very*
powerful tool and you can do many things - but you can also break
things very easily.

In many cases, I resort to trial and error: 
- this is working, 
- now I want to have that behaviour for this code block, 
- normally I would do it likethis, 
- not working,
- let's try out what is working,
- repeat from the beginning for the next change

But this is far from ideal and leads to spaghetti-code type property
setting which is quite fragile.

I don't think is it only me who has these problems.

So what could be done to remedy this?  I think a few aspects should be
tackeled (in no particular order):

1) a lot of information is in the manual - but spread out in many
   different locations / sections. The first would be to bring these
   sections together and to consolidate them into one section. I don't
   think this should go only into worg.
2) A set of simple and easily to understand examples which build on
   each other are needed. So starting with simple examples and expand
   these to complex examples.
3) These examples should be uaed as tests (maybe there are tests for
   this, but I am not at all familiar with the test framework of org).
4) based on these, the org code should be checked for
   - bugs (obviously)
   - inconsistencies in the approach used for header argument setting
 and inheritance and
   - possibly sugfgest to deprecate certain aspects to simplify it
 (but keep the flexibility which is there at the moment!
5) the property inheritance and hierarchy of different ways of setting
   these should be documented in a structured way. 

To make this happen, I would suggest to get a discussion going to

1) get a few interested users who are willing to activly participate
   in this (There is alread one: Thanks Grant!)
2) discuss how this can be tackled
3) and then, from there, get it going.

Before I end, I must thank the org developers for their hard work they
have put into org - and I am sure that the header arguments framework
has received quite a bit of attention. But (and please correct me if I
am wrong), there is a relatively small overlap between main org
developers and regular org babel users.

And this is where the babel user can contributing to org, even if
their elisp knowledge is not the best.

OK - I hope we can geth this going and make a usefull contribution to
org babel,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpZHOQQmv0Zd.pgp
Description: PGP signature


pgp7oOEEzMn7I.pgp
Description: PGP signature


Re: [O] ob-R, about :results value verbatim drawer

2014-09-26 Thread Rainer M Krug
Grant Rettke  writes:

> On Wed, Sep 24, 2014 at 2:52 AM, Rainer M Krug  wrote:
>> would there be interest in pursuing this?
>
> Yes.
>
> I'm interested in working with other serious babel users to pool our
> efforts, provide a meaningful contribution, and do it in a way that
> works best for the maintainers.

OK - I will then repost the previous email under a different header and
ask for interested babel users who would like to participate and suggest
a way forward to make this happen.

Thanks for your thumbs up,

Rainer

>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpQdLjyEpOv9.pgp
Description: PGP signature


Re: [O] meaningfull names for org-src buffers

2014-09-25 Thread Rainer M Krug
Andreas Leha  writes:

> Hi Charles,
>
> Charles Berry  writes:
>> Andreas Leha  med.uni-goettingen.de> writes:
>>
>>> 
>>> Hi,
>>> 
>>> Grant Rettke  wisdomandwonder.com> writes:
>>> > On Thu, Sep 11, 2014 at 5:05 PM, Adriaan Sticker
>>> >  gmail.com> wrote:
>>> >> I was wondering if it's somehow possible to give named org src buffer the
>>> >> name they were give in their #+NAME tag? Now there are just called 
>>> >> something like:
>>> >> *Org Src test.org[ R ]*
>>> >>
>>> >> But if you have multiple org-src buffers opened at the same time, its 
>>> >> hard to find the correct one back.
>>> >
>>> > Excellent idea. I've got so many small source blocks that it is too
>>> > difficult to make sense of
>>> > keeping multiple source block edit buffers open and limit them to one
>>> > at a time eg
>>> >
>>> > ,
>>> > | (setq org-src-window-setup 'current-window)
>>> > `
>>> >
>>> > How have you come upon your workflow of keeping multiple open and what
>>> > are some of the pros and
>>> > cons that you've found with it?
>>> 
>>> I'd be interested in this as well.
>>> 
>>> Regards,
>>> Andreas
>>> 
>>> 
>>
>> Maybe I am answering the wrong question, but org-edit-src-code allows
>> you to specify the buffer name:
>>
>
> You are answering my exact question.
>
>>
>> ,[ C-h f org-edit-src-code RET ]
>> | org-edit-src-code is an interactive compiled Lisp function in
>> | `org-src.el'.
>> | 
>> | (org-edit-src-code &optional CONTEXT CODE EDIT-BUFFER-NAME)
>> | 
>> | ...
>> `
>>
>> So you can do something like this:
>>
>> #+BEGIN_SRC emacs-lisp
>>   (defun org-edit-src-code-plus-name ()
>> (interactive)
>> (let* ((eop  (org-element-at-point))
>>(name (or (org-element-property :name (org-element-context eop))
>>   "unnamed"))
>>(lang (org-element-property :language eop))
>>(buff-name (concat "*Org Src " name "[ " lang " ] *")))
>>   (org-edit-src-code nil nil buff-name)))
>> #+END_SRC
>>
>> which leads to a buffer named like "*Org Src My-block[ R ] *", where 
>> 'My-block' is the name of the src block.
>>
>
> Thanks!  On my first quick tests that works great!  It is in my
> initialization and I'll use that regularly.
>
> Is there any drawback to this?  Otherwise I'd advocate for
> org-edit-src-code doing that by default.

Haven't tried it out yet, but I second that statement.

Rainer

>
>> HTH,
>
> It sure does.
>
> Thanks,
> Andreas
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpxPBgKlq0Wd.pgp
Description: PGP signature


Re: [O] ob-R, about :results value verbatim drawer

2014-09-24 Thread Rainer M Krug
Aaron Ecay  writes:

> Hi Feng,
>
> 2014ko irailak 23an, Feng Shu-ek idatzi zuen:
>> but when I add a #+PROPERTY, it show error like below, how to deal with
>> it ?  thanks ...
>> 
>>   #+PROPERTY: header-args:R :colnames yes :rownames no :exports both
>>   #+BEGIN_SRC R :results value verbatim drawer
>>   data <- 
>> list(a="[[./test1.org]]",b="[[./test2.org]]",c="[[./test3.org]]")
>>   c(data$a,data$b,data$c)
>>   #+END_SRC
>> 
>> 
>>   executing R code block...
>>   Wrote /tmp/babel-1984743i/ob-input-198472lB
>>   org-babel-R-evaluate-external-process: Wrong type argument: listp, "x
>>   [[./test1.org]]
>>   [[./test2.org]]
>>   [[./test3.org]]
>>   "
>
> The simple answer is don’t add the #+property line.  In particular, the
> :colnames yes setting doesn’t play well with your code block.  If you
> must have the #+property line for other reasons, override the global
> setting of :colnames yes with :colnames no on the source block.

And another problem with different ways of setting header arguments.

Is this only a problem of R, or is this general (it does not seem to be
only me...) in org?

The more I think, a proper outline and description is needed how header
arguments for source blocks (probably in general, but I use org mainy
for literate programming and data analysis therefore always including
source code blocks) can be set and how these interact (inheritance, the
+, different ways of setting header arguments as above, ...). These
header arguments are a *very* powerful tool and you can do many things -
but you can also break things very easily.

In many cases, I resort to trial and error: This is working, now I want
to have that behaviour for this code block, normally I would do it like
this, not working, let's try out what is working. But this is far from
ideal and leads to spaghetti-code type property setting which is quite
fragile.

Again: is it only me? I don't think (hope?) so.

So what could be done to remedy this?  I think a few aspects should be
tackeled:

1) a lot of information is in the manual - but spread out in many
   different locations / sections. The first would be to bring these
   sections together and to consolidate them into one section.
2) We need a set of simple and easily to understand examples which
   build on each other. So starting with simple examples and expand
   these to complex examples.
3) These examples should be uaed as tests (maybe there are tests for
   this, but I am not at all familiar with the test framework of org).
4) based on these, the org code should be checked for
   - bugs (obviously)
   - inconsistencies in the approach used for header argument setting
 and inheritance and
   - possibly deprecate certain aspects to simplify it (but keep the
 flexibility which is there at the moment!
5) the property inheritance and hierarchy of different ways of setting
   these should be documented in a structured way. 

So is there anything in this direction? I guess this would be quite a
big task - would there be interest in pursuing this?

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpsC8z0z2wpk.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?

2014-09-23 Thread Rainer M Krug
Rasmus  writes:

> Hi,
>
> Rainer M Krug  writes:
>
> Thanks for the summary Rainer.

Hope I didn't forget anything...

>
>> I think that org could be a perfect environment for building CVs if
>> one could come up with an HOWTO and many examples how to do it - and I
>> think this is going into the right direction.
>
> I think the "right" approach is cooking up a reasonable way to
> represent CVs and make an ox-cv with a customized interface (like
> ox-koma-letter where ordering of blocks can also be changed
> "on-the-go") and provide some nice default "themes".  It should either
> build on an established LaTeX cv package or just KOMA-Script like
> Xavier's CV (and mine).  I didn't check the ox-cv.el that was posted
> carefully.

Yes - this might be the most "org-ish" approach, and the most stable
(over time).

>
> That being said, I don't have much time for this right now.

Isn't there a worg / org page, where these ideas are collected (TODO?
Feature Requests, ...)? I fear that this becomes forgotten again
(including myself!), as CVs are not something one uses regularly...

I unfortunately have not the elisp knowledge to contribute much here.

>
> It would be nicer to handle something like a CV in org than LaTeX.

I completely agree with you - I have it at the moment in LyX, but I am
fixing issues each time I need a CV.

Cheers,

Rainer

>
> Cheers,
> Rasmus

-- 
Rainer M. Krug

PGP: 0x0F52F982


pgpy7v8eB7geD.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Myles English  writes:

> Myles English writes:
>
>> Nicolas Goaziou writes:
>>
>>> One option could be to define a specialized latex back-end dedicated to
>>> moderncv class, much like "ox-koma-letter.el" does for "scrlttr2".
>>
>> I did actually make a start on this, I'll dig it out and put it
>> somewhere accessible, soon.
>
> ..and here it is:
>
> https://github.com/mylese/ox-cv

This looks very nice - thanks. 

Rainer

>
> It kind of works, I haven't tried it with org more recent than about
> July.  I'll be trying to develop it further myself but would welcome a
> lot of input from others.  Alternatively, if someone wants to take it
> over completely, that would be fine too.
>
> Myles
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpgwRb2DIvl8.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Xavier Garrido  writes:

> Hi Rainer,
>
> You can see mine https://github.com/xgarrido/org-resume that uses
> org-mode to produce a LaTeX->PDF (see attached file) file as well as
> an HTML version.
>
> Hope it gives you some ideas.

I can only say *wow*! This looks seriously impressive to me. 

I will have to take a closer look and see if I understand it and can
make it do what I want it to. But it looks nicely commented.

Thanks a lot,

Rainer

>
> Cheers,
> Xavier
>
> Le 19/09/2014 11:18, Rainer M Krug a écrit :
>> Hi
>>
>> I am looking for examples / templates for CVs written using org, as I
>> decided to ose org for my CV.
>>
>> I fund this oldish conversation
>>
>> http://lists.gnu.org/archive/html/emacs-orgmode/2012-04/msg00096.html
>>
>> and these two templates for using org to write a CV:
>>
>> https://github.com/punchagan/resume
>> https://github.com/fasheng/fsh-orgmode-latex-cv
>>
>> as well this CV without .org file
>>
>> http://adamsonj.ninth.su/cv.html
>>
>> Also, there does not seem to be anything on worg.
>>
>> - Can somebody give any further info on org and CVs?
>> - How do you do it (I don't assume you write your CVs in Word?), or are
>> you using LaTeX directly?
>> - Any other examples and templates online?
>>
>> If I get enough, I will compile a summary for worg, but I need examples
>> and information.
>>
>> Thanks,
>>
>> Rainer
>>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpDefL1oi7v1.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Joseph Vidal-Rosset  writes:

> Le sam.  20 sept. 2014  à 02:49:03  , Dan Griswold   a
> envoyé ce message:
>> Not sure anybody saw this the first time, so I'll try again, with some 
>> expansion.
>>
>> Unlike the others who've commented, I moved my CV from LaTeX to
>> org-mode and I'm happy with the results. Two things make it work
>> well.
>>
>> First, a "cv" class added to org-latex-classes:
>>
>> (add-to-list '("cv"
>> "\\documentclass[10pt]{article}\n\\usepackage[margin=.75in]{geometry}\n%\\usepackage{palatino}\n\\usepackage{sectsty}\n\\sectionfont{\\normalsize\\selectfont\\
>> itshape}\n\\usepackage[T1]{fontenc}\n\\usepackage{libertine}\n\\renewcommand*\\oldstylenums[1]{{\\fontfamily{fxlj}\\selectfont
>> #1}}"
>> ("\\section{%s}" . "\\section*{%s}")))
> Hello Dan, hello the list,
>
> I guess that there  is a code problem in this (add-to-list  ...) , in my
> init.el (or custom.el) , it produces this warning:

Same here - I guess it has to do with linebreaks?

Rainer
>
> Wrong number of arguments: #[(list-var element &optional append compare-fn) 
> \204
> J\235\202>\305=\203  
> J>\202>\306=\203&\307
> J"\202>
> J\211\203<   @"\204<A\211\204-)\203D
> J\207
> \203R\304
> J C"\202V 
> JBL\207  [compare-fn  element  list-var  lst  append  eq  eql  memql]  5
> 1615569], 1
>
> Now a suggestion:  there is "moderncv" class in texlive  and I wonder if
> it is difficult to make an add-to-list for this class in order to export
> a CV both in latex and in html. 
>
> I have no time at the moment to try this solution. 
>
> Best wishes,
>
> Jo. 
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpWmAeslzPlZ.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Myles English  writes:

> Hello,
>
> Nicolas Goaziou writes:
>
>> Brady Trainor  writes:
>>
>>> And I did have a decent export to LaTeX resume from org, but after 
>>> discovering moderncv, I've switched, though I will be curious to read 
>>> others' methods of org-to-moderncv export.
>>
>> One option could be to define a specialized latex back-end dedicated to
>> moderncv class, much like "ox-koma-letter.el" does for "scrlttr2".
>
> I did actually make a start on this, I'll dig it out and put it
> somewhere accessible, soon.

I guess that this would be the best approach, but definitely not for me
to complete due to my lack of deeper elisp and LaTeX knowledge.

Thanks,

Rainer

>
> Myles
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpoL9qJeyI44.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Vikas Rawal  writes:

> I know I am being lazy in not trying it out, but if you could share a
> PDF, it would give us an idea of what this gives you.

Yes - an example pdf would be great.

Rainer

>
> Vikas
>  
> On 20-Sep-2014, at 6:19 am, Dan Griswold  wrote:
>
>> Not sure anybody saw this the first time, so I'll try again, with some 
>> expansion.
>> 
>> Unlike the others who've commented, I moved my CV from LaTeX to
>> org-mode and I'm happy with the results. Two things make it work
>> well.
>> 
>> First, a "cv" class added to org-latex-classes:
>> 
>> (add-to-list '("cv"
>> "\\documentclass[10pt]{article}\n\\usepackage[margin=.75in]{geometry}\n%\\usepackage{palatino}\n\\usepackage{sectsty}\n\\sectionfont{\\normalsize\\selectfont\\itshape}\n\\usepackage[T1]{fontenc}\n\\usepackage{libertine}\n\\renewcommand*\\oldstylenums[1]{{\\fontfamily{fxlj}\\selectfont
>> #1}}"
>>   ("\\section{%s}" . "\\section*{%s}")))
>> 
>> Second, something like the following at the top of the org file (replace 
>> with your particulars):
>> 
>> #+OPTIONS: author:nil timestamp:nil
>> #+TITLE:
>> #+DATE:
>> #+LaTeX_CLASS: cv
>> 
>> #+BEGIN_LATEX
>> \begin{flushleft}
>>   \bfseries\Large Curriculum Vitae\hfill Daniel M. Griswold\normalfont
>> \end{flushleft}
>> 
>> \vspace{-12pt}%
>> \begin{flushright}
>>   69 Stratton Road\\
>>   Rochester, NY 14610\\
>>   (585) xxx-\\
>>   dgris...@x.com\\
>>   \hrulefill
>> \end{flushright}
>> #+END_LATEX
>> 
>> Main headings are things like:
>> 
>> * Education
>> * Specialization
>> * Employment
>> * Publications
>> * Awards and Honors
>> 
>> and the details below each of these headings are simply unordered lists
>> 
>> I really like the easy of editing in org-mode this gives me.
>> 
>> Hope this helps,
>> 
>> Dan
>> 
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpKBjz4BzpGJ.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Rasmus  writes:

> Nicolas Goaziou  writes:
>
>> Hello,
>>
>> Brady Trainor  writes:
>>
>>> And I did have a decent export to LaTeX resume from org, but after 
>>> discovering moderncv, I've switched, though I will be curious to read 
>>> others' methods of org-to-moderncv export.
>>
>> One option could be to define a specialized latex back-end dedicated to
>> moderncv class, much like "ox-koma-letter.el" does for "scrlttr2".
>
> You can even do it all on the LaTeX side, e.g. redefining description
> (or using ¤+ATTR_LATEX) to make use of the description form
>
> "- year :: item"
>
> Together with rebinding the title-command it should be pretty easy to
> make a CV.

I am not a LaTeX expert, so could you please elaborate a bit on this, as
it sounds like a reasonable approach, and also relatively easy to
implement?

Rainer

>
> I never worked the LaTeX CV classes as I did not care for their
> default looks, but it's very easy to use KOMA for CVs.
>
> —Rasmus

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpqelCaoa3x_.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
Brady Trainor  writes:

> On 9/19/2014 2:18 AM, Rainer M Krug wrote:
>> Hi
>>
>> - How do you do it (I don't assume you write your CVs in Word?), or are
>> you using LaTeX directly?
>
> Nice question, I will enjoy reading all the examples in this thread.
>
> For a bit, I tried to make org do everything, like export resumes to 
> Word, Writer, LaTeX and ASCII from one tree. Eventually, I couldn't 
> justify managing all the moving parts, but maybe one day...

I am only thinking about export to LaTeX / pdf and html, but ASCII might
be nice as well.

>
> So I abandoned the export to word processors, though I had succeeded in 
> applying template files. Too much going on behind the scenes for me, and 
> requests for Word resumes should be rare enough that I just have notes 
> on how to quickly format a resume there. After all, with so many OS and 
> fonts, sending a Word document across OS can have unpredictable results. 
> PDF or plain text is the way to go. (Interpretive dance is okay too.)

Completely agree - it would not be worth to keep that route up for a
CV.

>
> And I did have a decent export to LaTeX resume from org, but after 
> discovering moderncv, I've switched, though I will be curious to read 
> others' methods of org-to-moderncv export.

Yes - moderncv looks nice. Would be interested in suggestions as well.

Thanks,

Rainer

>
> But what I do still use is export to ASCII, as editing an ASCII resume 
> layout is a pain. Here is the crux of my template for that
>
> #+OPTIONS: toc:nil num:nil
> #+NAME: setup # I have no idea what this line is for, I found it on worg
> #+BEGIN_SRC emacs-lisp :results silent :exports none
> (setq org-ascii-headline-spacing '(0 . 1))
> (setq org-ascii-inner-margin 5)
> (setq org-ascii-underline '((ascii nil ?= nil)))
> #+END_SRC
>
> * resume :export:
>
> #+BEGIN_CENTER
> Brady Trainor\\
> algeb...@uw.edu -- (206) 898-4124
> #+END_CENTER
>
> ** Experience
> *** Jan -Present Position
> Location\\
> Job description.
>
> ... etc.
>
> This is nice for sites that seem to prefer plain text, or demand it. I'm 
> considering removing the centering, as some sites seem to remove the 
> whitespace up to first character (B).
>
> Brady
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpnsv3iOgXsX.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?)

2014-09-22 Thread Rainer M Krug
torys.ander...@gmail.com (Tory S. Anderson) writes:

> Very nice, John. Thanks for sharing the LaTeX! 

I agree - thanks.

I will take a closer look later and possibly use some ideas.

Rainer

>
> John Hendy  writes:
>
>> Like the rest, I picked straight LaTeX, as it just felt like forcing Org to
>> do something unnatural, in my opinion. At least, if you get into any sort
>> of formatting stuff, it just didn't feel right. Here's some other mailing
>> list discussions if you haven't run into them:
>> - https://www.mail-archive.com/emacs-orgmode@gnu.org/msg37000.html
>> - http://web.archiveorange.com/archive/v/Fv8aAUnm6O4rHfVY6k0p
>>
>> And a github repo:
>> - https://github.com/fasheng/fsh-orgmode-latex-cv
>>
>> I still have a bookmarks folder in Chromium from when I was hunting around.
>> Here are the ones that, apparently, I found worth to make the Ctrl+D cut
>> for future reference if you're interested
>> -
>> http://linux.dsplabs.com.au/resume-writing-example-latex-template-linux-curriculum-vitae-professional-cv-layout-format-text-p54/
>> - http://www.latextemplates.com/templates/curriculum_vitaes/6/cv_6.tex
>> - http://jblevins.org/projects/cv-template/
>> - http://nitens.org/taraborelli/cvtex
>>
>> I haven't updated mine since 2011, when I updated it for my current job. I
>> went with an internal CV so that I could list accomplishments that would be
>> considered confidential (patent applications, internal reports, etc.). I
>> did create a dummy version, which I've attached (tex/pdf). Re-looking at
>> it, I can't decide if I still like it or not. At the time, I was really
>> happy with it as my first LaTeX CV :) I'd also probably consider it a
>> hybrid CV/resume -- I liked describe some of my previous job
>> responsibilities, while including papers/presentations/etc.
>>
>>
>> Good luck!
>> John
>>
>>
>> On Fri, Sep 19, 2014 at 5:29 AM, Andreas Kiermeier <
>> andreas.kierme...@gmail.com> wrote:
>>
>>> Hi Rainer,
>>>
>>> like Tory I prepare my CV using latex directly. I've been using
>>> "moderncv" for several years now and have been quite happy with it
>>> (though that was before I've started using org). But even now, I can't
>>> see how using org, would add to what I already have.
>>>
>>> Mind you, I tend to add to my CV (mainly publications and experience)
>>> and revise it when needed, rather than adapt it to different
>>> situations.
>>>
>>> Cheers,
>>>
>>> Andreas
>>>
>>>
>>>
>>> On 19 September 2014 19:40, Tory S. Anderson 
>>> wrote:
>>> > I do mine in LaTeX and haven't had a reason to change that. I keep a
>>> "Master" CV/resumé with all the gratuitous information in all categories,
>>> then make subdirs for each submission and the trimmed-down versions of my
>>> resume that I sent out. At this stage in my career–where I am still
>>> tailoring resumés to employers and not really keeping a no-holds-barred CV—
>>> this is the best workflow I've found. I'm not sure how I'd go about
>>> versioning, trimming, and tracking things as neatly in an all-org
>>> environment.
>>> >
>>> > I'm presuming you just want a full-disclosure CV, though? Org makes more
>>> sense there.
>>> >
>>> > Rainer M Krug  writes:
>>> >
>>> >> Hi
>>> >>
>>> >> I am looking for examples / templates for CVs written using org, as I
>>> >> decided to ose org for my CV.
>>>
>>>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpo140KyY1UJ.pgp
Description: PGP signature


Re: [O] CV in orgmode for export to pdf (and html?

2014-09-22 Thread Rainer M Krug

First of all, thanks to everybody so far who responded to this
question. 

I reply to my question directly, as I am trying to sum up the replies
so far (the complete thread is theoretically below).

There are effectively two "schools", 

- using LaTeX (Tory, Andreas, John and Brady), and
- using org (Dan, Myles(?) and Xavier)

The reasons for using LaTeX directly were mainly the simplicity of
using LaTeX directly instead of telling org how to export to the
format wanted, while the reasons for using org were simplicity of
editing in org and the export to different formats (apart from pdf
also html).

I will not go further into the LaTeX as there is a vast amount of info
available on the Internets. 

My reasoning why I want to use org instead of LaTeX is the same as
mentioned in the thread, which is the simplicity of editing in org.
In addition, I like the different backends, and that the actual
content is separated from the export. 

I like Dan's approach as it looks relatively simple, although I still
have to look into it in detail (and as Joseph notes, there must be a
problem in the code).

Xavier's approach looks *very* impressive. I like the pdf, and I am
seriously thinking of using it, but my problem is the complexity - if
it breaks, I have no idea where to fix it. But as the original CV is
in org, the data would be there and I simply have to change the
export / publishing.

So what am I going to do?  I think I will start entering the CV into
org and then use Xavier's or Dan's approach and then see if I can get
a layout I like.

I like the idea of Rasmus to re-define the description environment,
and I might also play with this.

I think that org could be a perfect environment for building CVs if
one could come up with an HOWTO and many examples how to do it - and I
think this is going into the right direction.

So thanks a lot everybody for their input so far and keep the comments
and ideas flowing.

Rainer

torys.ander...@gmail.com (Tory S. Anderson) writes:

> I do mine in LaTeX and haven't had a reason to change that. I keep a
> "Master" CV/resumé with all the gratuitous information in all
> categories, then make subdirs for each submission and the trimmed-down
> versions of my resume that I sent out. At this stage in my
> career–where I am still tailoring resumés to employers and not really
> keeping a no-holds-barred CV— this is the best workflow I've
> found. I'm not sure how I'd go about versioning, trimming, and
> tracking things as neatly in an all-org environment.
>
> I'm presuming you just want a full-disclosure CV, though? Org makes more 
> sense there. 
>
> Rainer M Krug  writes:
>
>> Hi
>>
>> I am looking for examples / templates for CVs written using org, as I
>> decided to ose org for my CV.
>>
>> I fund this oldish conversation
>>
>> http://lists.gnu.org/archive/html/emacs-orgmode/2012-04/msg00096.html
>>
>> and these two templates for using org to write a CV:
>>
>> https://github.com/punchagan/resume
>> https://github.com/fasheng/fsh-orgmode-latex-cv
>>
>> as well this CV without .org file
>>
>> http://adamsonj.ninth.su/cv.html
>>
>> Also, there does not seem to be anything on worg.
>>
>> - Can somebody give any further info on org and CVs? 
>> - How do you do it (I don't assume you write your CVs in Word?), or are
>> you using LaTeX directly?
>> - Any other examples and templates online?
>>
>> If I get enough, I will compile a summary for worg, but I need examples
>> and information.
>>
>> Thanks,
>>
>> Rainer
>
>

Andreas Kiermeier  writes:

> Hi Rainer,
>
> like Tory I prepare my CV using latex directly. I've been using
> "moderncv" for several years now and have been quite happy with it
> (though that was before I've started using org). But even now, I can't
> see how using org, would add to what I already have.
>
> Mind you, I tend to add to my CV (mainly publications and experience)
> and revise it when needed, rather than adapt it to different
> situations.
>
> Cheers,
>
> Andreas
>
>
>
> On 19 September 2014 19:40, Tory S. Anderson  wrote:
>> I do mine in LaTeX and haven't had a reason to change that. I keep a
>> "Master" CV/resumé with all the gratuitous information in all
>> categories, then make subdirs for each submission and the
>> trimmed-down versions of my resume that I sent out. At this stage in
>> my career–where I am still tailoring resumés to employers and not
>> really keeping a no-holds-barred CV— this is the best workflow I've
>> found. I'm not sure how I'd go about versioning, trimming, and
>> tracking 

Re: [O] Creating new org headers from code blocks

2014-09-19 Thread Rainer M Krug
Thorsten Jolitz  writes:

> Rainer M Krug  writes:
>
>> Thorsten Jolitz  writes:
>>
>>> Rainer M Krug  writes:
>>>
>>>> Thorsten Jolitz  writes:
>>>> I don't quite understand your code below and what it is supposed to do.
>>>
>>> Drawers are probably better in most cases, but this code lets you use
>>> ':results pp replace' while developing, but converts the fixed-width pp
>>> results into raw results when desired (e.g. in a buffer copy before some
>>> action is taken).
>>
>> OK - I see. But what is the advantage in this approach? Drawer do
>> perfectly what I want, i.e. encapsulating an org structure in a for
>> replacement when re-calculated, inside the drawer they behave like
>> normal org structure (folding, ...) and upon export they are exported as
>> org code would be - or am I missing something?
>
> There are none (for you) then, but it might be useful anyway in some
> situations, at least the results look more like part of the document
> when you care about the looks of the org file too (not only the export
> results). 

True.

Thanks a lot,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpRmREnKgjTr.pgp
Description: PGP signature


Re: [O] Creating new org headers from code blocks

2014-09-19 Thread Rainer M Krug
Thorsten Jolitz  writes:

> Rainer M Krug  writes:
>
>> Thorsten Jolitz  writes:
>> I don't quite understand your code below and what it is supposed to do.
>
> Drawers are probably better in most cases, but this code lets you use
> ':results pp replace' while developing, but converts the fixed-width pp
> results into raw results when desired (e.g. in a buffer copy before some
> action is taken).

OK - I see. But what is the advantage in this approach? Drawer do
perfectly what I want, i.e. encapsulating an org structure in a for
replacement when re-calculated, inside the drawer they behave like
normal org structure (folding, ...) and upon export they are exported as
org code would be - or am I missing something?

Rainer



>
>>> #+BEGIN_SRC emacs-lisp :results none
>>>   (defvar tj/fixed-width-to-raw-langs '("R")
>>> "List of Babel langs for `tj/fixed-width-to-raw-results'.")
>>>
>>>   (defun tj/fixed-width-to-raw-results ()
>>> "Call `org-toggle-fixed-width' on ':results pp'."
>>> (org-babel-map-src-blocks nil
>>>   (and (member lang tj/toggle-fixed-width-src-block-langs)
>>>(member "pp" (split-string header-args " " t))
>>>(save-excursion
>>>  (goto-char (org-babel-where-is-src-block-result))
>>>  (forward-line)
>>>  (while (org-in-fixed-width-region-p)
>>>(org-toggle-fixed-width)
>>>(forward-line))
>>>
>>> #+END_SRC
>>> #+begin_src R :results pp replace
>>>  c("** New header2", "[[./graph1.pdf]]", "", "** and second header", "and 
>>> some text" )
>>> #+end_src
>>>
>>> #+results:
>>> : ** New header2
>>> : [[./graph1.pdf]]
>>> : 
>>> : ** and second header
>>> : and some text

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpd83LJU_zOB.pgp
Description: PGP signature


Re: [O] Creating new org headers from code blocks

2014-09-19 Thread Rainer M Krug
Thorsten Jolitz  writes:

> Rainer M Krug  writes:
>
> Hi,
>
>> I have some R code which generates several graphics. I would now like to
>> generate in R text which is then interpreted by org, upon export, as
>> normal org code. Furthermore, I would like to create new org headers from
>> the R code. Imagine I have the R code block below. Executed, I get the
>> results below:
>>
>> --8<---cut here---start->8---
>> * Some code block
>> #+begin_src R :results raw :wrap :exports both
>> c("** New header", "[[./graph1.pdf]]", "", "** and second header", "and some 
>> text" )
>> #+end_src
>>
>> #+RESULTS:
>> #+BEGIN_RESULTS
>> ,** New header
>> [[./graph1.pdf]]
>>
>> ,** and second header
>> and some text
>> #+END_RESULTS
>> --8<---cut here---end--->8---
>>
>> I can leave the :wrap, but then the results are not overwritten, but
>> appended - otherwise it works as expected.
>>
>> How can I achieve that I get 
>>
>> ,
>> | ** New header
>> | [[./graph1.pdf]]
>> | 
>> | ** and second header
>> | and some text
>> `
>>
>> in the org file, but also that the result gets overwritten upon repeated
>> execution?
>
> I asked about this ':results raw' limitation before and was told to RTFM
> ;)
>
> (although its not really on the page where I would look for it:
> http://orgmode.org/manual/results.html).

Thanks for pointing me to RTFM - there I found "drawer" and

,
| #+begin_src R :results  raw drawer 
| c("*** Mean", "[[file:./netimpacts_mean.pdf]]","", "*** 
Mode","[[file:./netimpacts_mode.pdf]]")
| #+end_src
`

results in

,
| #+RESULTS:
| :RESULTS:
| *** Mean
| [[file:./netimpacts_mean.pdf]]
| 
| *** Mode
| [[file:./netimpacts_mode.pdf]]
| :END:
`

which is nicely highlighted as headers, exported as headers and
replaced.

Perfect.

I don't quite understand your code below and what it is supposed to do.

Thanks,

Rainer

>
> You could look-up that thread in the mailing-list for some tips, and/or
> use this on a temporary buffer-copy just before you want to act on the
> raw results:

>
> #+BEGIN_SRC emacs-lisp :results none
>   (defvar tj/fixed-width-to-raw-langs '("R")
> "List of Babel langs for `tj/fixed-width-to-raw-results'.")
>
>   (defun tj/fixed-width-to-raw-results ()
> "Call `org-toggle-fixed-width' on ':results pp'."
> (org-babel-map-src-blocks nil
>   (and (member lang tj/toggle-fixed-width-src-block-langs)
>(member "pp" (split-string header-args " " t))
>    (save-excursion
>  (goto-char (org-babel-where-is-src-block-result))
>  (forward-line)
>  (while (org-in-fixed-width-region-p)
>(org-toggle-fixed-width)
>(forward-line))
>
> #+END_SRC
> #+begin_src R :results pp replace
>  c("** New header2", "[[./graph1.pdf]]", "", "** and second header", "and 
> some text" )
> #+end_src
>
> #+results:
> : ** New header2
> : [[./graph1.pdf]]
> : 
> : ** and second header
> : and some text

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpJN3q49dtBF.pgp
Description: PGP signature


[O] header arguments, inheritance, and noweb expansion Was: «Macro» expansion in source blocks; code-sharing between blocks

2014-09-19 Thread Rainer M Krug
Andreas Kiermeier  writes:

> Thanks Rainer,
>
> but unfortunately this isn't working. I'm sure I'm doing something
> wrong ... somewhere.
>
> In case this makes any difference I have in the document header:
>
> #+PROPERTY: header-args:R :session *R*
> #+PROPERTY: header-args :results output graphics :exports results
>
> I've now changed the source block header to ":exports none :eval no"
> but now there really is nothing in the output.
>
> In fact, the corresponding .tex file now contains:
>
> \begin{table}[h]
> \label{tbl:refyear}
> \caption{Separation outcomes (death or any type of discharge) by
> reference year.}
> nil
> \end{table}
>
> and in the *Message* buffer I now have:
>
> Evaluation of this R code-block (tbl-refyear) is disabled.
> org-babel-exp processing...
> Evaluation of this R code-block (tbl-refyear) is disabled.
> executing Latex code block...
>
> So, this source block really doesn't evaluated at all.

This boils down to the question I asked earlier about header-args and
+header args, inheritance of header arguments and this in contrast to
normal header args.  

Based on this discussion, I thought that the header arguments count
*where the code is executed* and not where it is defined - well -
surprise for me.

You could try and put the code block with the definition of the code
into a subtree where you set

,
| :PROPERTIES:
| :headser-args+: eval no
| :END:
`

This might work?

Rainer

>
> Thanks
>
> Andreas
>
> On 19 September 2014 18:34, Rainer M Krug  wrote:
>> Andreas Kiermeier  writes:
>>
>>> I don't think you need the ":noweb yes" as part of the setup_fu
>>> header, as this block is not pulling in other materials.
>>>
>>> Having used this type of setup only over the last couple of days, I've
>>> come up with another question. It appears that the setup_fu is
>>> executed twice ... once as it's own source block (though by itself not
>>> need) and once as part of the second noweb block. This isn't a problem
>>> if the execution time is small, but I'm trying to create a summary
>>> table in Latex format from 2 million records - so the time is
>>> considerable.
>>>
>>
>> Check out the :eval header argument: if you use
>>
>> ,
>> | #+BEGIN_SRC R :eval never :exports none
>> `
>>
>> this block is never executed - this should work. There are also other
>> values for :eval. From the help:
>>
>> ,
>> | 14.8.2.25 `:eval'
>> | .
>> |
>> | The `:eval' header argument can be used to limit the evaluation of
>> | specific code blocks.  The `:eval' header argument can be useful for
>> | protecting against the evaluation of dangerous code blocks or to ensure
>> | that evaluation will require a query regardless of the value of the
>> | `org-confirm-babel-evaluate' variable.  The possible values of `:eval'
>> | and their effects are shown below.
>> |
>> | `never or no'
>> |  The code block will not be evaluated under any circumstances.
>> |
>> | `query'
>> |  Evaluation of the code block will require a query.
>> |
>> | `never-export or no-export'
>> |  The code block will not be evaluated during export but may still
>> |  be called interactively.
>> |
>> | `query-export'
>> |  Evaluation of the code block during export will require a query.
>> |
>> |If this header argument is not set then evaluation is determined by
>> | the value of the `org-confirm-babel-evaluate' variable see *Note Code
>> | evaluation security::.
>> `
>>
>> Cheers,
>>
>> Rainer
>>
>>
>>> My two blocks (with some code removed for simplicity) are as follow:
>>>
>>> #+NAME: tbl-refyear
>>> #+BEGIN_SRC R :results silent :exports none
>>>   latex(tabular(   ))
>>> #+END_SRC
>>>
>>> #+BEGIN_SRC latex :noweb yes
>>> \begin{table}[h]
>>> \label{tbl:refyear}
>>> \caption{Separation outcomes (death or any type of discharge) by
>>> reference year.}
>>> <>
>>> \end{table}
>>> #+END_SRC
>>>
>>> I've tried :cache yes as part of the tbl-refyear source block, but
>>> that didn't stop if from being run twice. Am I missing a suitable
>>> header argument?
>>>
>>> This is the only way I could find to wrap the latex table (which has
>>> some complex formatting and hence why I've used it over just producing
>>> a table) in a float with a caption (though I still can't properly
>>> reference the label when I export to a PDF file).
>>>
>>> Any thought would be greatly appreciated. TIA!
>>>
>>> Andreas
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpbJDZT3tku8.pgp
Description: PGP signature


[O] Creating new org headers from code blocks

2014-09-19 Thread Rainer M Krug
Hi

I have some R code which generates several graphics. I would now like to
generate in R text which is then interpreted by org, upon export, as
normal org code. Furthermore, I would like to create new org headers from
the R code. Imagine I have the R code block below. Executed, I get the
results below:

--8<---cut here---start->8---
* Some code block
#+begin_src R :results raw :wrap :exports both
c("** New header", "[[./graph1.pdf]]", "", "** and second header", "and some 
text" )
#+end_src

#+RESULTS:
#+BEGIN_RESULTS
,** New header
[[./graph1.pdf]]

,** and second header
and some text
#+END_RESULTS
--8<---cut here---end--->8---

I can leave the :wrap, but then the results are not overwritten, but
appended - otherwise it works as expected.

How can I achieve that I get 

,
| ** New header
| [[./graph1.pdf]]
| 
| ** and second header
| and some text
`

in the org file, but also that the result gets overwritten upon repeated
execution?

Thanks,

Rainer


-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpQmGrnCbxSz.pgp
Description: PGP signature


[O] CV in orgmode for export to pdf (and html?)

2014-09-19 Thread Rainer M Krug
Hi

I am looking for examples / templates for CVs written using org, as I
decided to ose org for my CV.

I fund this oldish conversation

http://lists.gnu.org/archive/html/emacs-orgmode/2012-04/msg00096.html

and these two templates for using org to write a CV:

https://github.com/punchagan/resume
https://github.com/fasheng/fsh-orgmode-latex-cv

as well this CV without .org file

http://adamsonj.ninth.su/cv.html

Also, there does not seem to be anything on worg.

- Can somebody give any further info on org and CVs? 
- How do you do it (I don't assume you write your CVs in Word?), or are
you using LaTeX directly?
- Any other examples and templates online?

If I get enough, I will compile a summary for worg, but I need examples
and information.

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpSurobKC8r5.pgp
Description: PGP signature


Re: [O] «Macro» expansion in source blocks; code-sharing between blocks

2014-09-19 Thread Rainer M Krug
Andreas Kiermeier  writes:

> I don't think you need the ":noweb yes" as part of the setup_fu
> header, as this block is not pulling in other materials.
>
> Having used this type of setup only over the last couple of days, I've
> come up with another question. It appears that the setup_fu is
> executed twice ... once as it's own source block (though by itself not
> need) and once as part of the second noweb block. This isn't a problem
> if the execution time is small, but I'm trying to create a summary
> table in Latex format from 2 million records - so the time is
> considerable.
>

Check out the :eval header argument: if you use 

,
| #+BEGIN_SRC R :eval never :exports none
`

this block is never executed - this should work. There are also other
values for :eval. From the help:

,
| 14.8.2.25 `:eval'
| .
| 
| The `:eval' header argument can be used to limit the evaluation of
| specific code blocks.  The `:eval' header argument can be useful for
| protecting against the evaluation of dangerous code blocks or to ensure
| that evaluation will require a query regardless of the value of the
| `org-confirm-babel-evaluate' variable.  The possible values of `:eval'
| and their effects are shown below.
| 
| `never or no'
|  The code block will not be evaluated under any circumstances.
| 
| `query'
|  Evaluation of the code block will require a query.
| 
| `never-export or no-export'
|  The code block will not be evaluated during export but may still
|  be called interactively.
| 
| `query-export'
|  Evaluation of the code block during export will require a query.
| 
|If this header argument is not set then evaluation is determined by
| the value of the `org-confirm-babel-evaluate' variable see *Note Code
| evaluation security::.
`

Cheers,

Rainer


> My two blocks (with some code removed for simplicity) are as follow:
>
> #+NAME: tbl-refyear
> #+BEGIN_SRC R :results silent :exports none
>   latex(tabular(   ))
> #+END_SRC
>
> #+BEGIN_SRC latex :noweb yes
> \begin{table}[h]
> \label{tbl:refyear}
> \caption{Separation outcomes (death or any type of discharge) by
> reference year.}
> <>
> \end{table}
> #+END_SRC
>
> I've tried :cache yes as part of the tbl-refyear source block, but
> that didn't stop if from being run twice. Am I missing a suitable
> header argument?
>
> This is the only way I could find to wrap the latex table (which has
> some complex formatting and hence why I've used it over just producing
> a table) in a float with a caption (though I still can't properly
> reference the label when I export to a PDF file).
>
> Any thought would be greatly appreciated. TIA!
>
> Andreas
>
> On 18 September 2014 23:31, Eric S Fraga  wrote:
>>
>> On Thursday, 18 Sep 2014 at 13:26, Tobias Getzner wrote:
>> > On Thu, 18 Sep 2014 13:17:14 +, Tobias Getzner wrote:
>> >
>> >> Are there any convenient inline-expansion methods I might have
>> >> overlooked?
>> >
>> > To illustrate, I was wondering if any of the following is feasible
>> > somehow:
>>
>> Yes, and you almost got it right with your syntactic expansion:
>>
>> #+begin_src org
>>
>>   ,* Syntactic expansion
>>
>>   ,#+name: setup_fu
>>   ,#+begin_src sh :noweb yes
>> echo 2
>>   ,#+end_src
>>
>>   ,#+begin_src sh :results raw :noweb yes
>> echo 1
>> <>
>> echo 3
>>   ,#+end_src
>>
>>   ,#+results:
>>   1
>>   2
>>   3
>>
>> #+end_src
>>
>> Org src blocks can reference other src blocks.  Note the ":noweb yes"
>> option and the use of <<...>>.
>>
>>
>> --
>> : Eric S Fraga (0xFFFCF67D), Emacs 24.4.50.1, Org release_8.3beta-366-gb2fca7
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpWAFl74ly3w.pgp
Description: PGP signature


Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 /usr/local/share/emacs/site-lisp/org/)]

2014-09-19 Thread Rainer M Krug
Aaron Ecay  writes:

> Hi Malcom,
>
> 2014ko irailak 18an, "Cook, Malcolm"-ek idatzi zuen:
>> 
>> Hi,
>> 
>> Hmm, I spoke too soon the problem is only partially fixed by this
>> patch...
>> 
>> Trying to work with in org-mode with R code blocks attached to
>> persistent sessions (i.e. adding ':session myRsession' to the code
>> block header ) makes things start to break again, at least in my
>> hands.
>> 
>> I'm going to wait till things settle down before trying to upgrade ESS
>> again.
>> 
>> Thanks for the patch anyway.
>
> Can you give an ECM <http://orgmode.org/worg/org-faq.html#ecm>?  I tried
> to reconstruct what you are saying, but the patch seems to work as
> expected for me.

Haven't had a problem since I used the patch.

>
> (At the risk of being redundant, did you make sure that you are running
> the most recent code including the patch?  The most foolproof way is to
> navidate to the definition of ‘org-babel-R-initiate-session’ in ob-R.el,
> verify that the call to ‘ess-wait-for-process’ is present, and use C-M-x
> to reevaluate the defun.)

Also: if you are compile, did you compile after applying the patch? I
was looking once for an error for quite some time until I figured out
that I still had some old compiled files lurking around...

Rainer

>
> Thanks,

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpA9l5zEFamR.pgp
Description: PGP signature


Re: [O] Make html password protected?

2014-09-18 Thread Rainer M Krug
Ian Barton  writes:

> On 08/09/14 11:22, Rainer M Krug wrote:
>> Hi
>>
>> I do not have much experience with html and websites (what an
>> understatement!) but I would like to publish / export a simple html page
>> password protected. Is ther an easy way to do it in word?
>>
>> The content is not highly confidential or sensitive, just some analysis
>> for a paper of which I would like to provide regular feedback to my
>> co-authors and which should not be to easily readable by others.
>>
>> Any suggestions?
>>
>
> It depends if you have access to your web server configuration. If you
> are able to modify it the simplest way is to create an .htacess file
> in the directory containing your file:

Unfortunately I am not. I only have ftp access to the html directory.

Rainer

>
> AuthName"Journal"
> AuthTypeDigest file:
> AuthUserFile/etc/httpd/journal.passwd
> Require valid-user
> Order   allow,deny
> Satisfy any
>
> You can create a password file with:
>
> htdigest -c /etc/httpd/journal.passwd "Journal" username
>
> To add more users omit the -c argument, which will create a new file.
>
> Make sure you use digest authentication not basic (ie don't use
> htpasswd). Basic authentication transmits user names and passwords in
> plain text.
>
> Ian.
>
>

-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :   +33 - (0)9 53 10 27 44
Cell:   +33 - (0)6 85 62 59 98
Fax :   +33 - (0)9 58 10 27 44

Fax (D):+49 - (0)3 21 21 25 22 44

email:  rai...@krugs.de

Skype:  RMkrug

PGP: 0x0F52F982


pgpBoXiugsDeF.pgp
Description: PGP signature


Re: [O] Emacs server and org-protocol

2014-09-17 Thread Rainer M Krug
Stefan Huchler  writes:

> I dont really get what the problem is here, email servers checkup is

Not necessarily - depends which mail server (e.g. gmail or local), if
you have one or many folders / tags, your network connection, ...

Often used solution:

mail server (e.g. gmail) <- offlineimap -> local imap server <- gnus ->
the user

So offlineimap runs in the background and the local email server check
is fast enough.

I have two instances running, because of longer calculation in my second
(non-email) emacs instance...

Cheers,

Rainer


> fast enough, and rss u can use that:
>
> nnrss-use-local to ‘t’ and use ‘nnrss-generate-download-script
>
>
>
>

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpSiQ7VoGtAL.pgp
Description: PGP signature


Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 /usr/local/share/emacs/site-lisp/org/)]

2014-09-17 Thread Rainer M Krug
Rainer M Krug  writes:

Using it, error is gone.

Rainer

> Charles Berry  writes:
>
>> Charles Berry  ucsd.edu> writes:
>>
>>> 
>>> Rainer M Krug  krugs.de> writes:
>>> 
>>> > 
>>> > Thanks - you came before me. I get the same error but managed to work 
>>> > around.
>>> > 
>>> > This is likely caused by the upgrade of ess, 
>>> 
>>> Likely.
>>> 
>>> But it may not be an ESS problem per se. 
>>> 
>>> M-x R starts a process that runs asynchronously. In interactive use there 
>>> is no issue (barring something in .First() that slows the startup for
>>> a very long time).
>>> 
>>> But, ...
>>> 
>>> If the  (rename-buffer ...) in org-babel-R-initiate-session
>>> runs before all the setup that ESS performs in the process buffer is 
>>> complete, chaos can result.
>>> 
>>> Not sure what the best way is to fix this.
>>>
>>
>> OK. Looks like (ess-wait-for-process) fixes this. Here is a patch.
>
> Thanks.
>
> Haven't tried it yet, but I can't imagine any downside of this
> patch. Could this be committed?
>
> Rainer
>
>>
>> Chuck
>> ==
>>
>> From 89472012d80ce9ad4c8722f304c0d29327efa1fc Mon Sep 17 00:00:00 2001
>> From: chasberry 
>> Date: Tue, 16 Sep 2014 19:57:59 -0700
>> Subject: [PATCH] lisp/ob-R.el: use `ess-wait-for-process' to assure clean
>>  session startup
>>
>> * lisp/ob-R.el (org-babel-R-initiate-session): Make sure that (R) has
>> finished before `rename-buffer' is run.
>>
>> TINYCHANGE
>> ---
>>  lisp/ob-R.el | 3 +++
>>  1 file changed, 3 insertions(+)
>>
>> diff --git a/lisp/ob-R.el b/lisp/ob-R.el
>> index 41b943c..7575acf 100644
>> --- a/lisp/ob-R.el
>> +++ b/lisp/ob-R.el
>> @@ -35,6 +35,8 @@
>>  (declare-function inferior-ess-send-input "ext:ess-inf" ())
>>  (declare-function ess-make-buffer-current "ext:ess-inf" ())
>>  (declare-function ess-eval-buffer "ext:ess-inf" (vis))
>> +(declare-function ess-wait-for-process "ext:ess-inf" 
>> +  (&optional proc sec-prompt wait force-redisplay))
>>  (declare-function org-number-sequence "org-compat" (from &optional to inc))
>>  (declare-function org-remove-if-not "org" (predicate seq))
>>  (declare-function org-every "org" (pred seq))
>> @@ -262,6 +264,7 @@ This function is called by 
>> `org-babel-execute-src-block'."
>>  ;; Session buffer exists, but with dead process
>>  (set-buffer session))
>>(require 'ess) (R)
>> +  (ess-wait-for-process)
>>(rename-buffer
>> (if (bufferp session)
>> (buffer-name session)

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp_LdElBmteT.pgp
Description: PGP signature


Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 /usr/local/share/emacs/site-lisp/org/)]

2014-09-17 Thread Rainer M Krug
Charles Berry  writes:

> Charles Berry  ucsd.edu> writes:
>
>> 
>> Rainer M Krug  krugs.de> writes:
>> 
>> > 
>> > Thanks - you came before me. I get the same error but managed to work 
>> > around.
>> > 
>> > This is likely caused by the upgrade of ess, 
>> 
>> Likely.
>> 
>> But it may not be an ESS problem per se. 
>> 
>> M-x R starts a process that runs asynchronously. In interactive use there 
>> is no issue (barring something in .First() that slows the startup for
>> a very long time).
>> 
>> But, ...
>> 
>> If the  (rename-buffer ...) in org-babel-R-initiate-session
>> runs before all the setup that ESS performs in the process buffer is 
>> complete, chaos can result.
>> 
>> Not sure what the best way is to fix this.
>>
>
> OK. Looks like (ess-wait-for-process) fixes this. Here is a patch.

Thanks.

Haven't tried it yet, but I can't imagine any downside of this
patch. Could this be committed?

Rainer

>
> Chuck
> ==
>
> From 89472012d80ce9ad4c8722f304c0d29327efa1fc Mon Sep 17 00:00:00 2001
> From: chasberry 
> Date: Tue, 16 Sep 2014 19:57:59 -0700
> Subject: [PATCH] lisp/ob-R.el: use `ess-wait-for-process' to assure clean
>  session startup
>
> * lisp/ob-R.el (org-babel-R-initiate-session): Make sure that (R) has
> finished before `rename-buffer' is run.
>
> TINYCHANGE
> ---
>  lisp/ob-R.el | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/lisp/ob-R.el b/lisp/ob-R.el
> index 41b943c..7575acf 100644
> --- a/lisp/ob-R.el
> +++ b/lisp/ob-R.el
> @@ -35,6 +35,8 @@
>  (declare-function inferior-ess-send-input "ext:ess-inf" ())
>  (declare-function ess-make-buffer-current "ext:ess-inf" ())
>  (declare-function ess-eval-buffer "ext:ess-inf" (vis))
> +(declare-function ess-wait-for-process "ext:ess-inf" 
> +   (&optional proc sec-prompt wait force-redisplay))
>  (declare-function org-number-sequence "org-compat" (from &optional to inc))
>  (declare-function org-remove-if-not "org" (predicate seq))
>  (declare-function org-every "org" (pred seq))
> @@ -262,6 +264,7 @@ This function is called by `org-babel-execute-src-block'."
>   ;; Session buffer exists, but with dead process
>   (set-buffer session))
> (require 'ess) (R)
> +   (ess-wait-for-process)
> (rename-buffer
>  (if (bufferp session)
>  (buffer-name session)

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpnuTGfJgstT.pgp
Description: PGP signature


Re: [O] Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 @ /usr/local/share/emacs/site-lisp/org/)]

2014-09-16 Thread Rainer M Krug
Thanks - you came before me. I get the same error but managed to work around.

This is likely caused by the upgrade of ess, as I realized it after
upgrading to ess 14.09.

You can work around by 
1) evaluating the R code which gives the error message
2) quitting the R session
3) re-starting the R session manually in the same window (where the old
R session was)

I also send this to the ess mailing list.

Cheers,

Rainer


Ed Kademan  writes:

> I can't evaluate R code blocks in org files. For example the file with
> contents:
>
> #+property: header-args:R :session R-foo
>
> #+BEGIN_SRC R
>   print(pi)
> #+END_SRC
>
> spawns an R session that reports:
>
>   Error: could not find function ".ess.eval"
>
> and does not give me a result.
> I am running ess-version: 14.09 and am invoking emacs as follows:
>
> #!/bin/sh
>
> o=/usr/local/share/emacs/site-lisp/org
> emacs -Q --eval="(progn
>   (add-to-list 'load-path \"$o\")
>   (require 'org)
>   (org-babel-do-load-languages
>'org-babel-load-languages
>'((R . t)))
>   (package-initialize)
>   (setq ess-ask-for-ess-directory 'nil
> ess-directory \"~/R/\"))"
>
> EdK
>
> Emacs  : GNU Emacs 24.4.50.1 (i686-pc-linux-gnu, GTK+ Version 2.24.23)
>  of 2014-08-23 on dl
> Package: Org-mode version 8.3beta (release_8.3beta-362-ga92789 @ 
> /usr/local/share/emacs/site-lisp/org/)
>
> current state:
> ==
> (setq
>  org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point
> org-babel-execute-safely-maybe)
>  org-tab-first-hook '(org-hide-block-toggle-maybe
> org-babel-hide-result-toggle-maybe
> org-babel-header-arg-expand)
>  org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
> org-cycle-hide-inline-tasks org-cycle-show-empty-lines
> org-optimize-window-after-visibility-change)
>  org-agenda-before-write-hook '(org-agenda-add-entry-text)
>  org-speed-command-hook '(org-speed-command-default-hook
> org-babel-speed-command-hook)
>  org-babel-pre-tangle-hook '(save-buffer)
>  org-occur-hook '(org-first-headline-recenter)
>  org-metaup-hook '(org-babel-load-in-session-maybe)
>  org-confirm-elisp-link-function 'yes-or-no-p
>  org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
>  org-mode-hook '(#[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)
>  org-metadown-hook '(org-babel-pop-to-session-maybe)
>  org-src-mode-hook '(org-src-babel-configure-edit-buffer
>org-src-mode-configure-edit-buffer)
>  org-after-todo-state-change-hook '(org-clock-out-if-current)
>  org-babel-load-languages '((R . t))
>  org-confirm-shell-link-function 'yes-or-no-p
>  )

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpufjzeifxSH.pgp
Description: PGP signature


Re: [O] org-ref "no key found"

2014-09-16 Thread Julian M. Burgos
Yes, you were right.  An update of org-mode fixed everything.  Thanks again!

John Kitchin writes:

> If you look in your messages do you see something like jit-lock errors?
> I do not recall exactly what the errors are but the ones I have seen
> that resemble what you describe have jit in them. 
>
> I saw this recently in an ELPA version (maybe around Sept 1), and it went 
> away when I updated
> the ELPA org version to the most recent one.
>
>
> "Julian M. Burgos"  writes:
>
>> John, another issue...a really minor one, and I am not sure if it is
>> org-ref related.  When I open the notes file, the org faces are not
>> applied evenly.  In particular, 
>>
>> a) Text after #TITLE: or #AUTHOR appears as regular text.  If I use M-x
>> describe face, I get "default".  If modify in any way the face changes
>> to "org-document-info" as it should be.
>>
>> b) Within the heading of each reference, the "TODO" statement appears
>> with the same face as the rest of the heading (org-level-2 face).
>>
>> c) Links to pdf files appear like this, with default face:
>>  
>> [[cite:Collie2000]] [[file:/home/julian/Documents/Refs/Collie2000.pdf][pdf]]
>>
>> And not as clickable links 
>> cite:Collie2000 pdf (underlined, in blue, with org-link face)
>>
>> Again, as soon as I change anything the org-link face is applied and I
>> get a clickable link.
>>
>> Of all this, the pdf links are the real issue, as they are
>> non-functional until I edit them.
>>
>> Strangely, :PROPERTIES: and :END: appear in their correct face.  Also,
>> if I "fix" the faces (editing the text or pressing enter so I get the
>> right faces) and close the notes files, I get the same wriong faces when I
>> reopen the file.
>>
>> Does this makes sense?  Do you know what could be the issue?
>> Many thanks again,
>>
>> Julian
>>
>>
>> Julian M. Burgos writes:
>>
>>> Excellent! Many thanks... now it works like a charm.
>>>
>>> John Kitchin writes:
>>>
>>>> No problem. Thanks for the tips to replicate this. It was pretty helpful
>>>> in solving the problem (and thanks again to Nick who pointed me towards
>>>> edebug-defun a while ago!)
>>>>
>>>> I think I have fixed this. The problem was org-ref was not finding a key
>>>> that exists in a file. the way that is done all over org-ref is to
>>>> insert the contents of the bibfile in temp buffer, and then use
>>>> bibtex-search-entry on that buffer. It works like a charm usually, but
>>>> not in the replicated steps you have below. once it works once, though,
>>>> it seems to always work. 
>>>>
>>>> Anyway, I think it is fixed now. there is a new version at
>>>> https://github.com/jkitchin/jmax/blob/master/org/org-ref.org
>>>>
>>>> Thanks for reporting the bug!
>>>>
>>>> "Julian M. Burgos"  writes:
>>>>
>>>>> Hi John,
>>>>>
>>>>> I am resending this... I think it did not went through the previous
>>>>> time.
>>>>>
>>>>> I think I can replicate the org-ref bug now (if it is a bug).  This is
>>>>> the situation:
>>>>>
>>>>> a) If I open emacs, load a file that already has some link, and click on
>>>>> the link (or place the cursor on it and press enter) I get the "no key
>>>>> found" message and I cannot open the notes file (I get a "Wrong type
>>>>> argument: stringp, nil"), although the link to the pdf file works.  If I
>>>>> open more than one file, links do not work in any of them.  At this
>>>>> point if I check the value of the "org-ref-default-bibliography"
>>>>> variable, I get the correct path and filename of my .bib file.
>>>>>
>>>>> b) If I insert a new citation (using Ctrl-]) in any of the documents,
>>>>> links work as they should in all documents (this is, I get the title and
>>>>> I can open the notes file).
>>>>>>
>>>>> I should say that I am not using the org-ref-insert-bibliography-link
>>>>> function, because I use biblatex and I prefer to insert the Latex
>>>>> \printbibliography command.  But if use it and insert the bibliography
>>>>> link, the behaviour does not change.
>>>>>
>>>>> This is what I have in my .em

Re: [O] You don't like the HTML export; well, that could change!

2014-09-16 Thread Rainer M Krug
Fabrice Niessen 
writes:

> Hello,
>
> I'm announcing the release of Bigblow, a CSS + JS theme for the Org HTML
> exports.
>
> To use it in your own files, adding these lines should make it:
>
> #+HTML_HEAD:  href="http://www.pirilampo.org/styles/bigblow/css/htmlize.css"/>
> #+HTML_HEAD:  href="http://www.pirilampo.org/styles/bigblow/css/bigblow.css"/>
> #+HTML_HEAD:  href="http://www.pirilampo.org/styles/bigblow/css/hideshow.css"/>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/jquery-1.11.0.min.js"">http://www.pirilampo.org/styles/bigblow/js/jquery-1.11.0.min.js"</a>;>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/jquery-ui-1.10.2.min.js"">http://www.pirilampo.org/styles/bigblow/js/jquery-ui-1.10.2.min.js"</a>;>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/jquery.localscroll-min.js"">http://www.pirilampo.org/styles/bigblow/js/jquery.localscroll-min.js"</a>;>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/jquery.scrollTo-1.4.3.1-min.js"">http://www.pirilampo.org/styles/bigblow/js/jquery.scrollTo-1.4.3.1-min.js"</a>;>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/jquery.zclip.min.js"">http://www.pirilampo.org/styles/bigblow/js/jquery.zclip.min.js"</a>;>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/bigblow.js"">http://www.pirilampo.org/styles/bigblow/js/bigblow.js"</a>;>
> #+HTML_HEAD:  src="<a  rel="nofollow" href="http://www.pirilampo.org/styles/bigblow/js/hideshow.js"">http://www.pirilampo.org/styles/bigblow/js/hideshow.js"</a>;>
>
> If you clone my repo from GitHub [1], it can become as easy as adding
> just one line:
>
> #+SETUPFILE: path/to/Git/repo/setup/bigblow-pirilampo.setup

Thanks for this - this is awesome. I love it and I am going to use it!

One addition: the template also works with svg files, depending on
browser.

Cheers,

Rainer


>
> (PS- It would be very nice if we could add http references here!  Then,
> there would even be no need to copy the files locally...)
>
> Test it on your files, or look at the video I posted on YouTube to see
> what it looks like:
>
>   https://www.youtube.com/watch?v=DnSGSiXYuOk
>
> Best regards,
> Fabrice
>
> PPS- I will still make some changes in a couple of days, like renaming
>  the files so that they have a version number, but that I'll warn
>  you when I'll get this done.
>
> [1] https://github.com/fniessen/org-html-themes

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpk6NRy1Dxdv.pgp
Description: PGP signature


Re: [O] org-ref "no key found"

2014-09-15 Thread Julian M. Burgos
John, another issue...a really minor one, and I am not sure if it is
org-ref related.  When I open the notes file, the org faces are not
applied evenly.  In particular, 

a) Text after #TITLE: or #AUTHOR appears as regular text.  If I use M-x
describe face, I get "default".  If modify in any way the face changes
to "org-document-info" as it should be.

b) Within the heading of each reference, the "TODO" statement appears
with the same face as the rest of the heading (org-level-2 face).

c) Links to pdf files appear like this, with default face:
 
[[cite:Collie2000]] [[file:/home/julian/Documents/Refs/Collie2000.pdf][pdf]]

And not as clickable links 
cite:Collie2000 pdf (underlined, in blue, with org-link face)

Again, as soon as I change anything the org-link face is applied and I
get a clickable link.

Of all this, the pdf links are the real issue, as they are
non-functional until I edit them.

Strangely, :PROPERTIES: and :END: appear in their correct face.  Also,
if I "fix" the faces (editing the text or pressing enter so I get the
right faces) and close the notes files, I get the same wriong faces when I
reopen the file.

Does this makes sense?  Do you know what could be the issue?
Many thanks again,

Julian


Julian M. Burgos writes:

> Excellent! Many thanks... now it works like a charm.
>
> John Kitchin writes:
>
>> No problem. Thanks for the tips to replicate this. It was pretty helpful
>> in solving the problem (and thanks again to Nick who pointed me towards
>> edebug-defun a while ago!)
>>
>> I think I have fixed this. The problem was org-ref was not finding a key
>> that exists in a file. the way that is done all over org-ref is to
>> insert the contents of the bibfile in temp buffer, and then use
>> bibtex-search-entry on that buffer. It works like a charm usually, but
>> not in the replicated steps you have below. once it works once, though,
>> it seems to always work. 
>>
>> Anyway, I think it is fixed now. there is a new version at
>> https://github.com/jkitchin/jmax/blob/master/org/org-ref.org
>>
>> Thanks for reporting the bug!
>>
>> "Julian M. Burgos"  writes:
>>
>>> Hi John,
>>>
>>> I am resending this... I think it did not went through the previous
>>> time.
>>>
>>> I think I can replicate the org-ref bug now (if it is a bug).  This is
>>> the situation:
>>>
>>> a) If I open emacs, load a file that already has some link, and click on
>>> the link (or place the cursor on it and press enter) I get the "no key
>>> found" message and I cannot open the notes file (I get a "Wrong type
>>> argument: stringp, nil"), although the link to the pdf file works.  If I
>>> open more than one file, links do not work in any of them.  At this
>>> point if I check the value of the "org-ref-default-bibliography"
>>> variable, I get the correct path and filename of my .bib file.
>>>
>>> b) If I insert a new citation (using Ctrl-]) in any of the documents,
>>> links work as they should in all documents (this is, I get the title and
>>> I can open the notes file).
>>>>
>>> I should say that I am not using the org-ref-insert-bibliography-link
>>> function, because I use biblatex and I prefer to insert the Latex
>>> \printbibliography command.  But if use it and insert the bibliography
>>> link, the behaviour does not change.
>>>
>>> This is what I have in my .emacs file that is related to RefTex and
>>> org-ref:
>>>
>>> --
>>> ;; Load RefTex
>>> (add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
>>> (autoload 'reftex-mode "reftex" "RefTeX Minor Mode" t)
>>> (autoload 'turn-on-reftex  "reftex" "RefTeX Minor Mode" nil)
>>> (autoload 'reftex-citation "reftex-cite" "Make citation" nil)
>>> (autoload 'reftex-index-phrase-mode "reftex-index" "Phrase mode" t)
>>> (add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
>>> (add-hook 'latex-mode-hook 'turn-on-reftex)   ; with Emacs latex mode
>>>
>>> ;; Make RefTeX faster
>>> (setq reftex-enable-partial-scans t)
>>> (setq reftex-save-parse-info t)
>>> (setq reftex-use-multiple-selection-buffers t)
>>> (setq reftex-plug-into-AUCTeX t)
>>>
>>> (setq reftex-default-bibliography 
>>> '("/home/julian/Docum

Re: [O] org-ref "no key found"

2014-09-15 Thread Julian M. Burgos
Excellent! Many thanks... now it works like a charm.

John Kitchin writes:

> No problem. Thanks for the tips to replicate this. It was pretty helpful
> in solving the problem (and thanks again to Nick who pointed me towards
> edebug-defun a while ago!)
>
> I think I have fixed this. The problem was org-ref was not finding a key
> that exists in a file. the way that is done all over org-ref is to
> insert the contents of the bibfile in temp buffer, and then use
> bibtex-search-entry on that buffer. It works like a charm usually, but
> not in the replicated steps you have below. once it works once, though,
> it seems to always work. 
>
> Anyway, I think it is fixed now. there is a new version at
> https://github.com/jkitchin/jmax/blob/master/org/org-ref.org
>
> Thanks for reporting the bug!
>
> "Julian M. Burgos"  writes:
>
>> Hi John,
>>
>> I am resending this... I think it did not went through the previous
>> time.
>>
>> I think I can replicate the org-ref bug now (if it is a bug).  This is
>> the situation:
>>
>> a) If I open emacs, load a file that already has some link, and click on
>> the link (or place the cursor on it and press enter) I get the "no key
>> found" message and I cannot open the notes file (I get a "Wrong type
>> argument: stringp, nil"), although the link to the pdf file works.  If I
>> open more than one file, links do not work in any of them.  At this
>> point if I check the value of the "org-ref-default-bibliography"
>> variable, I get the correct path and filename of my .bib file.
>>
>> b) If I insert a new citation (using Ctrl-]) in any of the documents,
>> links work as they should in all documents (this is, I get the title and
>> I can open the notes file).
>>>
>> I should say that I am not using the org-ref-insert-bibliography-link
>> function, because I use biblatex and I prefer to insert the Latex
>> \printbibliography command.  But if use it and insert the bibliography
>> link, the behaviour does not change.
>>
>> This is what I have in my .emacs file that is related to RefTex and
>> org-ref:
>>
>> --
>> ;; Load RefTex
>> (add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
>> (autoload 'reftex-mode "reftex" "RefTeX Minor Mode" t)
>> (autoload 'turn-on-reftex  "reftex" "RefTeX Minor Mode" nil)
>> (autoload 'reftex-citation "reftex-cite" "Make citation" nil)
>> (autoload 'reftex-index-phrase-mode "reftex-index" "Phrase mode" t)
>> (add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
>> (add-hook 'latex-mode-hook 'turn-on-reftex)   ; with Emacs latex mode
>>
>> ;; Make RefTeX faster
>> (setq reftex-enable-partial-scans t)
>> (setq reftex-save-parse-info t)
>> (setq reftex-use-multiple-selection-buffers t)
>> (setq reftex-plug-into-AUCTeX t)
>>
>> (setq reftex-default-bibliography 
>> '("/home/julian/Documents/Refs/BibTex/references.bib"))
>> (setq reftex-sort-bibtex-matches "author")   ; Sort entries found in BibTex 
>> database 
>> (setq bibtex-dialect "biblatex")
>>
>> --
>> (require 'org-ref)
>>
>> (setq org-ref-bibliography-notes "/home/julian/Documents/org files/notes.org"
>>   org-ref-default-bibliography 
>> '("/home/julian/Documents/Refs/BibTex/references.bib")
>>   org-ref-pdf-directory "/home/julian/Documents/Refs/")
>>  (setq org-ref-default-citation-link "parencite")
>>  
>> --
>>
>> Below I am sending you very simple .org and .bib files that (in my computer)
>> reproduce this behaviour.  In this file I did use
>> org-ref-insert-bibliography-link.  Let me know if I can give you any other 
>> information.  
>>
>> All the best,
>>
>> Julian
>>
>> --Start trial.org file 
>> 
>>
>> * Trial
>> Some references
>> parencite:Brown2011a,Hobbs2006
>>
>> bibliography:~/Documents/trial.bib
>>
>> --End trial.org file 
>> -
>>
>>
>> --Start trial.bib f

Re: [O] org-ref "no key found"

2014-09-12 Thread Julian M. Burgos
Hi John,

I am resending this... I think it did not went through the previous
time.

I think I can replicate the org-ref bug now (if it is a bug).  This is
the situation:

a) If I open emacs, load a file that already has some link, and click on
the link (or place the cursor on it and press enter) I get the "no key
found" message and I cannot open the notes file (I get a "Wrong type
argument: stringp, nil"), although the link to the pdf file works.  If I
open more than one file, links do not work in any of them.  At this
point if I check the value of the "org-ref-default-bibliography"
variable, I get the correct path and filename of my .bib file.

b) If I insert a new citation (using Ctrl-]) in any of the documents,
links work as they should in all documents (this is, I get the title and
I can open the notes file).
>
I should say that I am not using the org-ref-insert-bibliography-link
function, because I use biblatex and I prefer to insert the Latex
\printbibliography command.  But if use it and insert the bibliography
link, the behaviour does not change.

This is what I have in my .emacs file that is related to RefTex and
org-ref:

--
;; Load RefTex
(add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
(autoload 'reftex-mode "reftex" "RefTeX Minor Mode" t)
(autoload 'turn-on-reftex  "reftex" "RefTeX Minor Mode" nil)
(autoload 'reftex-citation "reftex-cite" "Make citation" nil)
(autoload 'reftex-index-phrase-mode "reftex-index" "Phrase mode" t)
(add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
(add-hook 'latex-mode-hook 'turn-on-reftex)   ; with Emacs latex mode

;; Make RefTeX faster
(setq reftex-enable-partial-scans t)
(setq reftex-save-parse-info t)
(setq reftex-use-multiple-selection-buffers t)
(setq reftex-plug-into-AUCTeX t)

(setq reftex-default-bibliography 
'("/home/julian/Documents/Refs/BibTex/references.bib"))
(setq reftex-sort-bibtex-matches "author")   ; Sort entries found in BibTex 
database 
(setq bibtex-dialect "biblatex")

--
(require 'org-ref)

(setq org-ref-bibliography-notes "/home/julian/Documents/org files/notes.org"
  org-ref-default-bibliography 
'("/home/julian/Documents/Refs/BibTex/references.bib")
  org-ref-pdf-directory "/home/julian/Documents/Refs/")
 (setq org-ref-default-citation-link "parencite")
 
--

Below I am sending you very simple .org and .bib files that (in my computer)
reproduce this behaviour.  In this file I did use
org-ref-insert-bibliography-link.  Let me know if I can give you any other 
information.  

All the best,

Julian

--Start trial.org file 


* Trial
Some references
parencite:Brown2011a,Hobbs2006

bibliography:~/Documents/trial.bib

--End trial.org file 
-


--Start trial.bib file 
----

Article{Brown2011a,
  Title= {Quantitative approaches in climate change 
ecology},
  Author   = {Brown, C.J. and Schoeman, D.S. and Sydeman, W.J. 
and Brander, K. and Buckley, L.B. and Burrows, M. and Duarte, C.M. and Moore, 
P.J. and Pandolfi, J.M. and Poloczanska, E. and others},
  Journaltitle = {Global Change Biology},
  Year = {2011},

  Crossref = {burnhm},
  File = {:Brown2011a.pdf:PDF},
  Publisher= {Wiley Online Library}
}

@Article{Hobbs2006,
  Title= {Alternatives to statistical hypothesis testing in 
ecology: a guide to self teaching},
  Author   = {Hobbs, N.T. and Hilborn, R.},
  Journaltitle = {Ecological Applications},
  Year = {2006},
  Number   = {1},
  Pages= {5--19},
  Volume   = {16},

  Crossref = {Quick2010},
  File = {:Hobbs2006.pdf:PDF},
  Publisher= {Eco Soc America}
}

--End trial.bib file 
-




> Julian M. Burgos writes:
>
>> John, for some weird reason everything seems to be working now.  Thanks
>> for your help... I will let you know if I break it again.
>>
>> John Kitchin writes:
>>
>>> that is odd. this means org-ref is not finding the key you clicked
>>> on. could you send me a small example that repr

[O] Easy way of inspecting / showing value of property?

2014-09-10 Thread Rainer M Krug
Hi

From time to time my exports / tangles / executions of code blocks do
not work as expected, and in many cases this is caused by a wrong value
in the :header-arguments property.

Is there an easy way to inspect the value of this (or any other?)
property in org?

If I use the column view defined as 

,
| #+PROPERTY: header-args :tangle-mode (identity #o444)
| #+PROPERTY: header-args+ :tangle no
| #+PROPERTY: header-args+ :mkdirp yes
| #+PROPERTY: header-args+ :exports both
| #+PROPERTY: header-args+ :comments both
| #+PROPERTY: header-args+ :padline yes
| #+PROPERTY: header-args+ :eval no-export
| 
| #+PROPERTY: header-args:R :session *R_proMixStands*
| 
| #+COLUMNS: %25ITEM %TAGS %PRIORITY %TODO %header-args
`

the header-args column is always empty, although the property is set at
the file level (see above) and also at the subtree level.

Also, column view does not show the properties of code blocks.

Is there a way of showing the value of the property :header-args?

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgplF0E5Ozhcf.pgp
Description: PGP signature


Re: [O] Difference :header-args: and :header-args+:?

2014-09-09 Thread Rainer M Krug
Achim Gratz  writes:

> Rainer M Krug writes:
>> If this is the case, I would opt, in addition to the + operator, to
>> have a - operator, which *removes* properties from the property set
>> :header-args.
>
> Properties don't work that way, they're just strings.

So the + adds a string to the end of the inherited (or before defined)
string - correct? If this is the case, the same property can be
mwentioned in the :header-qrgs string? 

>
>> Initially I thought, to use :header-args+ instead of :header-args would
>> work, but I was wrong (see below).
>
> It's supposed to work, but doesn't due to a bug in the property API.

OK - good to know.

Rainer

>
>
> Regards,
> Achim.

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpVjuXzmKaFS.pgp
Description: PGP signature


Re: [O] Difference :header-args: and :header-args+:?

2014-09-09 Thread Rainer M Krug
 problem that the properties in :header-args are evaluated
From left to right, and if one is found, this one is used? In case of
inheritance (and adding a property via :header-args+) appends it, and if
a same one exists before, the older one is used?

>
> From your other mail:
>
> 2014ko irailak 8an, Achim Gratz-ek idatzi zuen:
>> 
>> Rainer M Krug writes:
>>> Aaron Ecay  writes:
>
> [...]
>
>>>> Are you aware that you can set individual header args as properties?
>>>> Something like (at the file level):
>> 
>> Are you aware that this doesn't quite do what you think it does, some of
>> the time, when things become more complex than your example?
>
> Again, can you say more about what you mean here?  As a personal
> anecdote, I have never been surprised by the behavior of “classic”
> header arg properties.
>
>> 
>>> I was using this deprecated behavior and I was *very* happy with it, but
>>> I am trying to adjust to the new syntax.
>>> 
>>> So how can I use the new syntax?
>> 
>> If you maybe had an example of what you're trying to do instead of
>> asking stuff about things you don't want to do?  Otherwise, have a look
>> at
>> 
>> /testing/examples/ob-header-arg-defaults.org
>
> I find the content of this file incredibly dense, and the suggestion
> of its use as documentation bordering on a joke.  (Documentation may
> not exist, and that just means an area for improvement has been found.
> But it’s not as though we’re all going to read that file and suddenly
> understand what you mean.)  It looks like it is trying to demonstrate
> inheritance and overriding of :var header args.  I can’t figure out
> why the #+call in “Overwrite” gets go1, but the addition of “var+ to1”
> in “Accumulate” causes this to shift, not to “to1”, but to “ge1”.
> That is a very confusing interaction (to name just one).  It’s also not
> clear to me how it relates to other header args, since vars supplement
> each other, whereas other types of header replace.

I just looked at it - and there are may things going on which are way to
complex to understand the basics of the use of :header-args (or rather
working with property sets (or lists?) in general?) in org/

A still confused

Rainer
-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp3iAiQVJXml.pgp
Description: PGP signature


Re: [O] Difference :header-args: and :header-args+:?

2014-09-09 Thread Rainer M Krug
Sorry about some points - see corrections below:

Rainer M Krug  writes:

> Achim Gratz  writes:
>
>> Aaron Ecay writes:
>>> Eric Schulte has said <http://mid.gmane.org/87wqce0w9n@gmail.com>
>>> that the deprecation of this feature is “premature”.  I didn’t realize
>>> at the time that the deprecation was also included in the manual rather
>>> than just a code comment.  Possibly it should be un-deprecated.
>>
>> It shouldn't, owing to a number of essentially un-fixable corner cases
>> and its inherent non-scaleability.
>>
>>> Certainly I agree that the suggested replacement is less capable.
>>
>> Do you have an example of something that it cannot do (modulo the bugs
>> and corners of the deprecated syntax)?
>
> I agree with Achim, that the new header-args should be able to do the
> same as the old syntax, but I also think that it is more "clunky" and
> less easy to grasp how to do things.
>
> And the problem are 
>
> a) the different ways that properties can be set (system wide, file
> wide, subtree level, code block - I might have forgotten some),
>
> b) the different levels and
>
> d) the inheritance rules of these levels (I assume inheritance is only
> in subtrees and code blocks in the subtree? How do file wide and system
> wide properties play here? (7.4. Property Inheritance, I am confused about the
> system wide and file wide properties?


d) the inheritance rules of these levels - In the manual it says it is
off (7.4 Property Inheritance):

,
| Org mode does not turn this on by default, because it can slow down
| property searches significantly and is often not needed.  However, if
| you find inheritance useful, you can turn it on by setting the variable
| `org-use-property-inheritance'.
`

But based on my experience it is on? Also in the examples it is on?
Especially the inheritance with the combination of the + is confusing
to me. If inheritance is on, the + should add an argument to the
header-args property, while without the +, it should overwrite the
inherited property? Or do they do the same?


>
> I know that this information is likely somewhere in the manual, but this
> whole issue of properties (especially when including the +) becomes
> rather confusing to me.
>
> Rainer
>
>>
>>
>> Regards,
>> Achim.

-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :   +33 - (0)9 53 10 27 44
Cell:   +33 - (0)6 85 62 59 98
Fax :   +33 - (0)9 58 10 27 44

Fax (D):+49 - (0)3 21 21 25 22 44

email:  rai...@krugs.de

Skype:  RMkrug

PGP: 0x0F52F982


pgpcEGUlQHUML.pgp
Description: PGP signature


Re: [O] Difference :header-args: and :header-args+:?

2014-09-09 Thread Rainer M Krug
Achim Gratz  writes:

> Aaron Ecay writes:
>> Eric Schulte has said <http://mid.gmane.org/87wqce0w9n@gmail.com>
>> that the deprecation of this feature is “premature”.  I didn’t realize
>> at the time that the deprecation was also included in the manual rather
>> than just a code comment.  Possibly it should be un-deprecated.
>
> It shouldn't, owing to a number of essentially un-fixable corner cases
> and its inherent non-scaleability.
>
>> Certainly I agree that the suggested replacement is less capable.
>
> Do you have an example of something that it cannot do (modulo the bugs
> and corners of the deprecated syntax)?

I agree with Achim, that the new header-args should be able to do the
same as the old syntax, but I also think that it is more "clunky" and
less easy to grasp how to do things.

And the problem are 

a) the different ways that properties can be set (system wide, file
wide, subtree level, code block - I might have forgotten some),

b) the different levels and

d) the inheritance rules of these levels (I assume inheritance is only
in subtrees and code blocks in the subtree? How do file wide and system
wide properties play here? (7.4. Property Inheritance, I am confused about the
system wide and file wide properties?

I know that this information is likely somewhere in the manual, but this
whole issue of properties (especially when including the +) becomes
rather confusing to me.

Rainer

>
>
> Regards,
> Achim.

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpo1uC5z05Rx.pgp
Description: PGP signature


Re: [O] Difference :header-args: and :header-args+:?

2014-09-08 Thread Rainer M Krug
I would like to ping this question, as it is still bothering me and I
could not find any explanation.

Thanks,

Rainer

Aaron Ecay  writes:

> Hi Rainer,
>
> 2014ko irailak 5an, Rainer M Krug-ek idatzi zuen:
>> 
>> Absolutely - but this has been (unfortunately!!!) be deprecated:
>> 
>> Quoted from the manual [1] :
>> 
>> ,
>> | [1] The deprecated syntax for default header argument properties, using
>> | the name of the header argument as a property name directly, evaluates
>> | the property as seen by the corresponding source block definition. This
>> | behavior has been kept for backwards compatibility.
>> `
>> 
>> I was using this deprecated behavior and I was *very* happy with it, but
>> I am trying to adjust to the new syntax.
>> 
>> So how can I use the new syntax?
>
> Eric Schulte has said <http://mid.gmane.org/87wqce0w9n@gmail.com>
> that the deprecation of this feature is “premature”.  I didn’t realize
> at the time that the deprecation was also included in the manual rather
> than just a code comment.  Possibly it should be un-deprecated.
>
> Certainly I agree that the suggested replacement is less capable.  Sorry
> I can’t help more.  Maybe Eric or Achim (who introduced the deprecation)
> will comment.

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpQtmWoH1Rmf.pgp
Description: PGP signature


[O] Floating Table of figures in html export?

2014-09-08 Thread Rainer M Krug
Hi

now that I have a floating TOC in my exported html, is there a way of 

1) adding a Table of Figures in the html export (I have it in the LaTeX
export), and 

2) how can I make this one floating as well?

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpAss7aKwKsb.pgp
Description: PGP signature


[O] Make html password protected?

2014-09-08 Thread Rainer M Krug
Hi

I do not have much experience with html and websites (what an
understatement!) but I would like to publish / export a simple html page
password protected. Is ther an easy way to do it in word?

The content is not highly confidential or sensitive, just some analysis
for a paper of which I would like to provide regular feedback to my
co-authors and which should not be to easily readable by others.

Any suggestions?

Rainer
-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgptryG02Ks_m.pgp
Description: PGP signature


Re: [O] org-ref "no key found"

2014-09-08 Thread Julian M. Burgos
Hi John, 
I think I can replicate the org-ref bug now (if it is a bug).  This is the 
situation:

a) If I open emacs, load a file that already has some link, and click on
the link (or place the cursor on it and press enter) I get the "no key
found" message and I cannot open the notes file (I get a "Wrong type
argument: stringp, nil"), although the link to the pdf file works.  If I open 
more
than one file, links do not work in any of them.  At this point if I
check the value of the "org-ref-default-bibliography" variable, I get
the correct path and filename of my .bib file.

b) If I insert a new citation (using Ctrl-]) in any of the documents,
links work as they should in all documents (this is, I get the title and
I can open the notes file).  

I should say that I am not using the org-ref-insert-bibliography-link
function, because I use biblatex and I prefer to insert the Latex
\printbibliography command.  But if use it and insert the bibliography
link, the behaviour does not change.

This is what I have in my .emacs file that is related to RefTex and org-ref:

--
;; Load RefTex
(add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
(autoload 'reftex-mode "reftex" "RefTeX Minor Mode" t)
(autoload 'turn-on-reftex  "reftex" "RefTeX Minor Mode" nil)
(autoload 'reftex-citation "reftex-cite" "Make citation" nil)
(autoload 'reftex-index-phrase-mode "reftex-index" "Phrase mode" t)
(add-hook 'LaTeX-mode-hook 'turn-on-reftex)   ; with AUCTeX LaTeX mode
(add-hook 'latex-mode-hook 'turn-on-reftex)   ; with Emacs latex mode

;; Make RefTeX faster
(setq reftex-enable-partial-scans t)
(setq reftex-save-parse-info t)
(setq reftex-use-multiple-selection-buffers t)
(setq reftex-plug-into-AUCTeX t)

(setq reftex-default-bibliography 
'("/home/julian/Documents/Refs/BibTex/references.bib"))
(setq reftex-sort-bibtex-matches "author")   ; Sort entries found in BibTex 
database 
(setq bibtex-dialect "biblatex")

--
(require 'org-ref)

(setq org-ref-bibliography-notes "/home/julian/Documents/org files/notes.org"
  org-ref-default-bibliography 
'("/home/julian/Documents/Refs/BibTex/references.bib")
  org-ref-pdf-directory "/home/julian/Documents/Refs/")

(setq org-ref-default-citation-link "parencite")
--

I am sending you very simple .org and .bib files that (in my computer)
reproduce this behaviour.  In this file I did use
org-ref-insert-bibliography-link.  Let me know if I can give you any other 
information.  

All the best,

Julian



trial.bib
Description: Binary data


trial.org
Description: Lotus Organizer


Julian M. Burgos writes:

> John, for some weird reason everything seems to be working now.  Thanks
> for your help... I will let you know if I break it again.
>
> John Kitchin writes:
>
>> that is odd. this means org-ref is not finding the key you clicked
>> on. could you send me a small example that reproduces your problem (an
>> org-file and the bib file)?
>>
>> "Julian M. Burgos"  writes:
>>
>>> Hi John, 
>>>
>>> No, they still do not work even after I click on the bibliography link
>>> and get my .bib file opened.
>>>
>>> Julian
>>>
>>> John Kitchin writes:
>>>
>>>> "Julian M. Burgos"  writes:
>>>>
>>>> If you click on the bibliography link to open the file, and then go back
>>>> to your org-file, do the cite links work?
>>>>
>>>> I suspect the notes problem is related to the no key found problem.
>>>>
>>>>> Hello everyone,
>>>>>
>>>>> I am playing around with Joh Kitchin's excellent org-ref, and I am
>>>>> having a few issues.  In my .emacs file I have set up the values for the
>>>>> org-ref-bibliography-notes, org-ref-default-bibliography, and
>>>>> org-ref-pdf-directory.
>>>>>
>>>>> With this I can access my .bib database and use org-ref-insert-cite link
>>>>> to add a citation link with no problems.  But when I press enter on the
>>>>> cite link, I get the following message:
>>>>>
>>>>> no key found
>>>>>  (No key found) (p)df (u)rl (n)otes (q) quit
>>>>>
>>>>> If I press "p" I get the pdf file, but if I press "n" I get the
>>>>> following message: 
>>>>>
>>>>> "Wrong type argument: stringp, nil".
>>>>>
>>>>> Any ideas how to solve this?
>>>>>
>>>>> Many thanks,
>>>>>
>>>>> Julian


-- 
Julian Mariano Burgos, PhD
Hafrannsóknastofnun/Marine Research Institute
Skúlagata 4, 121 Reykjavík, Iceland
Sími/Telephone : +354-5752037
Bréfsími/Telefax:  +354-5752001
Netfang/Email: jul...@hafro.is


[O] Downloadable mailing list archive?

2014-09-05 Thread Rainer M Krug
Hi 

is there a downloadable mailing list archive in maildir format for
org-mode?

I know I can download the mbox from gmane, but I would prefer maildir
format.

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpol1L_nCFNV.pgp
Description: PGP signature


Re: [O] Difference :header-args: and :header-args+:?

2014-09-05 Thread Rainer M Krug
Aaron Ecay  writes:

> Hi Rainer,
>
> 2014ko irailak 4an, Rainer M Krug-ek idatzi zuen:
>> 
>> Hi
>> 
>> I have a question concerning the property :header-args:. In addition
>> to :header-args: there is also :header-args+:.
>> 
>> 
>> 1) If I set some properties globally and in a subtree I want to *add* a
>> *new* header argument - do I have to use the + or not?
>> 
>> 2) If I set some properties globally and in a subtree I want to *change*
>> a *single* header argument which *was set globally* - do I have to use
>> the + or not?
>
> Are you aware that you can set individual header args as properties?
> Something like (at the file level):
>
> #+property: session *foo*
>
> or (at the subtree level):
>
> :PROPERTIES:
> :session: *foo*
> :END:
>
> This will likely be easier than trying to do surgery on the header-args
> property.

Absolutely - but this has been (unfortunately!!!) be deprecated:

Quoted from the manual [1] :

,
| [1] The deprecated syntax for default header argument properties, using
| the name of the header argument as a property name directly, evaluates
| the property as seen by the corresponding source block definition. This
| behavior has been kept for backwards compatibility.
`

I was using this deprecated behavior and I was *very* happy with it, but
I am trying to adjust to the new syntax.

So how can I use the new syntax?

Rainer

Footnotes: 
[1]  
http://orgmode.org/manual/Header-arguments-in-Org-mode-properties.html#Header-arguments-in-Org-mode-properties

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgplohVIvhXWD.pgp
Description: PGP signature


Re: [O] graphics for html and latex / pdf export?

2014-09-04 Thread Rainer M Krug
Thorsten Jolitz  writes:

> Rainer M Krug  writes:
>
>> OK - ignore my comment concerning R - this is working. I am just trying
>> it out. HTML works perfectly. 
>>
>> I am just struggling with pdf. I have to set the org-latex-pdf-process
>> to "pdflatex -shell-escape -interaction nonstopmode -output-directory %o
>> %f" and, due to security concerns, only want to set it via file local
>> variable. But I somehow don't manage it.
>>
>> ,
>> | # Local Variables:
>> | # org-latex-pdf-process: "pdflatex -shell-escape -interaction
>> | nonstopmode -output-directory %o %f"
>> | # End:
>> `
>>
>> Does not work ("No valid command to process pdf"). How can I set the
>> command as a file local variable?
>
> maybe as list like here:
>
> % reftex-ref-style-default-list: ("Fancyref")

Perfect - working.

Thanks a lot,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp7ZFH3QL7tf.pgp
Description: PGP signature


Re: [O] graphics for html and latex / pdf export?

2014-09-04 Thread Rainer M Krug
OK - ignore my comment concerning R - this is working. I am just trying
it out. HTML works perfectly. 

I am just struggling with pdf. I have to set the org-latex-pdf-process
to "pdflatex -shell-escape -interaction nonstopmode -output-directory %o
%f" and, due to security concerns, only want to set it via file local
variable. But I somehow don't manage it.

,
| # Local Variables:
| # org-latex-pdf-process: "pdflatex -shell-escape -interaction nonstopmode 
-output-directory %o %f"
| # End:
`

Does not work ("No valid command to process pdf"). How can I set the
command as a file local variable?

Rainer
 

Rainer M Krug  writes:

> Aaron Ecay  writes:
>
>> Hi Rainer,
>>
>> One option is to use svg graphics, which are supported in latex (via the
>> svg package from CTAN) and in HTML (on almost all modern browsers:
>> <http://caniuse.com/#feat=svg>).  The svg latex package supports
>> compiling with pdflatex out of the box and lualatex with a little
>> hackery; xelatex is not supported (you also need to install inkscape and
>> compile with a flag that allows latex code to execute shell commands).
>
> svg does not work easily, as I have to use the cairo package in R to use
> it, so I have to add this manually. Nevertheless, I could do this in a
> session in a block before.
>
>>
>> Otherwise, you might be looking for something like this worg page:
>> <http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html#sec-4-3>.
>
> That one works nicely when generating the graphs on export - but I
> would like to do no evaluations on export to have the org file as a
> "output" itself.
>
> Thanks a lot,
>
> Rainer
>
>>
>> And also search “by-backend” in the mailing list archives for other
>> relevant examples.
>>
>> Hope this is helpful,

-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :   +33 - (0)9 53 10 27 44
Cell:   +33 - (0)6 85 62 59 98
Fax :   +33 - (0)9 58 10 27 44

Fax (D):+49 - (0)3 21 21 25 22 44

email:  rai...@krugs.de

Skype:  RMkrug

PGP: 0x0F52F982


pgpdRf97uA5fJ.pgp
Description: PGP signature


Re: [O] graphics for html and latex / pdf export?

2014-09-04 Thread Rainer M Krug
Aaron Ecay  writes:

> Hi Rainer,
>
> One option is to use svg graphics, which are supported in latex (via the
> svg package from CTAN) and in HTML (on almost all modern browsers:
> <http://caniuse.com/#feat=svg>).  The svg latex package supports
> compiling with pdflatex out of the box and lualatex with a little
> hackery; xelatex is not supported (you also need to install inkscape and
> compile with a flag that allows latex code to execute shell commands).

svg does not work easily, as I have to use the cairo package in R to use
it, so I have to add this manually. Nevertheless, I could do this in a
session in a block before.

>
> Otherwise, you might be looking for something like this worg page:
> <http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-LaTeX.html#sec-4-3>.

That one works nicely when generating the graphs on export - but I
would like to do no evaluations on export to have the org file as a
"output" itself.

Thanks a lot,

Rainer

>
> And also search “by-backend” in the mailing list archives for other
> relevant examples.
>
> Hope this is helpful,

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgp9l59mEnDEu.pgp
Description: PGP signature


[O] Difference :header-args: and :header-args+:?

2014-09-04 Thread Rainer M Krug
Hi

I have a question concerning the property :header-args:. In addition
to :header-args: there is also :header-args+:.


1) If I set some properties globally and in a subtree I want to *add* a
*new* header argument - do I have to use the + or not?

2) If I set some properties globally and in a subtree I want to *change*
a *single* header argument which *was set globally* - do I have to use
the + or not?

I am asking, because the + version is not mentioned in the manual and I
have the feeling there are some inconsistencies, but I want to confirm
if I understand this correctly before reporting these.

Thanks,

Rainer

-- 
Rainer M. Krug
email: Rainerkrugsde
PGP: 0x0F52F982


pgpZGqI8rzKI1.pgp
Description: PGP signature


<    4   5   6   7   8   9   10   11   12   13   >