How to set a line style as default for multiple plots in Gnuplot

gnuplot

I would like to create plot using gnuplot. The line width should be 3 in all plots. If I do it for one plot only this is done by:

set style line 1 linewidth 3

Is there any way how to do it globally as default?

Best Answer

You can specify

set terminal <terminal> linewidth 3

This will change the default linewidth for all lines in the plot, including the plot borders.

If that's not what you want, you can specify all the lines in a loop (gnuplot 4.6+), where n is the number of lines you are plotting:

do for [i=1:n] {
    set style line i linewidth 3
}