narunlifescience / AlphaPlot

:chart_with_upwards_trend: Application for statistical analysis and data visualization which can generate different types of publication quality 2D and 3D plots with extensive visual customization.
http://alphaplot.sourceforge.net/
GNU General Public License v2.0
243 stars 37 forks source link

CSV Import: cannot open files with commas as decimal point #28

Closed Scindix closed 2 years ago

Scindix commented 3 years ago

Edit: I'm using Version 1.011A-alpha

Thanks for making a modern version of qtiPlot. There's just one issue I'd like to point out: I'm unable to import files that use commas as decimal seperator which is a format used in some European languages. This is the csv file:

$ cat test.csv
Zeit t / s;Spannung U_B1 / V;Spannung U_A1 / V
0;0,665;-0,375
0,1;0,77;-0,29
0,2;0,855;-0,225
0,3;0,905;-0,2
0,401;0,91;-0,205
0,501;0,89;-0,245
0,6;0,83;-0,32
0,7;0,74;-0,41
0,801;0,63;-0,515
0,9;0,505;-0,625
1;0,385;-0,73

This is how I'm importing it: Screenshot from 2021-04-30 22-33-21 ↑ Please note that I'm using the correct Decimal Seperators. However the imported table consists mostly of zeros. Screenshot from 2021-04-30 22-37-32 If I perform the exact same import in SciDAVis it is imported correctly: Screenshot from 2021-04-30 22-41-09

filipestevao commented 3 years ago

Hi @Scindix,

Thanks for your collaboration. I can confirm this bug.

There is a way to get around this situation without having to modify the raw data.

First, the Decimal Separators is set to 1 000,0 or 1.000,0 (Edit → Preferences → General → Numeric Format).

After, I don't check the Numeric data in import window:

alphaplot1

The data is imported as Text:

alphaplot2

Then, I select all the columns and in Type I set Numeric and Apply.

alphaplot3

Of course, this does not remove the fact that this issue needs to be fixed. But it is an optional solution until it is done.

narunlifescience commented 3 years ago

Thank you for reporting. I will have a look at it later.

narunlifescience commented 2 years ago

fixed in new release v1.02