Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #15233
| From | Sseziwa Mukasa <mukasa@gmail.com> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Writing numeric data to CSV does not write final EOL |
| Date | 2013-07-23 08:42 +0000 |
| Message-ID | <kslfm0$pnu$1@smc.vnet.net> (permalink) |
| References | <20130721082237.45F9E6A09@smc.vnet.net> |
| Organization | Time-Warner Telecom |
You can append an empty row:
Export["C:/tmpfile.csv", Append[mytable,{}], "csv"];
On Jul 21, 2013, at 4:22 AM, kogan.clark@gmail.com wrote:
> Hi!
>
> I am using Mathematica 8 to write a numeric matrix to a csv file using the commands:
>
> mytable = {{1, 2}, {3, 4}};
> mytable = Export["C:/tmpfile.csv", mytable, "csv"];
>
>
> This produces a file, but does not put a final line end character after the 4. I am trying to read this file with R, which requires the final line end character. I was wondering if anyone knew the simplest (or a very simple) way to add the additional line end character.
>
> Thanks!
>
> Clark
>
Back to comp.soft-sys.math.mathematica | Previous | Next — Next in thread | Find similar | Unroll thread
Re: Writing numeric data to CSV does not write final EOL Sseziwa Mukasa <mukasa@gmail.com> - 2013-07-23 08:42 +0000
Re: Writing numeric data to CSV does not write final EOL Alan <alan.isaac@gmail.com> - 2013-09-17 09:31 +0000
Re: Writing numeric data to CSV does not write final EOL Sseziwa Mukasa <mukasa@gmail.com> - 2013-09-19 05:19 +0000
Re: Writing numeric data to CSV does not write final EOL David Bailey <dave@removedbailey.co.uk> - 2013-09-24 07:58 +0000
csiph-web