I'm using Gnuplot to draw a graph. In the graph I drew three smooth curve belonging to three data sets.
Presently I'm using the following Gnuplot script.
reset
set terminal png
set xlabel "Square matrix size"
set ylabel "Time (in milliseconds)"
set yrange [0:750]
set title "Lower Triangular Matrix"
set key reverse Left outside
set grid
set output 'matrixlt.png'
set style data linespoints
plot "matrixlowertriangle.dat" using 1:2 lt 1 lw 2 smooth bezier title 'MatPro', \
"matrixlowertriangle.dat" using 1:3 lt 2 lw 2 smooth bezier title 'C#' , \
"matrixlowertriangle.dat" using 1:4 lt 3 lw 2 smooth bezier title 'C++'
With the above script I'm getting following graph.
Now I want to draw each point belonging to the same curve using a unique point style. ( For example each point belonging to C# using one point type and C++ data points in a different style.)
I tried some tutorials, but still no luck. Can somebody help me to achieve this task?
I don't have your data so I made some up (it always helps to be helpful if some useful mock dataset is given...):
0 0 0 0
200 1000 1200 1500
400 4000 7000 9000
600 7000 15000 18000
800 12000 23000 25000
1000 18000 33000 40000
Based upon your code, I tried
reset
set terminal png
set xlabel "Square matrix size"
set ylabel "Time (in milliseconds)"
set xrange [0:1200]
set yrange [0:50000]
set title "Lower Triangular Matrix"
set key reverse Left outside
set grid
set output 'matrixlt.png'
set style data linespoints
plot "matrixlowertriangle.dat" using 1:2 lt 1 lw 2 smooth bezier title 'MatPro', \
"matrixlowertriangle.dat" using 1:3 lt 2 lw 2 smooth bezier title 'C#' , \
"matrixlowertriangle.dat" using 1:4 lt 3 lw 2 smooth bezier title 'C++' , \
"matrixlowertriangle.dat" using 1:2 with points title "", \
"matrixlowertriangle.dat" using 1:3 with points title "", \
"matrixlowertriangle.dat" using 1:4 with points title ""
and got
Is that closer to what you want?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With