emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] [BUG] [babel] [R] :colnames yes conflicts with :results file


From: Rainer M Krug
Subject: Re: [O] [BUG] [babel] [R] :colnames yes conflicts with :results file
Date: Wed, 07 Jan 2015 14:45:52 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (darwin)

Sebastien Vauban <sva-news-D0wtAvR13HarG/address@hidden>
writes:

> Thomas S. Dye wrote:
>> Rainer M Krug <Rainer-vfylz/address@hidden> writes:
>>> But the :colnames only works on tables (i.e. :results table) - but
>>> the result is represented as a link to a file. So what should happen?
>>
>> I think this is mistaken.  "Tables" occur in at least three contexts
>> in babel source code blocks.  There are input tables, :var mytable,
>> there are "tables" within the code block, represented in R as
>> a dataframe or a matrix, and there are output tables, which are placed
>> in the Org mode buffer as a result.
>>
>> I use :colnames to keep the column names of input tables associated
>> with the "tables" within the code block, and typically have them
>> represented in the output, whether that is a "table" written to file,
>> or output to the Org mode buffer as an Org mode table, either by
>> default or (more rarely) through use of :results table.
>>
>> In my experience :results table is mostly useful for coercing a value
>> that babel would otherwise interpret as a scalar into a single element
>> table.
>
> Another problem, IIUC, is that :colnames serves to specify both input
> and output, right?

This would be the optimal solution - but instead of having a second
header argument, the values ~input~ and ~output~ and ~both~ could be added,
allowing to have headers only for input or output respectively, or for
both (equivalent to ~yes~ at the moment, but clearer).

>
> Or can you well declare that, for example, the input table has an
> header, but to strip it from the output??

I would prefer the option to be able to specify :colnames and :rownames
for input and output separately.


Cheers,

Rainer

>
> Best regards,
>   Seb

-- 
Rainer M. Krug
email: Rainer<at>krugs<dot>de
PGP: 0x0F52F982

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]