thelfer / tfel-plot

This project defines a C++11 library for generating plots based on TFEL and Qt and an executable called `tplot` which can be used as a drop-in replacement of `gnuplot` but also have a lot of other functionalities.
GNU General Public License v3.0
1 stars 0 forks source link

How to specify separator character ure in file #4

Closed pgoldbronn closed 6 years ago

pgoldbronn commented 6 years ago

tplot take care of space as column separator.

If we have other separator as ',' or ';' (or tab ?) we could not plot values. It wiould be nice if we could specify a value for separator like option --separator ';' (ou -s ';')

For example csv file

TIME;RADIUS 1;RADIUS 2
1; 2.5 ; 2.5
2;2.6; 3.5
3;3.5 ;4.5
4   ;    5.5;6.0
5;5.1;8.0

tplot example.txt -s ';' -u 1:2 example.txt -s ';' -u 1:3

thelfer commented 6 years ago

You can now use the following syntax:

tplot cvs:test.csv -u ...

Here cvs refers to a file format where the data are separated by a comma or a semi-colon (In the current implementation, you can mix both).

pgoldbronn commented 6 years ago

File type is csv, isn't it ? That doesn't work

thelfer commented 6 years ago

Can you update and try again ?

pgoldbronn commented 6 years ago

Great ! it works fine.