[R-sig-Geo] mlr3spatial
Giuseppe Amatulli
g|u@eppe@@m@tu||| @end|ng |rom gm@||@com
Sun Apr 17 18:40:17 CEST 2022
Hi,
I'm trying to apply a supervised regression following the example at
https://mlr3spatial.mlr-org.com/articles/mlr3spatial.html
In my case the response variable is a presence-absence (0/1) raster file
with many NA values
task = as_task_regr
<https://mlr3.mlr-org.com/reference/as_task_regr.html>(backend, target
= "presence-absence")
print <https://rdrr.io/r/base/print.html>(task)#> <TaskRegr:backend>
(122848 x 6)#> * Target: presence-absence#> * Properties: -#> *
Features (5):#> - dbl (5): band2, band3, band4, band5, band6
At this point I need to extract the row_ids where
presence-absence != NA
in order to fill the
learner$train(task, row_ids = row_ids)
I have tried to search for an example but I could not find one.
Can anyone help me?
Thanks
--
Giuseppe Amatulli, Ph.D.
Research scientist at
School of the Environment
Yale University
New Haven, CT, USA - 06511
Twitter: @BigDataEcology
Teaching: http://spatial-ecology.net
Work: https://environment.yale.edu/profile/giuseppe-amatulli/
[[alternative HTML version deleted]]
More information about the R-sig-Geo
mailing list