I've been trying to run locfit on data with 6 inputs and 1 output in R. Whenever I make a prediction for the same exact data that the model was built on though, I get significant discrepancies between the fitted outputs of the prediction and the actual data. I have scaled the inputs, tweaked the alpha parameter, and played around with a lot of the other variables as well. Is their some kind of bug in locfit or is it just unable to do multivariate local regression with so many variables? I was able to accurately predict data using Vizier, commercialized software that also performs locally weighted regression. Thanks. Sincerely, Paul Leu -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
>From Leu_Paul_W at cat.com Wed Jun 13 11:32 EDT 2001 > > I've been trying to run locfit on data with 6 inputs and 1 output in >R. Whenever I make a prediction for the same exact data that the model was >built on though, I get significant discrepancies. I have tweaked the alpha >parameter to no avail and played around with a lot of the other variables >as well. Is their some kind of bug in locfit or is it just unable to do >multivariate local regression with so many variables? > I was able to accurately predict data using Vizier, commercialized >software that also performs locally weighted regression.I don't think I understand the problem properly, can you send more details of what you're trying to do? Some possible explanations would be (1) There usually should be discrepancies between the data and the predictions at the data points; the only cases when there should be no discrepancy is if the data are a polynomial (<= quadratic, for local quadratic fits). (some authors have forced interpolation of the data by using a singular weight function in the local regression; locfit doesn't do this). (2) By default, the locfit() function fits the local polynomial model at a selected set of points; the predict() function interpolates from the fit at the selected points. So the output of predict() is not exactly equal to the local regression surface. This default can be overridden by giving a matrix of fitting points as the ev argument, locfit(...,ev=...). (3) The fitting should work in six dimensions (although I haven't extensively tested beyond 2-3 dimensions). The interpolation used by predict() may be problematic (as high dimensional interpolation usually is) although the code should work. Regards, Catherine. (sorry for sending this partial response to the whole list, replying to the sender produces Your request ``mail cat.com Leu_Paul_W '' failed (code P). The symptom was: Thu Jun 14 09:54:06 EDT 2001 connect to cat.com: 550 5.1.1 <Leu_Paul_W at cat.com>... User unknown ) -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
I''ve been trying to run locfit on data with 6 inputs and 1 output in R. Whenever I make a prediction for the same exact data that the model was built on though, I get significant discrepancies between the fitted outputs of the prediction and the actual data. Here is an example of some of the parameters I tried: fit <-locfit(plossactual~Reynolds.Bevel+Reynolds.Pinion+Pinion.Velocity+Bevel.Velocity,data=nte,ev "x", alpha=c(0, .035), scale=c(2e6, 6e5, .6, 1.2, 200, 200)) As you can see, the bandwidth is an extremely small constant value and so all data should be fitted close to exact (I tried even smaller too). The variable "x" contains exactly the same data that the model is using so there shouldn''t be any issues of interpolation. When I used the predict function, I used the same set of data ("x" and "predictionpoints" are the same). I also tried a variety of scaling schemes, including just setting the value to T. Currently, I am just trying to verify that the locfit algorithm does in fact work for multivariate data by building a model on some data and then using the model to predict the same set of data, before I start getting into issues with interpolation, extrapolation, cross validation, etc. Am I missing something here? Thanks for your time and your help. Sincerely, Paul Leu -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._