0

I'd like to perform a regression analysis in QGIS. Let's say for example that I have 3 grids as my dependent variable and 3 single values as my predictor. That is, for a single value of the predictor I'll have as many values as dependent variable as the number of cells in a grid. For another single value as predictor, I'll have as many values as dependent variable as the number of cells of another grid and so on. I want to perform a regression analysis between the predictor and the dependent, for example with a power law such as Y=a*(X^b) where X is a single value and Y all the values of a single grid. As a result, I'll have consequently two grids as output, one for a values and one for b values.

Is it possible to do so, maybe using Python?

0

Can you clarify: do you want a single number to predict the value everywhere on a grid? That is, is the grid a constant value?

0

Yes i want the single number to predict the value everywhere but the grid is not constant. Let's say for example, i have 3 single values and 3 grids, with 4 cell each one. All the grids have the same extension. Given a spatial location (that is, given a single cell in a certain position), i'll have 3 dependant values, one for each grid, in that cell: each one of these 3 values is related to a single value of the predictors. If i do the regression, i'll obtain "a" and "b" parameters valid for the cell i've considered. I move to another cell, repeat the process and obtain "a" and "b" parameters valid for this second cell, and so on. What i'll have eventually is 4 values for "a", and 4 for "b". I hope that I have been able to explain the problem. Thanks for your answer!

1
  • Might be easier if you edit your original question and show a map of your data and the grids. Tell us which features are inputs and which are outputs. The SAGA plugin has regression analysis for points and predictor grids, but I think you are doing the reverse. – wingnut Apr 7 at 5:04

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.