Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to plot a graph with linux?

Tags:

linux

gnuplot

I want to plot a data file (speed11.data) in Linux. the data file looking like:

1,4.45823517e+01
2,4.45873528e+01
3,4.45923538e+01
4,4.45973549e+01

I used gnuplot, but I got error.

 gnuplot> plot "speed11.data"


gnuplot> 1,4.45823517e+01
         ^
         "speed11.data", line 1: invalid command

How to plot this graph?

The output of locale is:

LANG=en_CA.UTF-8
LC_CTYPE="en_CA.UTF-8"
LC_NUMERIC="en_CA.UTF-8"
LC_TIME="en_CA.UTF-8"
LC_COLLATE="en_CA.UTF-8"
LC_MONETARY="en_CA.UTF-8"
LC_MESSAGES="en_CA.UTF-8"
LC_PAPER="en_CA.UTF-8"
LC_NAME="en_CA.UTF-8"
LC_ADDRESS="en_CA.UTF-8"
LC_TELEPHONE="en_CA.UTF-8"
LC_MEASUREMENT="en_CA.UTF-8"
LC_IDENTIFICATION="en_CA.UTF-8"
LC_ALL=
like image 939
h747 Avatar asked May 21 '26 07:05

h747


1 Answers

For gnuplot, you might want to look at this post that deals with using comma separated values (CSV) in gnuplot.

Alternatively , you might want to try using R instead of gnuplot. R has the ability to import csv data files and is able to do some sophisticated graphing.

like image 73
RichardC Avatar answered May 24 '26 13:05

RichardC