title: Power regression in R similar to excel
body: <p>I have a simple dataset and I am trying to use the power trend to best fit the data. The sample data is very small and is as follows:</p>
  
  <pre><code>structure(list(Discharge = c(250, 300, 500, 700, 900), Downstream = c(0.3, 
  0.3, 0.3, 0.3, 0.3), Age = c(1.32026239202165, 1.08595138888889, 
  0.638899189814815, 0.455364583333333, 0.355935185185185)), .Names = c("Discharge", 
  "Downstream", "Age"), row.names = c(NA, 5L), class = "data.frame")
  </code></pre>
  
  <p>Data looks as follows:</p>
  
  <pre><code>&gt; new
    Discharge Downstream       Age
  1       250        0.3 1.3202624
  2       300        0.3 1.0859514
  3       500        0.3 0.6388992
  4       700        0.3 0.4553646
  5       900        0.3 0.3559352
  </code></pre>
  
  <p>I tried to plot the above data using <code>ggplot2</code> </p>
  
  <pre><code>ggplot(new)+geom_point(aes(x=Discharge,y=Age))
  </code></pre>
  
  <p>I could add the linear line using <code>geom_smooth(method="lm")</code> but I am not sure what code do I need to show the power line.</p>
  
  <p>The output is as follows:</p>
  
  <p><img src="https://i.stack.imgur.com/r3zjW.png" alt="enter image description here"></p>
  
  <p>How Can I add a power linear regression line as done in excel ? The excel figure is shown below:</p>
  
  <p><img src="https://i.stack.imgur.com/lnlNn.png" alt="enter image description here"></p>