Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Am 15.05.2014 um 06:49 schrieb Vikas Rawal : > > I think starter-kit is a good choice. You will be up and running in no time. > Just put it in place. > Well, time moves differently around here. Since I use Aquamacs it took me over a day to get it working. A google sear gave me: The starter kit is designed to be used with GNU Emacs. Version 24 or later is required, and the current released version (24.3) is recommended. It will not work with Aquamacs without modification. Seriously? That it? No "Here are the necessary modifications"? It seems to work now. I write a separate article to describe what I did. Axel
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
>>> >> >> May be I should specify the packages that are being called, so the user can >> make sure those are installed or modify the config file. But I prefer the >> basic set of LaTeX packages being called by default rather than being added >> in every file. > > This will be a problem when one of your collaborators doesn't use your config > files. > There are many packages for tabular/table environments. > Having them in the document gives a strong hint that there is something > different that may collide with the packages another user prefers. (No-one > can agree on a basic set of LaTeX packages:-) > > If you keep them in the configuration file, the user has to extract the > relevant information > > (setq org-latex-default-packages-alist …) > > from your configuration and add it to their configuration file. > > You can always supply a template file with all the relevant > +LaTeX_HEADER > definitions. > > You can even have lines like > > #+LaTeX_HEADER: \usepackage{tabulary} % provides column specification LCRJ > #+LaTeX_HEADER: \usepackage{threeparttable} % A table with cation and notes > #+LaTeX_HEADER: \renewcommand{\TPTminimum}{\linewidth} % configure > threeparttable > #+Latex_HEADER: %\usepackage{tgschola} % enable to use the Schola font > #+Latex_HEADER: %\usepackage{tgbonum} % enable to use the Bonum font > #+Latex_HEADER: %\usepackage{tgpagella} % enable to use the Pagella font > #+Latex_HEADER: \usepackage[urw-garamond]{mathdesign} \linespread{1.0609} This may be a better solution. We could even provide a separate file with sample lines that need to go at the top, which can be modified if needed, to be called in using #+INCLUDE: into a document. Since Suvayu has offered to have a go at modifying the document for Worg, I would wait for him to do what he thinks may be best. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Am 15.05.2014 um 06:49 schrieb Vikas Rawal : >>> I removed explicit inclusion of these packages from this document and the >>> instructions, because I wanted to reduce the work in terms of setting >>> things up. >> >> You achieved the opposite. >> Now a user *has* to enable the config file. >> Otherwise it would be clear that additional packages may be needed which may >> not be part of a minimal TeX Live installation. >> > > May be I should specify the packages that are being called, so the user can > make sure those are installed or modify the config file. But I prefer the > basic set of LaTeX packages being called by default rather than being added > in every file. This will be a problem when one of your collaborators doesn't use your config files. There are many packages for tabular/table environments. Having them in the document gives a strong hint that there is something different that may collide with the packages another user prefers. (No-one can agree on a basic set of LaTeX packages:-) If you keep them in the configuration file, the user has to extract the relevant information (setq org-latex-default-packages-alist …) from your configuration and add it to their configuration file. You can always supply a template file with all the relevant +LaTeX_HEADER definitions. You can even have lines like #+LaTeX_HEADER: \usepackage{tabulary} % provides column specification LCRJ #+LaTeX_HEADER: \usepackage{threeparttable} % A table with cation and notes #+LaTeX_HEADER: \renewcommand{\TPTminimum}{\linewidth} % configure threeparttable #+Latex_HEADER: %\usepackage{tgschola} % enable to use the Schola font #+Latex_HEADER: %\usepackage{tgbonum} % enable to use the Bonum font #+Latex_HEADER: %\usepackage{tgpagella} % enable to use the Pagella font #+Latex_HEADER: \usepackage[urw-garamond]{mathdesign} \linespread{1.0609} and let the user decide which to use instead of hiding this in an option which requires modifications of the latex exporter. (My Latex template has several pages of commented preamble. I activate only what I need but I have everything available, including common usage examples.) But in the end this is your decision, you know what works best for your users and I know how to modify the configuration to suit my needs. Axel
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
> >> >> Thank you Axel for taking the time to test it. I look forward to more >> comments as you look at it. You comments are very useful. > > I'm new to Emacs, but know LaTeX and Pandoc. > I have a lot of beginner’s questions. > (Configuring emacs is quite difficult: should I use > - custom-set-variable > - starter-kit > - raw elisp in .emacs > ) > You could use either. I think starter-kit is a good choice. You will be up and running in no time. Just put it in place. If you are using the starter kit, you should create a sub-directory inside .emacs.d with your username. Any .org file or .el file you keep inside will be evaluated when you start emacs. If you put my config file in that sub-directory, you are good to go as far as my basic set up goes. In addition, you could have your personal config files for whatever additional you want. This is not necessarily “optimal”, but it will be quick and clean. As you learn, you can customise to make it optimal to your needs. > In your document you are using alt instead of meta. > Not everyone uses alt for meta (especially on the Mac where alt (option) is > used to access unusual characters). > >>> I tried to export the .org to Latex and failed because it needed >>> tabulary and threeparttable. >>> >>> They are used if you use vikas-general.org but as far as i understood the >>> document that is just recommended. >>> >>> I added the line >>> #+LaTeX_HEADER: \usepackage{tabulary,threeparttable} >>> to the document. >>> >> >> vikas-general.org (I already dislike my name being on that file) > > How about > > config.org ? > config-example.org ? > And ask the user to copy it to $USER.org > Yes, one of these, I guess. I want to leave $user.org for additional personal configurations that the person may want to do. >> I removed explicit inclusion of these packages from this document and the >> instructions, because I wanted to reduce the work in terms of setting things >> up. > > You achieved the opposite. > Now a user *has* to enable the config file. > Otherwise it would be clear that additional packages may be needed which may > not be part of a minimal TeX Live installation. > May be I should specify the packages that are being called, so the user can make sure those are installed or modify the config file. But I prefer the basic set of LaTeX packages being called by default rather than being added in every file. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Am 14.05.2014 um 18:51 schrieb Vikas Rawal : > > Thank you Axel for taking the time to test it. I look forward to more > comments as you look at it. You comments are very useful. I'm new to Emacs, but know LaTeX and Pandoc. I have a lot of beginner’s questions. (Configuring emacs is quite difficult: should I use - custom-set-variable - starter-kit - raw elisp in .emacs ) In your document you are using alt instead of meta. Not everyone uses alt for meta (especially on the Mac where alt (option) is used to access unusual characters). >> I tried to export the .org to Latex and failed because it needed >> tabulary and threeparttable. >> >> They are used if you use vikas-general.org but as far as i understood the >> document that is just recommended. >> >> I added the line >> #+LaTeX_HEADER: \usepackage{tabulary,threeparttable} >> to the document. >> > > vikas-general.org (I already dislike my name being on that file) How about config.org ? config-example.org ? And ask the user to copy it to $USER.org > I removed explicit inclusion of these packages from this document and the > instructions, because I wanted to reduce the work in terms of setting things > up. You achieved the opposite. Now a user *has* to enable the config file. Otherwise it would be clear that additional packages may be needed which may not be part of a minimal TeX Live installation. >> You are using >> >> : #+LaTeX_CLASS_OPTIONS: [garamond] >> >> which results in >> >> \documentclass[garamond]{article} >> >> But garamond is not a valid option for article. >> > > This is where I got this from > > http://orgmode.org/worg/org-contrib/babel/examples/article-class.html#sec-4-3-2 > > I think it requires mathdesign to be loaded. But I will check. Yes, and some additional LaTeX coding. I'll wait for the next release and have a closer look. Axel
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Thank you Axel for taking the time to test it. I look forward to more comments as you look at it. You comments are very useful. > > I tried to export the .org to Latex and failed because it needed > tabulary and threeparttable. > > They are used if you use vikas-general.org but as far as i understood the > document that is just recommended. > > I added the line > #+LaTeX_HEADER: \usepackage{tabulary,threeparttable} > to the document. > vikas-general.org (I already dislike my name being on that file) specifies these as part of org-latex-default-package-list, so both tabulary and threeparttable should get included by default. I removed explicit inclusion of these packages from this document and the instructions, because I wanted to reduce the work in terms of setting things up. > Another problem I had are the URLs in the section titles. > They cause problems when running the tex file a second time. > > Runaway argument? > {R \(` `\045\BOOKMARK [2][-]{subsection.2.4}{Pandoc}{section.2}\BOOKMARK \ETC. > ! File ended while scanning use of \@@BOOKMARK. > >\par > > You may want to move the URLs from the section title to the body. > I thought I had fixed this. But will check again. > You are using straight (") quotation marks in org and the LaTeX export has > straight quotation marks. Is there a way to convert them to “” or \enquote? > Should use (setq org-export-with-smart-quotes t) Will add that to the revised abcd-general.org > You are using > > : #+LaTeX_CLASS_OPTIONS: [garamond] > > which results in > > \documentclass[garamond]{article} > > But garamond is not a valid option for article. > This is where I got this from http://orgmode.org/worg/org-contrib/babel/examples/article-class.html#sec-4-3-2 I think it requires mathdesign to be loaded. But I will check. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
>> >> Unless others feel differently, I would let the document float around the >> cyberspace, on my personal website and on github, for anyone to discover and >> use. > > I hate a good resource getting lost in the Internet. So I would like to > suggest you make a shorter version for Worg, just focusing on the > "producing a complete document part": R, ESS, pandoc, and all. > > Of course that requires more of your time and effort. So how about > using Worg as it is meant to be, copy paste the relevant sections into > worg and collaboratively trim it down to shape? > If people think that is a good idea, I could give this a first shot > sometime next week. > It would be wonderful if you could. At least some people seem to think it is useful to have a guide of this kind. If so, improving it together should be the way to go. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Am 12.05.2014 um 14:57 schrieb Vikas Rawal : > I have been using Org for writing research papers for a while, gradually > improving my set up to be able to exactly produce the output I want. In this > process, I have benefited greatly not only from the resources available on > the Org-mode website but also from various people who generously provided > solutions to my numerous queries on this mailing list. I felt that it may be > of some use if I put together all the pieces and document what I was doing. > > I have put the draft for comments at: > https://github.com/vikasrawal/orgpaper/blob/master/orgpapers.org This looks like a workflow I may like. A few comments: I tried to export the .org to Latex and failed because it needed tabulary and threeparttable. They are used if you use vikas-general.org but as far as i understood the document that is just recommended. I added the line #+LaTeX_HEADER: \usepackage{tabulary,threeparttable} to the document. Another problem I had are the URLs in the section titles. They cause problems when running the tex file a second time. Runaway argument? {R \(` `\045\BOOKMARK [2][-]{subsection.2.4}{Pandoc}{section.2}\BOOKMARK \ETC. ! File ended while scanning use of \@@BOOKMARK. \par You may want to move the URLs from the section title to the body. You are using straight (") quotation marks in org and the LaTeX export has straight quotation marks. Is there a way to convert them to “” or \enquote? You are using : #+LaTeX_CLASS_OPTIONS: [garamond] which results in \documentclass[garamond]{article} But garamond is not a valid option for article. I use this instead #+Latex_HEADER: \usepackage{tgschola} I tried ebgaramont, but that font does not contain TS1 support. Now I have a printable version of your document and will have a closer look. Greetings Axel
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Hi Vikas, On Tue, May 13, 2014 at 08:40:13PM +0200, Vikas Rawal wrote: > > > > It seems safer/efficient to focus on making modular documentation that > > is the definitive *best*/*right* way (and *best* explained) to do > > something, and then to link to that prolifically. > > > > Your points are very valid and expressed convincingly. > > Writing this document was a result of, first and foremost, a personal urge to > write it, and secondly, in view of very specific use cases (my graduate > students, to whom I wanted to provide a one-stop shop, before they explore > rest of the stuff). > > That said, your arguments that it is not optimal to include such a document > as part of documentation on orgmode.org is perhaps right. I can see that > maintaining modular non-repetitive content is easier. Long-term maintenance > of documentation should be an important concern for something that is under > heavy development. > > Unless others feel differently, I would let the document float around the > cyberspace, on my personal website and on github, for anyone to discover and > use. I hate a good resource getting lost in the Internet. So I would like to suggest you make a shorter version for Worg, just focusing on the "producing a complete document part": R, ESS, pandoc, and all. Of course that requires more of your time and effort. So how about using Worg as it is meant to be, copy paste the relevant sections into worg and collaboratively trim it down to shape? If people think that is a good idea, I could give this a first shot sometime next week. Cheers, -- Suvayu Open source is the future. It sets us free.
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Aloha Vikas, Vikas Rawal writes: > There is some overlap. But I think there is a considerable utility in > addressing people who would need to be taken from installation of > emacs to production of a full document. I'm in complete agreement here and hope you didn't read some criticism into my earlier comment. I write similar documents for my work group, but mine aren't as helpful and clear as yours is. All the best, Tom -- Thomas S. Dye http://www.tsdye.com
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
> > You mentioning pandoc as one of the tools to use made me finally sit > down and look at it. I am very glad I did. Just today, I started > working on a paper that has to be in Word format in the end. This is > always annoying but especially when the paper has mathematics in > it. I have been totally addicted to Org-mode, and find it absurd to write in Word. On the other hand, none of my collaborators use LaTeX or Org. For a long time, I produced PDFs, circulated them, and then in the end, when others had to work on the document, bit my lip and converted it painfully to Word, manually fixing all LaTeX-specific stuff. Pandoc is a treat and clearly the way to go, at least until development of odt exporter catches up. Am glad you found the document useful. If you have any feedback from your group, particularly on parts that you would think need improvement, do share them with me. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
> > It seems safer/efficient to focus on making modular documentation that > is the definitive *best*/*right* way (and *best* explained) to do > something, and then to link to that prolifically. > Your points are very valid and expressed convincingly. Writing this document was a result of, first and foremost, a personal urge to write it, and secondly, in view of very specific use cases (my graduate students, to whom I wanted to provide a one-stop shop, before they explore rest of the stuff). That said, your arguments that it is not optimal to include such a document as part of documentation on orgmode.org is perhaps right. I can see that maintaining modular non-repetitive content is easier. Long-term maintenance of documentation should be an important concern for something that is under heavy development. Unless others feel differently, I would let the document float around the cyberspace, on my personal website and on github, for anyone to discover and use. Thanks for your very reasonable comments. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
On Monday, 12 May 2014 at 14:57, Vikas Rawal wrote: > I have been using Org for writing research papers for a while, > gradually improving my set up to be able to exactly produce the output > I want. In this process, I have benefited greatly not only from the > resources available on the Org-mode website but also from various > people who generously provided solutions to my numerous queries on > this mailing list. I felt that it may be of some use if I put together > all the pieces and document what I was doing. > > I have put the draft for comments at: > https://github.com/vikasrawal/orgpaper/blob/master/orgpapers.org Thanks for this. I circulated it to my research group yesterday and I hope it convinces some to try. >From my perspective, I must say: thank you, thank you, thank you! You mentioning pandoc as one of the tools to use made me finally sit down and look at it. I am very glad I did. Just today, I started working on a paper that has to be in Word format in the end. This is always annoying but especially when the paper has mathematics in it. And this one does. I learned that pandoc exports latex to odt and docx including the conversion of equations. I had not been aware of this. This is a real time saver so thank you again! For me, org export to latex followed by pandoc to docx will be my preferred route when I need to create Word documents (which luckily is not that often), rather than using org's export to odt. -- : Eric S Fraga (0xFFFCF67D), Emacs 24.4.50.2, Org release_8.2.6-958-g7c8559-git
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
On Tue, May 13, 2014 at 12:48 PM, Vikas Rawal wrote: > > >> Aloha Vikas, >> >> Very nice! >> >> Your document overlaps and updates the LaTeX export tutorial on Worg >> that I wrote for the old exporter. Perhaps it could be revised to >> replace the old export tutorial? > > There is some overlap. But I think there is a considerable utility in > addressing people who would need to be taken from installation of emacs to > production of a full document. My 0.02 cents on this. As someone who often leans quite far toward the verbose/thorough end of the spectrum, I completely relate to this sentiment. That said, I've come to believe it's sub-optimal. With this approach, what ends up happening is: - Multiple versions of the same information proliferate (we're re-doing each other's work) - Similarly, there's more information to update down the road - While excellent/to-your-best-knowledge, the instructions you provide might not be the best ones Thus, I've started to believe how you approached the initial sections (install Emacs, R, Org) are better. A sentence or two, with a link to do the thing you're telling them to do. While it probably /won't/ happen (at least with the vast majority of those options), what if this page changes? - http://orgmode.org/manual/Export-settings.html You now have to update your table of various options as well. Even without that... I'm no longer convinced of the benefits of re-writing existing documentation for the sake of an all-in-one information source, unless it's a book (meant to be standalone). It seems safer/efficient to focus on making modular documentation that is the definitive *best*/*right* way (and *best* explained) to do something, and then to link to that prolifically. This feels horrible to write, as your document looks awesome. You did ask for feedback, and things migrated toward this area, so I wanted to flesh out why I think one might steer toward one approach vs. another. That said, as long as it isn't incorrect... more documentation is still almost always better to increase the probability of finding the right hit on Google, so thanks a ton for your contribution and effort to help others. Best regards, John > > That is, people start using a workable solution, and then go to more detailed > documentation to modify it to their needs and to learn rest of the stuff that > you can do with Org. > > I could, however, tweak it specifically for Worg depending on what is > considered most appropriate for Worg. > > Vikas > >
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
> Aloha Vikas, > > Very nice! > > Your document overlaps and updates the LaTeX export tutorial on Worg > that I wrote for the old exporter. Perhaps it could be revised to > replace the old export tutorial? There is some overlap. But I think there is a considerable utility in addressing people who would need to be taken from installation of emacs to production of a full document. That is, people start using a workable solution, and then go to more detailed documentation to modify it to their needs and to learn rest of the stuff that you can do with Org. I could, however, tweak it specifically for Worg depending on what is considered most appropriate for Worg. Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Aloha Vikas, Very nice! Your document overlaps and updates the LaTeX export tutorial on Worg that I wrote for the old exporter. Perhaps it could be revised to replace the old export tutorial? Just a thought. All the best, Tom Vikas Rawal writes: >> >>> For whatever it is worth, here it is. Pointers to any errors as well >>> as comments for improving it would be greatly appreciated. Also, I >>> would be happy to contribute it to Worg, if people consider it useful. >> >> Some comments: at places it seemed a bit too verbose, e.g. when you are >> introducing some idea/technique. I think it would be nice if you could >> make it a bit more concise. > > Did you miss “social sciences” in the title :) > > Jokes apart, will try to look at the text and improve as much as I > can. Specific suggestions welcome. > >> I also noticed a few things in the >> formatting that looked LaTeX specific; e.g. \FloatBarrier after the >> table on keybindings. If you intend to include this in Worg, I think >> you should remove these. In fact you can explicitly target html. >> > > Thanks. \FloatBarrier gone. Also done a few other fixes. > > Looking forward to further comments. > > Best, > > Vikas > -- Thomas S. Dye http://www.tsdye.com
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
> >> For whatever it is worth, here it is. Pointers to any errors as well >> as comments for improving it would be greatly appreciated. Also, I >> would be happy to contribute it to Worg, if people consider it useful. > > Some comments: at places it seemed a bit too verbose, e.g. when you are > introducing some idea/technique. I think it would be nice if you could > make it a bit more concise. Did you miss “social sciences” in the title :) Jokes apart, will try to look at the text and improve as much as I can. Specific suggestions welcome. > I also noticed a few things in the > formatting that looked LaTeX specific; e.g. \FloatBarrier after the > table on keybindings. If you intend to include this in Worg, I think > you should remove these. In fact you can explicitly target html. > Thanks. \FloatBarrier gone. Also done a few other fixes. Looking forward to further comments. Best, Vikas
Re: [O] Using Emacs, Org-mode and R for Research Writing in Social Sciences
Hi Vikas, On Mon, May 12, 2014 at 02:57:19PM +0200, Vikas Rawal wrote: > > I have put the draft for comments at: > https://github.com/vikasrawal/orgpaper/blob/master/orgpapers.org Firstly a thank you for writing it. I gave it a quick cursory glance, seems nice and thorough, and very appropriate for your target audience :). > For whatever it is worth, here it is. Pointers to any errors as well > as comments for improving it would be greatly appreciated. Also, I > would be happy to contribute it to Worg, if people consider it useful. Some comments: at places it seemed a bit too verbose, e.g. when you are introducing some idea/technique. I think it would be nice if you could make it a bit more concise. I also noticed a few things in the formatting that looked LaTeX specific; e.g. \FloatBarrier after the table on keybindings. If you intend to include this in Worg, I think you should remove these. In fact you can explicitly target html. That's it for now :). Cheers, -- Suvayu Open source is the future. It sets us free.