Hello Daniweb,

As my title, I have a problem in my gnuplot.

I can set the minimum range based on my file.. but doing the maximum range it give a wrong output for min and max yrange.

I been searching for net and tried there solutions but it won't work for me.

This is my script line for me yrange:

set yrange [*:35] noreverse nowriteback
#set yrange [*:*] noreverse nowriteback

The first line is working, but to get the best graphical image is getting the min max of the data.

The second line is not working, as I see that is the closest answer on my problem.

Please help me to get the min max for my yrange.

This is my script:

#!/usr/bin/gnuplot
reset
set terminal pngcairo
set datafile separator ','
set style fill solid 0.3
set grid
set title 'Test Guide'
set offset graph 0.05, graph 0.05, graph 0.05, graph 0.05
set yrange [*:35] noreverse nowriteback
#set yrange [*:*] noreverse nowriteback
set ylabel 'Temperature'
set xlabel 'Day 0 to Day 5'
set output 'test.png'
plot 'new_test.dat' using 2:xticlabels(1) with line t 'Testing'

Thank you and God Bless

Recommended Answers

All 2 Replies

I think that the failing yrange set [:] is failing because you are trying to set the yrange to infinity which gnuplot cannot handle. I'm not a gnuplot expert, so this is just a SWAG.

Hello Sir Rubberman,

I just delete some of the data to my extracted file. Adjusting to my file is the only way I can do. After I delete first and second column the [:] is now working. The problem I think is even the string/text is included to the graph I make. But thank you for the time and reply sir.

PS: Sorry for late feedback

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.