[R-sig-Geo] Coding and addition of explanatory variables

Enoch Gyamfi Ampadu eg@mp@du @end|ng |rom gm@||@com
Tue Jun 9 16:06:15 CEST 2020


Dear List,

Please I am doing a biomass analysis with a satellite image. The
explanatory variables include the satellite bands and vegetation indices. I
am using Random forest regression. I have added bands of the satellite
image to the model and it worked. However, when I tried to add the
vegetation indices (bands) I get error messages. I have put the codes I am
using below;

Model <- randomForest(class~ B1 + B2 + B3 + B4 + B5 + B6 + B7 + B8 + B9 +
B10 + B11 + B12 + DVI1, data = Trainingset, proximity=TRUE,
                            importance=TRUE).
The "DVI1" is the vegetation index variable band I tried to add to the
model.

Below is the error message I received.

"Error in eval(predvars, data, env) : object 'DVI1' not found"

   I will be glad if I could get some assistance on how to resolve it.

Best regards,

Enoch

-- 
*Enoch Gyamfi - Ampadu*

*Geography & Environmental Sciences*

*College of Agriculture, Engineering & Science*

*University of KwaZulu-Natal, Westville Campus*

*Private Bag X54001*
*Durban, South Africa **– 4000**.*
*Phone: +27 835 828255*

*email: egampadu using gmail.com <egampadu using gmail.com>*


*skype: enoch.ampadu*
*The highest evidence of nobility is self-control*.

*A simple act of kindness creates an endless ripple*.

	[[alternative HTML version deleted]]



More information about the R-sig-Geo mailing list