title: Place linear function on orthonormal system
body: <p>I've been trying for 2-3 days to do a really simple linear function such as f(x) = ax+b and place it on a orthonormal system. I have no experience at all in R and my research have been unsuccessful.</p>
  <p>My attempts so far (I have close to 0 experience in code overall) are:</p>
  <pre><code>fun &lt;- function(x){ return(a x + b) } 
  curve(fun, from = -100, to = 100, ylab = expression(ax+b), main = &quot;curve function&quot;) 
  </code></pre>
  <p>Also functions I've been trying to use:<br />
  <code>curve</code>, <code>abline</code>, <code>plot</code>.<br />
  And things I've found like</p>
  <pre><code>plot(c(0:9),c(1:10)) 
  abline(2,1,col=&quot;red&quot;,lwd=2) 
  </code></pre>
  <p>were not really helpful but at least I know I can do what I want to and other things I haven't saved. (Sorry for my english.)</p>