diff --git a/demo/boxplot.dem b/demo/boxplot.dem index dd6b45415..0b267c26a 100644 --- a/demo/boxplot.dem +++ b/demo/boxplot.dem @@ -28,6 +28,7 @@ set xtics auto set yrange [*:*] set title "Distribution of energy usage of the continents, grouped by type of energy source\n" set ylabel "Billion Tons of Oil Equivalent" +set datafile columnheaders plot 'energy_circles.dat' using (1):($8/1.e6):(0):4 @@ -82,4 +83,5 @@ plot for [i=1:NF-2] 'energy_circles.dat' using (i):(filter(8, 4, i)), \ pause -1 'Hit to continue: boxplot demo finished' +unset datafile reset diff --git a/demo/energy_circles.dat b/demo/energy_circles.dat index 5b85531eb..61678f1b8 100644 --- a/demo/energy_circles.dat +++ b/demo/energy_circles.dat @@ -1,4 +1,4 @@ -#Latitude Longitude Continent Source Color_index Angle_start_at Angle Value Continent_total +Latitude Longitude Continent Source Color_index Angle_start_at Angle Value Continent_total 55.0 85.0 "ASIA (EXCL. MIDDLE EAST)" Coal 0 215.410 144.590 947639 2362223 55.0 85.0 "ASIA (EXCL. MIDDLE EAST)" Oil 1 154.375 61.034 400017 2362223 55.0 85.0 "ASIA (EXCL. MIDDLE EAST)" Gas 2 112.828 41.544 272284 2362223 diff --git a/demo/histerror.dem b/demo/histerror.dem index 17bbb5228..83ef9527f 100644 --- a/demo/histerror.dem +++ b/demo/histerror.dem @@ -19,3 +19,5 @@ plot 'histerror.dat' using 2:3 fs solid 0.5 lw 2 ti 'A', \ pause -1 " to continue" +unset datafile +reset diff --git a/demo/html/Makefile b/demo/html/Makefile index 430fe6432..fe583cb72 100644 --- a/demo/html/Makefile +++ b/demo/html/Makefile @@ -12,7 +12,7 @@ GNUPLOT_LIB = .. # Several of the demos need manual intervention: # fontfile vector epslatex # -html: airfoil.html animation.html approximate.html armillary.html array.html arrowstyle.html barchart_art.html binary.html bins.html bivariat.html boxplot.html boxclusters.html candlesticks.html circles.html cities.html columnhead.html contours.html convex_hull.html custom_contours.html controls.html custom_key.html dashtypes.html datastrings.html dgrid3d.html discrete.html electron.html ellipse.html enhanced_utf8.html epslatex.html errorbars.html fenceplot.html fillbetween.html fillcrvs.html fillstyle.html finance.html fit.html function_block.html hidden.html hidden2.html hidden_compare.html histograms.html histograms2.html histerror.html histogram_colors.html gantt.html image.html image2.html imageNaN.html index.html iterate.html jitter.html keyentry.html label_stacked_histograms.html layout.html lines_arrows.html linkedaxes.html map_projection.html margins.html mask_pm3d.html monotonic_spline.html multiaxis.html multiplt.html named_palettes.html nokey.html nonlinear1.html nonlinear2.html nonlinear3.html parallel.html param.html piecewise.html pixmap.html pm3dcolors.html pm3d.html pm3dgamma.html pm3d_clip.html pm3d_lighting.html pointsize.html polar.html poldat.html polar_quadrants.html polygons.html prob2.html prob.html projection.html rainbow.html random.html rectangle.html rgba_lines.html rgbalpha.html rgb_variable.html rotate_labels.html rugplot.html running_avg.html sampling.html scatter.html simple.html singulr.html smooth.html smooth_path.html solar_path.html spiderplot.html spline.html smooth_splines.html steps.html stringvar.html surface1.html surface2.html azimuth.html transparent.html transparent_solids.html textbox.html tics.html timedat.html ttics.html using.html varcolor.html vector.html violinplot.html walls.html world.html world2.html heatmaps.html heatmap_points.html stats.html unicode.html zerror.html boxes3d.html voxel.html vplot.html isosurface.html +html: airfoil.html animation.html approximate.html armillary.html array.html arrowstyle.html barchart_art.html binary.html bins.html bivariat.html boxplot.html boxclusters.html candlesticks.html circles.html cities.html columnhead.html contours.html convex_hull.html custom_contours.html controls.html custom_key.html dashtypes.html datastrings.html dgrid3d.html discrete.html electron.html ellipse.html enhanced_utf8.html epslatex.html errorbars.html fenceplot.html fillbetween.html fillcrvs.html fillstyle.html finance.html fit.html function_block.html hidden.html hidden2.html hidden_compare.html histograms.html histograms2.html histerror.html histogram_colors.html gantt.html image.html image2.html imageNaN.html index.html iterate.html jitter.html keyentry.html label_stacked_histograms.html layout.html lines_arrows.html linkedaxes.html map_projection.html margins.html mask_pm3d.html monotonic_spline.html multiaxis.html multiplt.html named_palettes.html nokey.html nonlinear1.html nonlinear2.html nonlinear3.html parallel.html param.html piecewise.html pixmap.html pm3dcolors.html pm3d.html pm3dgamma.html pm3d_clip.html pm3d_lighting.html pointsize.html polar.html poldat.html polar_quadrants.html polygons.html prob2.html prob.html projection.html rainbow.html random.html rectangle.html rgba_lines.html rgbalpha.html rgb_variable.html rotate_labels.html rugplot.html running_avg.html sampling.html scatter.html simple.html singulr.html smooth.html smooth_path.html solar_path.html spiderplot.html spline.html smooth_splines.html steps.html stringvar.html surface1.html surface2.html azimuth.html transparent.html transparent_solids.html textbox.html tics.html timedat.html ttics.html using.html varcolor.html vector.html violinplot.html walls.html world.html heatmaps.html heatmap_points.html stats.html unicode.html zerror.html boxes3d.html voxel.html vplot.html isosurface.html index.html: index.save cp index.save index.html @@ -20,6 +20,7 @@ index.html: index.save animation.html: animation.html.save cp animation.html.save animation.html + ../../src/gnuplot animation.gp special_functions: index.html showcase_plots complex_trig.html cerf.html elliptic.html expint.html ibeta.html igamma.html BesselK.html complex_airy.html Dawson.html Fresnel.html lambert.html lnGamma.html synchrotron.html uigamma.html zeta.html cp index.special_functions index.html diff --git a/demo/html/Makefile.canvas b/demo/html/Makefile.canvas index b3fa19526..f6c21a830 100644 --- a/demo/html/Makefile.canvas +++ b/demo/html/Makefile.canvas @@ -9,7 +9,7 @@ GNUPLOT_LIB = .. # # Auto-generation of html demo set. # -html_3d: binary.html bivariat.html contours.html custom_contours.html datastrings.html discrete.html errorbars.html fenceplot.html hidden.html hidden2.html hidden_compare.html margins.html pixmap.html pm3dcolors.html pm3d.html pm3d_clip.html pm3d_lighting.html pointsize.html polygons.html random.html rgb_variable.html sampling.html scatter.html singulr.html surface1.html surface2.html azimuth.html projection.html transparent_solids.html vector.html walls.html world.html world2.html zerror.html boxes3d.html vplot.html voxel.html isosurface.html +html_3d: binary.html bivariat.html contours.html custom_contours.html datastrings.html discrete.html errorbars.html fenceplot.html hidden.html hidden2.html hidden_compare.html margins.html pixmap.html pm3dcolors.html pm3d.html pm3d_clip.html pm3d_lighting.html pointsize.html polygons.html random.html rgb_variable.html sampling.html scatter.html singulr.html surface1.html surface2.html azimuth.html projection.html transparent_solids.html vector.html walls.html world.html zerror.html boxes3d.html vplot.html voxel.html isosurface.html html_2d: airfoil.html approximate.html array.html barchart_art.html bins.html boxplot.html boxclusters.html candlesticks.html canvas_utf8.html circles.html cities.html columnhead.html controls.html convex_hull.html custom_key.html dashtypes.html electron.html enhanced_utf8.html fillbetween.html fillcrvs.html fillstyle.html finance.html histograms.html histograms2.html histerror.html histogram_colors.html hypertext.html hypertext_surface.html gantt.html imageNaN.html index.html iterate.html jitter.html keyentry.html label_stacked_histograms.html layout.html lines_arrows.html linkedaxes.html map_projection.html mask_pm3d.html monotonic_spline.html multiaxis.html multiplt.html nonlinear1.html nonlinear2.html nonlinear3.html named_palettes.html nokey.html param.html piecewise.html polar.html poldat.html polar_quadrants.html prob2.html prob.html rainbow.html ellipse.html rectangle.html rgba_lines.html rgbalpha.html rotate_labels.html rugplot.html running_avg.html simple.html smooth.html smooth_path.html solar_path.html smooth_splines.html spiderplot.html spline.html steps.html transparent.html timedat.html ttics.html using.html varcolor.html world.html heatmaps.html heatmap_points.html stats.html violinplot.html diff --git a/demo/html/Makefile.svg b/demo/html/Makefile.svg index 9672b6547..4c61a822f 100644 --- a/demo/html/Makefile.svg +++ b/demo/html/Makefile.svg @@ -9,7 +9,7 @@ GNUPLOT_LIB = .. # # Auto-generation of the svg demo set. # -html: airfoil.html approximate.html armillary.html array.html barchart_art.html binary.html bins.html bivariat.html boxplot.html boxclusters.html candlesticks.html cerf.html circles.html cities.html columnhead.html contours.html custom_contours.html controls.html convex_hull.html custom_key.html dashtypes.html datastrings.html discrete.html electron.html enhanced_utf8.html errorbars.html fenceplot.html fillbetween.html fillcrvs.html fillstyle.html finance.html hidden.html hidden2.html hidden_compare.html histograms.html histograms2.html histerror.html histogram_colors.html hypertext.html hypertext_surface.html gantt.html imageNaN.html index.html iterate.html jitter.html keyentry.html label_stacked_histograms.html layout.html lines_arrows.html linkedaxes.html map_projection.html margins.html mask_pm3d.html monotonic_spline.html multiaxis.html multiplt.html nonlinear1.html nonlinear2.html nonlinear3.html named_palettes.html nokey.html parallel.html param.html piecewise.html pixmap.html pm3dcolors.html pm3d.html pm3d_clip.html pm3d_lighting.html pointsize.html polar.html poldat.html polar_quadrants.html polygons.html prob2.html prob.html rainbow.html random.html rectangle.html rgba_lines.html rgbalpha.html rgb_variable.html rotate_labels.html rugplot.html running_avg.html sampling.html scatter.html simple.html singulr.html smooth.html smooth_path.html smooth_splines.html spiderplot.html spline.html solar_path.html steps.html stringvar.html surface1.html surface2.html azimuth.html projection.html textbox.html transparent.html transparent_solids.html tics.html timedat.html ttics.html using.html varcolor.html vector.html violinplot.html walls.html world.html world2.html heatmaps.html heatmap_points.html ellipse.html stats.html unicode.html zerror.html boxes3d.html +html: airfoil.html approximate.html armillary.html array.html barchart_art.html binary.html bins.html bivariat.html boxplot.html boxclusters.html candlesticks.html cerf.html circles.html cities.html columnhead.html contours.html custom_contours.html controls.html convex_hull.html custom_key.html dashtypes.html datastrings.html discrete.html electron.html enhanced_utf8.html errorbars.html fenceplot.html fillbetween.html fillcrvs.html fillstyle.html finance.html hidden.html hidden2.html hidden_compare.html histograms.html histograms2.html histerror.html histogram_colors.html hypertext.html hypertext_surface.html gantt.html imageNaN.html index.html iterate.html jitter.html keyentry.html label_stacked_histograms.html layout.html lines_arrows.html linkedaxes.html map_projection.html margins.html mask_pm3d.html monotonic_spline.html multiaxis.html multiplt.html nonlinear1.html nonlinear2.html nonlinear3.html named_palettes.html nokey.html parallel.html param.html piecewise.html pixmap.html pm3dcolors.html pm3d.html pm3d_clip.html pm3d_lighting.html pointsize.html polar.html poldat.html polar_quadrants.html polygons.html prob2.html prob.html rainbow.html random.html rectangle.html rgba_lines.html rgbalpha.html rgb_variable.html rotate_labels.html rugplot.html running_avg.html sampling.html scatter.html simple.html singulr.html smooth.html smooth_path.html smooth_splines.html spiderplot.html spline.html solar_path.html steps.html stringvar.html surface1.html surface2.html azimuth.html projection.html textbox.html transparent.html transparent_solids.html tics.html timedat.html ttics.html using.html varcolor.html vector.html violinplot.html walls.html world.html heatmaps.html heatmap_points.html ellipse.html stats.html unicode.html zerror.html boxes3d.html index.html: index.svg cp index.svg index.html diff --git a/demo/html/animation.html.save b/demo/html/animation.html.save index 48991832c..329a63337 100644 --- a/demo/html/animation.html.save +++ b/demo/html/animation.html.save @@ -7,8 +7,8 @@ Back to demo index

