Menu

problem with output fit f(x) with yerrors

Help
2022-11-25
2022-11-27
  • Albert Pechoč

    Albert Pechoč - 2022-11-25

    Hi,
    I've been trying to make a graph with fit function using yerrors and it is not working. I think tajt the fit is ok because everything goes all right until I add the f(x) to plot. Can anyone tell me where the misstake is? Thank you!

    the code is here:
    clear
    reset
    set border 1
    set yzeroaxis
    set title "zavislost kapacity na plose"
    set xlabel "plocha desky"
    set ylabel "kapacita"

    E=0.00001

    set terminal eps size 1200,1200 font "Times-New-Roman,25"
    set output 'kond.eps'
    set terminal png size 1200,1200 font "Times-New-Roman,25"
    set output 'kond.png'

    f(x)= E*x/0.05
    fit f(x) "data.txt" using 1:2:3 yerrors via E
    plot 'data.txt' using 1:2:3 title "---" with yerrorbars linestyle 1 , \,f(x)

     
  • Hans-Bernhard Broeker

    Your plot script appears garbled. Particularly the last line has too many commas and backslashes to work as-is.

     
  • Albert Pechoč

    Albert Pechoč - 2022-11-27

    Oh yeah, tahnak you. I am quite new to this and I just copied the commnad behind the other. Your comment helped me to fix it.

     
  • Albert Pechoč

    Albert Pechoč - 2022-11-27

    Oh yeah, tahnak you. I am quite new to this and I just copied the commnad behind the other. Your comment helped me to fix it.

     

Log in to post a comment.