Non-linear regression models in PostgreSQL using R

后端 未结 3 1368
北恋
北恋 2021-02-06 14:56

Background

I have climate data (temperature, precipitation, snow depth) for all of Canada between 1900 and 2009. I have written a basic website and the simplest page a

3条回答
  •  猫巷女王i
    2021-02-06 15:50

    May I propose a different solution? Just use PostgreSQL to pull the data, feed it into some R script and finally show the results. The R script may be as complicated as you want as long as the user doesn't have to deal with it.

    You may want to have a look at rapache, an Apache module that allows running R scripts in a webpage. A couple of videos illustrating its use:

    • Hello world application
    • Jeffrey Horner's presentation of RApache + links to working apps

    In particular check how the San Francisco Estuary Institue Web Query Tool allows the user to interact with the parameters.

    As for the regression, I'm not an expert, so I may be saying something extremely stupid... but wouldn't something like a LOESS regression be OK for this?

提交回复
热议问题