Contour plot for quadratic equation in R

前端 未结 1 438
时光取名叫无心
时光取名叫无心 2021-01-24 22:36

I\'m trying to recreate contour plot shown in the picture below using R. It is a contour plot of constant syrup loss as a function of speed and pressure.

相关标签:
1条回答
  • 2021-01-24 22:55

    In the outer function, the Y argument is missing. The code

    z <- outer(x, y, function(x, y) 1217.30556 - 31.25625*x + 86.01667*y + 0.1291*x^2  - 2.87333*y^2 + 0.02875*x*y) 
    

    fixed the problem.

    0 讨论(0)
提交回复
热议问题