Question

I have a gnuplot (v4.2, on Mac OS 10.8) plotting question.

I have multi-column data, and I am trying to plot x vs y with z as a palette colour bar. When I plot it with a linear scale, it works fine, however, I want to have a log scale on the colour bar. When I do so, it plots the colour bar correctly, but the colour scale does not match the values it is plotting. The column 5 data ranges between 2 and 154, but all the points are coloured to values >100. Could anyone tell me what is wrong with the following?:

set term postscript enhanced
set output 'Adam_SN_test.ps'
set xlabel 'Test xt'
set xlabel font 'Helvetica, 24'
set ylabel 'Test y'
set ylabel font 'Helvetica, 24'
set xtics font 'Helvetica, 24'
set ytics font 'Helvetica, 24'
set pointsize 'multiplier'
set nokey 
set xrange [0:0.125]
set yrange [6:12]
set label font 'Helvetica'
set palette model RGB defined (0 "red",1 "blue", 2 "green")
set zrange [0.1:500]
set logscale z
set logscale cb
set cbrange[0.1:500]
plot "Adam_SN_temp.txt" using 2:3:5 with points pt 7 ps 1.0 lc palette

The file Adam_SN_temp.txt looks like this:

16294 0.02897 8.86248302517 59.1152701416 40.2917560538
203037 0.01479 8.53737795685 7.21619618663 12.0774348459
203114 0.06977 10.8643336344 21.5525447141 5.48389478337
203140 0.08696 10.9104677808 3.77345694074 2.3293583516
203148 0.04289 9.24387841659 104.765266398 44.073805516
209181 0.0581 10.2398050665 172.322620353 154.484926029

The colour bar is showing the correct log scale between the correct limits, and at colours above 100 are all green and all the points are green, indicating values above 100. However, clearly from the data the 5th column values are not all above 100:

enter image description here

(EDIT: The image shows the problematic output with 4.2.6)

When I remove the log statements it plots is perfectly on a linear scale with the right values.

Was it helpful?

Solution

it looks nice to me, the green point in the middle is the 6th point (154.484926029) gnuplot

this is what I get (with Version 4.6 patchlevel 5) Maybe you should ugrade your version? For this my advice would be to use macports

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top