I would like to chnage function implemented in python to R as the following

I have shapefile and I would like to add the number of the class to it using function as the following in python

Python code:
def Soybeans11(feature):
return feature.set("Class",0)

R code:
Soybeans11 <- function(feature){ return feature.set("Class",0)}

but the code in R does not work. could you please help me in this if possible?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.