Function for converting a raster to a dataframe.

rast_to_df(x, time_dim)

Arguments

x

Rast stack resulted from detect3event and re-organized until 'nc_no_NA' (see detect3 function)

time_dim

The time dimension. It should be a single value to use as the origin for the date indexes

Value

This function will convert a raster object to a dataframe.