I want to add the last value of a series to the plots legend. I tried different variants of this SO answer like so:
plot filename using 1:2:(last=$2) title sprintf("1/N %0.2f", last) with lines
But this puts nan
into the label. And if I do 1:(last=$2)
this messes up the whole line.
The problem is I need to make it platform independent meaning it needs to run on windows and linux. So I can not just tail and awk. Is there a build in way to achieve this?