Menu

fit xerror help

gnutron
2014-09-23
2014-09-24
  • gnutron

    gnutron - 2014-09-23

    Hi, I am using 5.0rc2 and am trying to fit a line to a data file with x, y, and x_err columns. I do:
    f(x)=m*x+b
    fit f(x) 'data.txt' u 1:2:3 xerror via m,b

    and gnuplot outputs "xerror requires exactly 2 columns". How can I make this work? Thanks!

     

    Last edit: gnutron 2014-09-23
  • Ethan Merritt

    Ethan Merritt - 2014-09-23

    Gnuplot does not support fitting [x,y] data with x errors.
    The "xerror" keyword was a mistake, and has been removed.
    Sorry about that.

    The fit command is one of the remaining areas still under revision leading up to version 5. As it stands right now, neither the "xerror" or "noerror" keywords will be used in the final 5.0 release.

    If you really mean that the 3rd column contains y errors, that's another story.

     
  • gnutron

    gnutron - 2014-09-24

    Ok, good to know. I just made up realistic (small) yerr bars in a fourth column and used the xyerror option. I assume this takes into account both the x- and y-error bars. Thanks!

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.