Using MapReduce with german CSV format

1 次查看(过去 30 天)
I try to use the MapReduce function to handel CSV files. My cells are seperated with ";" and are written in german format. e.g. header and 3 meassurements "k;temperature 0;20,4 1;20,8 2;21,1" not the englisch format "k,temperature 0,20.4 1,20.8 2,21.1" I found the option to use a ";" insted a "," for cell seperating by using mapreduce. But how to change the "." into "," for the numbers? I use Matlab 2015b. Thanks, TF

采纳的回答

Kirby Fears
Kirby Fears 2015-12-11

更多回答(1 个)

Thomas
Thomas 2015-12-11
Thank you for the answer. Now I can read the numerical data as a string and convert it to a number. It works well for small amount of data. But I work with huge amount of Data (some GB „Big Data“). I compare it for a 25MB file. The computation time for a file with conversion (string too number) is 65 seconds and for a file without conversion (string to number) it is 1.5 seconds. Is there no other way to read my data directly as numbers? Thanks, TF
  2 个评论
Kirby Fears
Kirby Fears 2015-12-11
Are you first setting up your input with the datastore() command?
Unfortunately datastore properties do not allow you to set the decimal character.
Thomas
Thomas 2015-12-11
Yes. I use datastore to read my data. Thanks for help.
So it has to be a task for Mathworks to add these option.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 MapReduce 的更多信息

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by