0

I have a data file to be fitted to a scatterplot in .txt format with simple x,y data.

I also have two lines that I want to overlay on the data:

Line 1: y= -0.2232589739194248 * x + 4.381190125671611

Line 2: y= 5.517500395590605 + -0.8442345203102343 * x + 0.07974732479342203 * x*x

I can plot each of these separately using the plot function, but how do I get them to all appear together?

1 Answer 1

1

Just use

set style func lines
plot 'file.txt' with points,\
     -0.2232589739194248 * x + 4.381190125671611,\
     5.517500395590605 + -0.8442345203102343 * x + 0.07974732479342203 * x*x
Sign up to request clarification or add additional context in comments.

2 Comments

@user3005506 Then you can consider accepting and possibly upvoting the answer :)
Sorry, took me a while. Thanks again :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.