* Output of R babel blocks with quotes is mangled/truncated
@ 2012-07-08 3:22 Viktor Rosenfeld
2012-07-08 15:28 ` cberry
0 siblings, 1 reply; 3+ messages in thread
From: Viktor Rosenfeld @ 2012-07-08 3:22 UTC (permalink / raw)
To: emacs-orgmode
Hi,
if a value outputted by R in a Babel block contains quotes only the
quoted parted is exported.
Consider this:
#+BEGIN_SRC R
q = 'cat="S"'
q
#+END_SRC
#+RESULTS:
: S
The expected result would be entire string, i.e. 'cat="S"' (without
single quotes). Is there a workaround? I've tried escaping with
backslashes to no avail.
Cheers,
Viktor
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Output of R babel blocks with quotes is mangled/truncated
2012-07-08 3:22 Output of R babel blocks with quotes is mangled/truncated Viktor Rosenfeld
@ 2012-07-08 15:28 ` cberry
2012-07-08 20:47 ` Viktor Rosenfeld
0 siblings, 1 reply; 3+ messages in thread
From: cberry @ 2012-07-08 15:28 UTC (permalink / raw)
To: emacs-orgmode
Viktor Rosenfeld <listuser36@googlemail.com> writes:
> Hi,
>
> if a value outputted by R in a Babel block contains quotes only the
> quoted parted is exported.
>
Try
#+begin_src R :results verbatim
q = 'cat="S"'
q
#+end_src
> Consider this:
>
> #+BEGIN_SRC R
> q = 'cat="S"'
> q
> #+END_SRC
>
> #+RESULTS:
> : S
>
> The expected result would be entire string, i.e. 'cat="S"' (without
> single quotes). Is there a workaround? I've tried escaping with
> backslashes to no avail.
>
> Cheers,
> Viktor
>
>
--
Charles C. Berry Dept of Family/Preventive Medicine
cberry at ucsd edu UC San Diego
http://famprevmed.ucsd.edu/faculty/cberry/ La Jolla, San Diego 92093-0901
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Output of R babel blocks with quotes is mangled/truncated
2012-07-08 15:28 ` cberry
@ 2012-07-08 20:47 ` Viktor Rosenfeld
0 siblings, 0 replies; 3+ messages in thread
From: Viktor Rosenfeld @ 2012-07-08 20:47 UTC (permalink / raw)
To: emacs-orgmode
Hi Charles,
cberry@tajo.ucsd.edu wrote:
> Viktor Rosenfeld <listuser36@googlemail.com> writes:
>
> > Hi,
> >
> > if a value outputted by R in a Babel block contains quotes only the
> > quoted parted is exported.
> >
>
> Try
>
> #+begin_src R :results verbatim
> q = 'cat="S"'
> q
>
> #+end_src
This is not a solution since I want to output vectors or data frames
from R as a table.
E.g. the following should return a table, but verbatim returns a quoted
block which I cannot use further in my processing:
#+NAME: quote-mangling
#+BEGIN_SRC R
q = c('cat="S"', 'pos="VVFIN"')
q
#+END_SRC
I also tried an extra newline at the end, but it makes no difference.
Cheers,
Viktor
>
> > Consider this:
> >
> > #+BEGIN_SRC R
> > q = 'cat="S"'
> > q
> > #+END_SRC
> >
> > #+RESULTS:
> > : S
> >
> > The expected result would be entire string, i.e. 'cat="S"' (without
> > single quotes). Is there a workaround? I've tried escaping with
> > backslashes to no avail.
> >
> > Cheers,
> > Viktor
> >
> >
>
> --
> Charles C. Berry Dept of Family/Preventive Medicine
> cberry at ucsd edu UC San Diego
> http://famprevmed.ucsd.edu/faculty/cberry/ La Jolla, San Diego 92093-0901
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-07-08 20:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-08 3:22 Output of R babel blocks with quotes is mangled/truncated Viktor Rosenfeld
2012-07-08 15:28 ` cberry
2012-07-08 20:47 ` Viktor Rosenfeld
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).