convert_to_matrix: Convert an object to a matrix

View source: R/convert_matrix.R

convert_to_matrixR Documentation

Convert an object to a matrix

Description

This function is mainly for internal use by the spatialwarnings package to convert objects before they are processed by *_sews functions.

Usage

convert_to_matrix(object, ...)

Arguments

object

An object (typically, a matrix or a list of matrices)

...

Additional arguments (currently ignored)

Details

This generic function is here so that other packages can extend it. For example, spatialwarningsGis will provide methods so that GIS objects can be handled (e.g. RasterLayer from package raster).

Examples


# this does nothing
convert_to_matrix(serengeti[2:3]) 


spatialwarnings documentation built on Sept. 11, 2024, 8:55 p.m.