gnuplot demo script: animation.dem

-generated by animation.gp on Mon Dec 7 11:31:05 2020 -
gnuplot version gnuplot 5.5 +generated by animation.gp on Tue Feb 7 11:31:05 2023 +
gnuplot version gnuplot 6.1
diff --git a/demo/html/index.canvas b/demo/html/index.canvas index dd72c58be..716f88e3f 100644 --- a/demo/html/index.canvas +++ b/demo/html/index.canvas @@ -2,17 +2,17 @@ -Gnuplot 5.5 demos (HTML canvas terminal) +Gnuplot 6.1 demos (HTML canvas terminal) -

Gnuplot 5.5 demos (HTML canvas terminal)
+

Gnuplot 6.1 demos (HTML canvas terminal)
See also the demo output for the - PNG and - SVG terminals. + PNG and + SVG terminals.

Your browser may not support the HTML 5 canvas element

@@ -91,7 +91,6 @@
  • pm3d coloring
  • pm3d hidden surfaces
  • pm3d clipping
  • -
  • 3D mapping
  • 2D projection of 3D surface
  • shaded error region
  • azimuth
  • @@ -125,7 +124,7 @@
  • polar quadrants
  • cylindrical/spherical
  • time/date coords
  • -
  • coord sampling ranges
  • +
  • coordinate sampling ranges
  • Binary and Image data

    @@ -255,7 +254,7 @@
    diff --git a/demo/html/index.special_functions b/demo/html/index.special_functions index 51f5af97b..2e189b3e2 100644 --- a/demo/html/index.special_functions +++ b/demo/html/index.special_functions @@ -1,12 +1,12 @@ -Demos for gnuplot version 5.5 +Demos for gnuplot version 6.1 -

    Demos for gnuplot version 5.5 (pngcairo terminal)
    +

    Demos for gnuplot version 6.1 (pngcairo terminal)
    See also the demo output for the - SVG and - canvas terminals. + SVG and + canvas terminals.

    - This page generated October 2022 + This page generated February 2023 diff --git a/demo/html/index.save b/demo/html/index.save index ad709eb43..72beba293 100644 --- a/demo/html/index.save +++ b/demo/html/index.save @@ -1,12 +1,12 @@ -Demos for gnuplot version 5.5 +Demos for gnuplot version 6.1 -

    Demos for gnuplot version 5.5 (pngcairo terminal)
    +

    Demos for gnuplot version 6.1 (pngcairo terminal)
    See also the demo output for the - SVG and - canvas terminals. + SVG and + canvas terminals.

    @@ -92,7 +92,6 @@ Here are samples of PNG output from some of the demos.

  • pm3d coloring
  • pm3d hidden surfaces
  • pm3d clipping
  • -
  • 3D mapping
  • 2D projection of 3D surface
  • shaded error region
  • azimuth
  • @@ -128,7 +127,7 @@ Here are samples of PNG output from some of the demos.
  • polar quadrants
  • cylindrical/spherical
  • time/date coords
  • -
  • coord sampling ranges
  • +
  • coordinate sampling ranges
  • Binary and Image data

    @@ -229,7 +228,7 @@ Here are samples of PNG output from some of the demos.
    - This page generated October 2022 + This page generated February 2023 @@ -237,9 +236,9 @@ Here are samples of PNG output from some of the demos.
  • Gnuplot development pages on SourceForge
  • On-line PDF documentation in - English + English and - Japanese + Japanese
  • @@ -84,7 +84,6 @@
  • pm3d coloring
  • pm3d hidden surfaces
  • pm3d clipping
  • -
  • 3D mapping
  • 2D projection of 3D surface
  • shaded error region
  • azimuth
  • @@ -125,7 +124,7 @@
  • polar quadrants
  • cylindrical/spherical
  • time/date coords
  • -
  • coord sampling ranges
  • +
  • coordinate sampling ranges
  • Binary and Image data

    @@ -270,7 +269,7 @@ diff --git a/demo/html/index.svg b/demo/html/index.svg index 2d40cfd87..584893877 100644 --- a/demo/html/index.svg +++ b/demo/html/index.svg @@ -1,6 +1,6 @@ -Demos for gnuplot Version 5.5 (SVG terminal) +Demos for gnuplot Version 6.1 (SVG terminal) @@ -8,10 +8,10 @@

    - Gnuplot Version 5.5 demos (SVG terminal)
    + Gnuplot Version 6.1 demos (SVG terminal)
    See also the demo output for the - PNG and - canvas terminals. + PNG and + canvas terminals.

    @@ -96,7 +96,6 @@ on mouse-coordinate tracking.

  • pm3d coloring
  • pm3d hidden surfaces
  • pm3d clipping
  • -
  • 3D mapping
  • 2D projection of 3D surface
  • shaded error region
  • azimuth
  • @@ -132,7 +131,7 @@ on mouse-coordinate tracking.
  • polar quadrants
  • cylindrical/spherical
  • time/date coords
  • -
  • coord sampling ranges
  • +
  • coordinate sampling ranges
  • Binary and Image data

    @@ -237,7 +236,7 @@ on mouse-coordinate tracking. diff --git a/demo/igamma.dem b/demo/igamma.dem index 0493d3514..c65bfb3f1 100644 --- a/demo/igamma.dem +++ b/demo/igamma.dem @@ -1,10 +1,10 @@ # -# Show limitation in old (prior to version 5.5) igamma domain and convergence +# Show limitation in old (prior to version 6) igamma domain and convergence # save_encoding = GPVAL_ENCODING set encoding utf8 -set title "igamma domain and convergence improved in version 5.5" +set title "igamma domain and convergence improved in version 6" set label 1 at graph 0.1, 0.8 set label 1 "igamma(a,z) = {Γ^{-1}(a) {/*2 ∫@_{/*0.5 0}^{/*.5 z}} {/:Italic t^{a-1}e^{-t}dt}" @@ -26,7 +26,7 @@ reset # # Previous igamma algorithm fails to converge for large a # -set title "igamma domain and convergence improved in version 5.5" +set title "igamma domain and convergence improved in version 6" set border -1 front linewidth 1.000 set view 46, 16, 1, 1 set samples 201, 201 diff --git a/demo/iterbugs.dem b/demo/iterbugs.dem new file mode 100644 index 000000000..ba6849040 --- /dev/null +++ b/demo/iterbugs.dem @@ -0,0 +1,24 @@ +# +# The combination of iteration and 3D plotting was problematic +# in earlier gnuplot versions. Be aware that this test plot +# would trigger an almost-infinite loop in versions prior to +# gnuplot 6. +# This demo serves as a unit test to check for regressions. +# +unset xtics +unset ytics +set border 16 +set view 60., 345., 1., 0.75 + +splot for [j=0:*] "whale.dat" index j using 1:($2-1):($3+1) \ + with lines lc "grey" notitle, \ + for [k=1:2] sin(x+k) with surface lc "dark-turquoise" notitle, \ + for [l=1:1] for [m=0:*] "whale.dat" index m using (2-$1):($2+1):($3+1) \ + with lines lc "steelblue" notitle, \ + keyentry with lines lc "grey" title "Grey Whale", \ + keyentry with boxes lc "dark-turquoise" title "waves", \ + keyentry with lines lc "steelblue" title "Blue Whale" + +pause -1 " to continue" + +reset diff --git a/demo/named_palettes.dem b/demo/named_palettes.dem index df5bcb8d0..4a123a5c0 100644 --- a/demo/named_palettes.dem +++ b/demo/named_palettes.dem @@ -49,7 +49,7 @@ pause -1 " to continue" # Method 2 (new in development version) # "set pm3d interpolate" works now # "set pm3d lighting" also works -set title "Version 5.5 offers a new keyword to access this palette" +set title "Version 6 offers a new keyword to access this palette" set palette defined (0 "dark-blue", 1 "white") set colormap new bluemap diff --git a/demo/pm3d_clip.dem b/demo/pm3d_clip.dem index e8b72a929..0a9f2358f 100644 --- a/demo/pm3d_clip.dem +++ b/demo/pm3d_clip.dem @@ -20,13 +20,13 @@ set ztics 5 f(x,y) = x**2 + y**2 * (1 - x)**3 -set multiplot layout 1,2 title "new pm3d default is smooth clipping against zrange" +set multiplot layout 1,2 title "Gnuplot 6 pm3d default is smooth clipping against zrange" set title "set pm3d clip4in (old default)" set pm3d clip4in splot f(x,y) with pm3d fc "cyan" -set title "set pm3d clip (new default)" +set title "set pm3d clip (Gnuplot 6)" set pm3d clip replot diff --git a/demo/pm3d_intersects.dem b/demo/pm3d_intersects.dem index 3ae791b03..11cc588ee 100644 --- a/demo/pm3d_intersects.dem +++ b/demo/pm3d_intersects.dem @@ -1,5 +1,5 @@ # -# New in version 5.5 - smooth intersection of pm3d surfaces +# New in version 6 - smooth intersection of pm3d surfaces # set title "Smooth intersection of pm3d surfaces" diff --git a/demo/pm3dcolors.dem b/demo/pm3dcolors.dem index 24e59c95b..069ae09b5 100644 --- a/demo/pm3dcolors.dem +++ b/demo/pm3dcolors.dem @@ -214,5 +214,6 @@ set title "set palette model RGB functions\n4*x*(1-theta(x-0.25)), 0.5*theta(x-0 splot f(x) pause -1 "Hit return to continue" +unset datafile reset diff --git a/demo/uigamma.dem b/demo/uigamma.dem index 4ae15ab2b..647b75da2 100644 --- a/demo/uigamma.dem +++ b/demo/uigamma.dem @@ -33,7 +33,7 @@ reset # Q(a,x) as uigamma # unset key -set title offset 0, -7 +set title offset 0, -7.5 set pointsize 0.5 set grid x @@ -41,7 +41,7 @@ set multiplot layout 2,1 upwards margins 0.25, 0.95, 0.1, 0.95 spacing 0, screen set xrange [83. : 89.] set yrange [1. - 2.e-15 : 1.0] set format y "%.16f" -set title "Lower incomplete gamma function: igamma(23, x)" +set title "Lower incomplete gamma function: igamma(23, x)\n(low precision in this range)" plot igamma(23., x) with points notitle set format y " %h" diff --git a/demo/watchmouse.dem b/demo/watchmouse.dem index d2df0bbb4..6f554c072 100644 --- a/demo/watchmouse.dem +++ b/demo/watchmouse.dem @@ -61,6 +61,7 @@ plot keyentry with yerrorbars pt 6 ps 0.4 title "min/avg/max temp", \ pause -1 ' to continue' +unset datafile reset diff --git a/docs/Makefile.am b/docs/Makefile.am index 61bce64b0..48efaa5d6 100644 --- a/docs/Makefile.am +++ b/docs/Makefile.am @@ -312,6 +312,7 @@ doc2web_CPPFLAGS = -DALL_TERM_DOC -I../src $(AM_CPPFLAGS) html: allterm.h doc2web$(EXEEXT) $(srcdir)/gnuplot.doc svg_figures webp_figures $(AM_V_at) [ -d html ] || mkdir -p html + $(AM_V_at) rm -f html/Overview.html html/Plotting_Styles.html html/Commands.html html/Terminals.html $(AM_V_GEN)./doc2web$(EXEEXT) $(srcdir)/gnuplot.doc html $(AM_V_GEN) sort -k 3 html/index.hhk > html/index.html diff --git a/docs/gnuplot.doc b/docs/gnuplot.doc index 1a3c62d9a..643c9e1d9 100644 --- a/docs/gnuplot.doc +++ b/docs/gnuplot.doc @@ -4,7 +4,7 @@ C ?gnuplot ^

    An Interactive Plotting Program

    ^

    Thomas Williams & Colin Kelley

    -^

    Version 5 organized by Ethan A Merritt and others

    +^

    Version 6 organized by Ethan A Merritt

    ^

    Major contributors (alphabetic order):
    ^
    ^ Hans-Bernhard Broeker, John Campbell,
    @@ -20,7 +20,7 @@ C ^ James R. Van Zandt, Alex Woo, Johannes Zellner
    ^

    ^

    Copyright (C) 1986 - 1993, 1998 - 2004 Thomas Williams, Colin Kelley
    -^ Copyright (C) 2004 - 2022 various authors

    +^ Copyright (C) 2004 - 2023 various authors

    ^

    Mailing list for comments: gnuplot-info@lists.sourceforge.net
    ^ Gnuplot home page
    ^ Issue trackers:   @@ -4464,7 +4464,7 @@ Ffigure_newsyntax ?watch Support for watchpoints is present only if your copy of gnuplot was built with configuration option --enable-watchpoints. This feature is EXPERIMENTAL - [details may change before it appears in a release version]. + [details may change in a subsequent release version]. Syntax: plot FOO watch {x|y|z|F(x,y)} = @@ -6579,7 +6579,9 @@ Ffigure_zerror dependent variable, and any number of parameters can be fitted. Optionally, error estimates can be input for weighting the data points. - The basic use of `fit` is best explained by a simple example: + The basic use of `fit` is best explained by a simple example where a set of + measured x and y values read from a file are used to be modeled by a + function y = f(x). f(x) = a + b*x + c*x**2 fit f(x) 'measured.dat' using 1:2 via a,b,c @@ -6781,9 +6783,9 @@ Ffigure_zerror squared differences or 'residuals' (SSR) between the input data points and the function values, evaluated at the same places. This quantity is often called 'chisquare' (i.e., the Greek letter chi, to the power of 2). The - algorithm attempts to minimize SSR, or more precisely, WSSR, as the residuals - are 'weighted' by the input data errors (or 1.0) before being squared; - see `fit error_estimates` for details. + algorithm attempts to minimize SSR, or more precisely the weighted sum of + squared residuals (WSSR), for which the residuals are weighted by the input + data errors before being squared; see `fit error_estimates` for details. That's why it is called 'least-squares fitting'. Let's look at an example to see what is meant by 'non-linear', but first we had better go over some @@ -6797,10 +6799,10 @@ Ffigure_zerror second {and higher} derivatives of the fitting function with respect to the parameters are zero for a linear least-squares problem). - For linear least-squares (LLS), the user-defined function will be a sum of - simple functions, not involving any parameters, each multiplied by one - parameter. NLLS handles more complicated functions in which parameters can - be used in a large number of ways. An example that illustrates the + For linear least-squares the user-defined function will be a sum of simple + functions, not involving any parameters, each multiplied by one parameter. + Nonlinear least-squares handles more complicated functions in which parameters + can be used in a large number of ways. An example that illustrates the difference between linear and nonlinear least-squares is the Fourier series. One member may be written as z=a*sin(c*x) + b*cos(c*x). @@ -6809,8 +6811,8 @@ Ffigure_zerror c is an unknown parameter, the problem is nonlinear. In the linear case, parameter values can be determined by comparatively - simple linear algebra, in one direct step. However LLS is a special case - which is also solved along with more general NLLS problems by the iterative + simple linear algebra, in one direct step. However the linear special case + is also solved along with more general nonlinear problems by the iterative procedure that `gnuplot` uses. `fit` attempts to find the minimum by doing a search. Each step (iteration) calculates WSSR with a new set of parameter values. The Marquardt-Levenberg algorithm selects the parameter values for @@ -6858,7 +6860,7 @@ Ffigure_zerror 4 statistical overview ?commands fit error statistical_overview ?statistical_overview - The theory of non-linear least-squares (NLLS) is generally described in terms + The theory of non-linear least-squares is generally described in terms of a normal distribution of errors, that is, the input data is assumed to be a sample from a population having a given mean and a Gaussian (normal) distribution about the mean with a given standard deviation. For a sample of @@ -6907,9 +6909,9 @@ Ffigure_zerror in the same way as the standard errors (standard deviation of each parameter) of a linear least-squares problem, even though the statistical conditions for designating the quantity calculated to be a standard deviation are not - generally valid for the NLLS problem. The asymptotic standard errors are - generally over-optimistic and should not be used for determining confidence - levels, but are useful for qualitative purposes. + generally valid for a nonlinear least-squares problem. The asymptotic + standard errors are generally over-optimistic and should not be used for + determining confidence levels, but are useful for qualitative purposes. The final solution also produces a correlation matrix indicating correlation of parameters in the region of the solution; The main diagonal elements, @@ -6982,11 +6984,11 @@ Ffigure_zerror of parameter uncertainties or evaluate the significance of the correlation matrix. - Note that `fit`, in common with most NLLS implementations, minimizes the - weighted sum of squared distances (y-f(x))**2. It does not provide any means - to account for "errors" in the values of x, only in y. Also, any "outliers" - (data points outside the normal distribution of the model) will have an - exaggerated effect on the solution. + Note that `fit`, in common with most nonlinear least-squares implementations, + minimizes the weighted sum of squared distances (y-f(x))**2. It does not + provide any means to account for "errors" in the values of x, only in y. + Also, any "outliers" (data points outside the normal distribution of the model) + will have an exaggerated effect on the solution. 3 control ?commands fit control ?fit control @@ -7014,13 +7016,15 @@ Ffigure_zerror Starting with gnuplot version 6, the `fit` command always returns to the next command input line regardless of the success or failure of fitting. This allows scripted recovery from fit errors. The variable FIT_ERROR is - set to 0 on success, non-zero on error. - Example: + set to 0 on success, non-zero on error. This example plots however many + of five data sets can be successfully fit. Failure for data set 2 would + not prevent fitting data sets 3 through 5. do for [i=1:5] { DATA = sprintf("Data_%05d.dat", i) fit f(x) DATA via a,b,c if (FIT_ERROR || !FIT_CONVERGED) { + print "Fit failed for ", DATA continue } set output sprintf("dataset_%05.png", i) @@ -7083,6 +7087,37 @@ Ffigure_zerror criterion, or a physical sense, with a solution more consistent with the model.) Depending on the problem, it may be desirable to `fit` with various sets of starting values, covering a reasonable range for each parameter. +3 time data +?commands fit time_data +?fit time_data + In fitting time data it is important to remember that gnuplot represents + time as seconds since 1 January 1970. For example if you wanted to fit a + quadratic model for the time dependence of something measured over the course + of one day in 2023, you might expect that it could be done using + T(x) = a + b*x + c*x*x + set xdata time + fit T(x) 'hits.dat' using 1:3 via a,b,c + + This will probably fail, because internally the x values corresponding to + that one day will have a range something like [1.67746e+09 : 1.67754e+09]. + The fractional change in x across the measured data will be only about + 1.e-05 and to guarantee convergence you would probably need many + decimal places of accuracy in the initial parameter estimates. + + One solution is to recast the problem as change in time since the start + of measurement. + set xdata time # data format "27-02-2023 12:00:00 measurement" + timefmt = "%d-%m-%Y %H:%M:%S" + set timefmt timefmt + t0 = strptime( timefmt, "27-02-2023 00:00:00" ) + fit T(x) 'temperature.dat' using ($1-t0):3 via a,b,c + + This shifts the range of the data to [0 : 86400], which is more tractable. + Another possibility in this case is to ignore the date in column 1 and use + relative time formats (tH/tM/tS) applied to column 2. + set timefmt "%tH:%tM:%tS" + fit T(x) 'temperature.dat' using 2:3 via a,b,c + 3 tips ?commands fit tips ?fit tips @@ -7201,7 +7236,12 @@ Ffigure_zerror Nevertheless it is still fast enough for 3D interactive rotation. #TeX The function definitions used in that demo are show below. #TeX \newline -#TeX {\small +#TeX \begin{center} +#TeX \begin{minipage}{5in} +#TeX { +#TeX \hrule +#TeX ~\newline +#TeX \small #TeX \begin{verbatim} #TeX array coef[15] = [ ... ] #TeX @@ -7221,7 +7261,10 @@ Ffigure_zerror #TeX #TeX my_lngamma(z) = (z == 0) ? NaN : (real(z) < 0.5) ? $Reflect(z) : $Lanczos(z) #TeX \end{verbatim} +#TeX \hrule #TeX } +#TeX \end{minipage} +#TeX \end{center} Use of function blocks is EXPERIMENTAL. Details may change before inclusion in a release version. @@ -8213,9 +8256,12 @@ Ffigure_convex_hull If the keyword `smooth` is present, the vertices are then used as guide points to generate a smooth closed curve (see `smooth path`). By default - this smoothed curve runs through the bounding points. The optional scale - factor shifts the guide points away from the centroid so that for scale - values greater than 1.0 all data points lie within the smoothed curve. + this smoothed curve runs through the bounding points. + + EXPERIMENTAL: The optional `expand` keyword and scale factor shift the + guide points away from the centroid so that for scale values greater than + 1.0 the smoothed curve is outside all data points. This procedure is not + very satisfactory and will be replaced in a later gnuplot version. 5 mask ?commands plot datafile filters mask @@ -9296,10 +9342,16 @@ Ffigure_smooth_path matching a template. Examples: - plot for [i=2:*] 'datafile' using 1:i with histogram + plot for [file in "A.dat B.dat"] for [column=2:*] file using 1:column splot for [i=0:*] 'datafile' index i using 1:2:3 with lines plot for [i=1:*] file=sprintf("File_%03d.dat",i) file using 2 title file + Caveat: + You can nest iterations where one is open-ended, as in the first example above. + However nesting an open-ended iteration inside another open-ended iteration is + probably not useful, since both will terminate at the same time when no data is + found. The program will issue a warning if this happens. + 3 title ?commands plot title ?commands splot title @@ -15094,9 +15146,8 @@ Ffigure_polar_grid ?unset style arrow ?show style arrow ?arrowstyle - Each terminal has a default set of arrow and point types, which can be seen - by using the command `test`. `set style arrow` defines a set of arrow types - and widths and point types and sizes so that you can refer to them later by + You can use `set style arrow` to define a set of arrow types. Each type has + its own width, point type, color, etc so that you can refer to them later by an index instead of repeating all the information at each invocation. Syntax: @@ -16088,7 +16139,7 @@ Ffigure_polar_grid If the %p format returns "am" or "AM", hour 12 will be interpreted as hour 0. If the %p format returns "pm" or "PM", hours < 12 will be increased by 12. - See also `set xdata` and `time/date` for more information. + See also `set xdata` `time/date` and `time_specifiers` for more information. Example: set timefmt "%d/%m/%Y\t%H:%M" diff --git a/faq/faq.tex b/faq/faq.tex index 80bed29e0..c06610cf9 100644 --- a/faq/faq.tex +++ b/faq/faq.tex @@ -102,7 +102,7 @@ \noindent This material describes \gnuplot version 5 (up to 5.4) \\ -FAQ version: June 2022 +FAQ version: February 2023 \\ PDF version of current document: {\http{www.gnuplot.info/faq/faq.pdf}. @@ -247,7 +247,7 @@ \subsection{What is the current version of \gnuplot?} The current stable version of \gnuplot is 5.4, first released in July 2020. Incremental versions (patchlevel 1, 2, ...) are typically released every six months. -The development version of \gnuplot is currently 5.5. +The development version is currently \gnuplot 6. \subsection{Where can I get \gnuplot?} \label{where-get-gnuplot} @@ -331,7 +331,7 @@ \subsection{What documentation is there, and how do I get it?} \subsection{Worked examples} There is a directory of worked examples in the the source distribution. -These examples and the resulting plots may also be found online at +Many of these examples and the resulting plots may also be found online at \http{gnuplot.sourceforge.net/demo/}. @@ -377,7 +377,7 @@ \subsection{How do I get help?} inhabited mostly by users who found it last century. \item -A more browser-oriented help forum may be found on StackOverflow +A more active help forum may be found on StackOverflow \http{stackoverflow.com/questions/tagged/gnuplot} \item @@ -445,7 +445,7 @@ \subsection{How do I print out my graphs?} \subsection{How do I include my graphs in my favorite word processor?} Basically, you save your plot to a file in a format your word processor -can understand, and then you read in the plot from your word processor. Vector +can understand, and then you read in the file from your word processor. Vector formats (PostScript, emf, svg, pdf, \TeX{}, \LaTeX{}) should be preferred, as you can scale your graph later to the right size. @@ -566,7 +566,7 @@ \subsection{Can I use \gnuplot routines for my own programs?} On systems supporting pipes, you can pipe commands to \gnuplot from other programs. Many applications with gnuplot as the graphics engine, like Octave -(\http{www.octave.org}), uses this method. This also works from a cgi script to +(\http{www.octave.org}), use this method. This also works from a cgi script to drive \gnuplot from a forms-based web page. @@ -602,7 +602,7 @@ \subsection{Hidden line or surface removal} This includes styles {\em with pm3d}, {\em with zerror}, {\em with boxes}, and miscellaneous plot elements generated while {\em set pm3d} is in effect. Hidden surface removal for these plots is achieved instead by drawing them -in order of their distance from the viewer, controlled by +in order of their distance from the viewer, enabled by the command {\em set pm3d depthorder}. \subsection{How do I force exact positions for the graph borders on the page?} @@ -692,7 +692,7 @@ \subsection{Animations} set terminal gif animate {delay

    }", " {tiny | small | medium | large | giant}", " {font \" {,}\"} {fontscale }", -" {size ,} {{no}crop} {animate}", +" {size ,} {animate} {{no}transparent}", " {background }", "", " The `sixel` output format was originally used by DEC terminals and printers.", -" This driver produces a sixel output stream by converting a PNG image created", -" internally using the gd library. The sixel output stream can be viewed in the", -" terminal as it is created or it can be written to a file so that it can be", -" replayed later by echoing the file to the terminal.", +" The gnuplot sixelgd driver produces a sixel output stream by converting a", +" PNG image created internally using the gd library. The sixel output stream", +" can be viewed in the terminal as it is created or it can be written to a file", +" so that it can be replayed later by echoing the file to the terminal.", "", " The sixel terminal is also useful for displaying gnuplot graphics on the", " linux console when no windowing system or graphics display manager is active.", " See `linux console`.", "", -" `transparent` instructs the driver to make the background color transparent.", -" Default is `notransparent`.", -"", " The `linewidth` and `dashlength` options are scaling factors that affect all", " lines drawn. They are multiplied by values requested in drawing commands.", "", " By default the sixel output uses 16 indexed colors. The `truecolor` option", -" instead creates a TrueColor png image that is mapped down onto 256 colors", +" instead creates a 24-bit RGB png image that is mapped down onto 256 colors", " in the output sixel image. Transparent fill styles require the `truecolor`", " option. See `fillstyle`.", -" A `transparent` background is possible in either indexed or TrueColor images.", "", " `butt` instructs the driver to use a line drawing method that does", " not overshoot the desired end point of a line. This setting is only", " relevant for line widths greater than 1. The alternative is `rounded`,", " which produces somewhat more uniform curved lines but can be much slower.", "", -" The details of font selection are complicated.", +" The details of font selection in the gdlib terminals are complicated.", " For more information please see `fonts`.", "", -" The output plot size is given in pixels---it defaults to 640x480.", -" Please see additional information under `canvas` and `set size`.", -" Blank space at the edges of the finished plot may be trimmed using the `crop`", -" option, resulting in a smaller final image size. Default is `nocrop`." +" The output plot size is given in pixels. It defaults to 640x480,", +" which is probably smaller than the size of your terminal window.", +"", +" `transparent` instructs the driver to make the background color transparent,", +" but most terminal emulators do not support this. Default is `notransparent`.", "", -" The terminal has been successfully tested with the xterm, mlterm and mintty", -" terminals. The later two support the `truecolor` mode using 256 sixel", -" colors out of box. Distributed copies of xterm may or may not have been", -" configured to support sixel graphics and may be limited to 16 colors.", +" Gnuplot's sixelgd output has been successfully tested with terminal", +" emulators including konsole, mlterm, mintty, and the vt340 mode of xterm", +" (note that distributed copies of xterm may not have been configured", +" to support sixel graphics). Sixel support in the KDE konsole terminal", +" was added in version 22.04.0.", "", "?set terminal sixelgd animate", "?set term sixelgd animate", @@ -3054,8 +3051,8 @@ START_HELP(sixelgd) "", " The `animate` option resets the cursor position to the terminal top left at", " the start of every plot so that successive plots overwrite the same area on", -" the screen rather than having earlier plots scroll off the top. This may be", -" desirable in order to create an in-place animation.", +" the screen rather than having earlier plots scroll off the top. This can be", +" used to create an in-place animation.", "" END_HELP(sixelgd) #endif /* TERM_HELP */
    - This page generated October 2022 + This page generated February 2023 @@ -278,9 +277,9 @@
  • Gnuplot development pages on SourceForge
  • On-line PDF documentation in - English + English and - Japanese + Japanese
  • - This page generated October 2022 + This page generated February 2023 @@ -245,7 +244,7 @@ on mouse-coordinate tracking.
  • Gnuplot development pages on SourceForge
  • On-line documentation in - PDF
  • + PDF