Re: "automatically" create table based on external (ascii) data

2009-04-07 Thread Nikos Alexandris
On Tue, 2009-04-07 at 16:17 +, Anders Host-Madsen wrote:
> Guenter Milde  writes:
> > Pasting into a table works with table-data if it is TAB separated. The
> > space is too often needed inside a table cell in the general case.
> 
> Thanks for the tip. I didn't realize this was possible.
> I tried exporting to csv and importing to LyX (see
> my previous posting), but it didn't work. This does work, but
> it should be added that it is necessary to paste
> as "plain text," otherwise the tabs are ignored.

Thank you Guenter.
Nikos



Re: "automatically" create table based on external (ascii) data

2009-04-07 Thread Anders Host-Madsen
Guenter Milde  writes:
> Pasting into a table works with table-data if it is TAB separated. The
> space is too often needed inside a table cell in the general case.

Thanks for the tip. I didn't realize this was possible.
I tried exporting to csv and importing to LyX (see
my previous posting), but it didn't work. This does work, but
it should be added that it is necessary to paste
as "plain text," otherwise the tabs are ignored.



Re: "automatically" create table based on external (ascii) data

2009-04-06 Thread Guenter Milde
On 2009-04-06, Nikos Alexandris wrote:
> On Mon, 2009-04-06 at 18:50 +0200, Siegfried Meunier-Guttin-Cluzel
> wrote:
>> Did you try the csv format (coma separated values ) ?
>> Siegfried.

> You mean... ? Insert directly a csv file? No, I did not. I just try to
> copy-paste from R. The " " (=space) also can (or should be able to) act
> as a "field separator" (or not?).

Pasting into a table works with table-data if it is TAB separated. The
space is too often needed inside a table cell in the general case.

> But I don't see why the copy-paste does not work? I would expect this to
> be a feature in LyX. Perhaps under development??

You might ask for an extension of the customizable csv2lyx "insert CSV
data" feature to work also as "Paste>Special>CSV" so you do not need to
create and import a temporary CSV file.

A quick workaround would be convert the spaces to tabs in your R output,
to generate an empty table with 

   M-x tabular-insert 7 9

(adjust column and row numbers) and paste the data there

Günter



Re: "automatically" create table based on external (ascii) data

2009-04-06 Thread Nikos Alexandris
On Mon, 2009-04-06 at 18:50 +0200, Siegfried Meunier-Guttin-Cluzel
wrote:
> Did you try the csv format (coma separated values ) ?
> Siegfried.

You mean... ? Insert directly a csv file? No, I did not. I just try to
copy-paste from R. The " " (=space) also can (or should be able to) act
as a "field separator" (or not?).

But I don't see why the copy-paste does not work? I would expect this to
be a feature in LyX. Perhaps under development??

Thanks, Nikos



Re: "automatically" create table based on external (ascii) data

2009-04-06 Thread Siegfried Meunier-Guttin-Cluzel

Did you try the csv format (coma separated values ) ?

Siegfried.


"automatically" create table based on external (ascii) data

2009-04-06 Thread Nikos Alexandris
Hi table-experts :-)

Is it possible to copy a matrix derived from R and paste directly in a
LyX table without waisting time to (re-)construct the table?

For example, I have the following 3 by 3 data

b02 0.3364205 0.5465307

b06 0.4624192 -0.1143715

b07 0.4435665 -0.2369216

Is it possible to create automatically a LyX 3 by 3 table without having
to put manually the values in the problem? Of course this example is not
the real problem. It becomes really time-waisting/tedious when the
table(s) to construct is(are) _large_, say 7 x 7 (and many).

I know there is the xtable() function in R but I want to avoid messing
with ERT's.

Kind regards, Nikos