【问题标题】:Gnuplot - fittingGnuplot - 拟合
【发布时间】:2020-07-08 20:16:28
【问题描述】:

请问装修有什么问题?

A = -100
C = -0.3
D = 22
f(x) = A*sin(2*pi*x+C)+D
fit f(x) 'RV_phase' via A,C,D
g(x) = -100*sin(2*pi*x-0.3)+22

plot 'RV_phase' u 3:2 with points pt 7 ps 1 notitle, f(x) lc rgb "black" title "Fitted", g(x) lc rgb "red" title "Manual setting"

手动设置曲线是否足够?

【问题讨论】:

  • 拟合时还必须指定数据列:fit f(x) 'RV_phase' using 3:2 via A,C,D
  • @Alex:我的印象是您正在拟合径向速度曲线。查看 GLS 周期图的Fortran version。它包含一个 gnuplot 脚本以适应圆形和开普勒轨道。

标签: gnuplot curve-fitting


【解决方案1】:

对于拟合,您必须使用 using 指定相同的数据列,就像您在绘图时使用的那样:

fit f(x) 'RV_phase' using 3:2 via A,C,D 
plot 'RV_phase' using 3:2 with points, f(x) with lines

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2016-03-22
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-09-30
    相关资源
    最近更新 更多