View source: R/byGridCell_CreateSFDataset.R
byGridCell_CreateSFDataset | R Documentation |
Function to create a map layer with values by grid cell.
byGridCell_CreateSFDataset( dfr, roms_grid, dataID = "gridCellID", join_type = c("right join", "left join", "inner join", "full join") )
dfr |
- dataframe with values to create map layer by gridCellID |
roms_grid |
- ROMS grid name, path to shapefile, or sf dataframe with grid polygons by ID |
dataID |
- column name for grid cell ids in input dataframe |
join_type |
- join type for |
Uses getGrid
if roms_grid is the name of a ROMS grid.
Uses readShapefile
if roms_grid is a shapefile.
The results depend on the join type:
- right join: matched rows in dfr
, all rows in roms_grid
- left join: all rows in dfr
, matched rows in roms_grid
- inner join: only rows in dfr
matched to roms_grid
- full join: all rows in dfr
and all rows in roms_grid
an sf (simple features) dataframe with the values by grid cell.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.