0
$\begingroup$

Lets say that I predicted plant productivity (logy) by precipitation (logx1) and moisture content of soil (logx2). my original data gives me the best result only after taking logarithm on both side of variables.

mod <- lm(logy ~ poly(logx1*logx2, 2, raw=TRUE)

then I got following coefficients from the model:

intercept=6.773; 
logx1*logx2 poly(1) = 2.511; 
logx1*logx2 poly(2) = 0.458

With regard to equation, I have 2 questions: 1. How I can explain the result of this equation 2. How to find the value when precipitation is 0.

Thanks in advance!

$\endgroup$
  • 1
    $\begingroup$ How much data do you have? You'd mostly likely do better to have logx1, logx2, their product, their squares, & the product of their squares. (Ie, lm(logy ~ logx1 + logx2 + logx1^2 + logx2^2 + logx1*logx2 + logx1^2*logx2^2).) This is a highly constrained model that is likely to not fit as well. Is there a very well grounded physical theory to justify this version? $\endgroup$ – gung - Reinstate Monica Jun 24 at 16:37
  • $\begingroup$ Would you please post - or link to - the original non-log data? $\endgroup$ – James Phillips Jun 24 at 16:47
  • 1
    $\begingroup$ @ James Phillips. I am sorry how to add data here? $\endgroup$ – Sun Rise Jun 24 at 17:19
  • $\begingroup$ You can paste it into the question or link to it. $\endgroup$ – James Phillips Jun 24 at 18:21
  • $\begingroup$ I have updated above $\endgroup$ – Sun Rise Jun 24 at 19:12
0
$\begingroup$

As you can see from the 3D scatterplot, the posted data seems rather noisy with both a "vertical" section and a "flat" section. The best I could find from an equation search was "Y = a * pow(X1, b) + c * pow(X2, d) + Offset" with fitted parameters a = 2.6908392707633102E+03, b = 3.4211996168376331E+00, c = 2.8379254883958050E+05, d = 2.8577605809712245E-04, and Offset = -2.8395222685511003E+05 giving RMSE = 154.6 and R-squared = 0.38

scatter

surface

$\endgroup$
  • 1
    $\begingroup$ @ James Phillips. Thank you so much. yes, data has a lot of noice. That is why I tried to use logarithmic transformation. I don't know that was right way to handle this kind of problem. Did you use specific software to do this or R? Actually all this thing are exactly what I want. to obtain RMSE & MR (%) etc. Can you tell me how to run this model in R? $\endgroup$ – Sun Rise Jun 24 at 20:42
  • $\begingroup$ My zunzun.com open source Python online curve fitting and surface fitting web site has a 3D "function finder" that I used for the equation search. I pasted your data into the online interface for this equation at zunzun.com/Equation/3/Power/Power%20D%20With%20Offset and then hit the "Submit" button. $\endgroup$ – James Phillips Jun 24 at 20:42
  • 1
    $\begingroup$ thanks again for your kind help and sharing this very usefull website as well. $\endgroup$ – Sun Rise Jun 24 at 21:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.