EVOLUTION-MANAGER
Edit File: geos_query.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: Dimension, simplicity, validity or is_empty queries on simple...</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" type="text/css" href="R.css" /> </head><body> <table width="100%" summary="page for geos_query {sf}"><tr><td>geos_query {sf}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>Dimension, simplicity, validity or is_empty queries on simple feature geometries</h2> <h3>Description</h3> <p>Dimension, simplicity, validity or is_empty queries on simple feature geometries </p> <h3>Usage</h3> <pre> st_dimension(x, NA_if_empty = TRUE) st_is_simple(x) st_is_empty(x) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>x</code></td> <td> <p>object of class <code>sf</code>, <code>sfc</code> or <code>sfg</code></p> </td></tr> <tr valign="top"><td><code>NA_if_empty</code></td> <td> <p>logical; if TRUE, return NA for empty geometries</p> </td></tr> </table> <h3>Value</h3> <p>st_dimension returns a numeric vector with 0 for points, 1 for lines, 2 for surfaces, and, if <code>NA_if_empty</code> is <code>TRUE</code>, <code>NA</code> for empty geometries. </p> <p>st_is_simple returns a logical vector, indicating for each geometry whether it is simple (e.g., not self-intersecting) </p> <p>st_is_empty returns for each geometry whether it is empty </p> <h3>Examples</h3> <pre> x = st_sfc( st_point(0:1), st_linestring(rbind(c(0,0),c(1,1))), st_polygon(list(rbind(c(0,0),c(1,0),c(0,1),c(0,0)))), st_multipoint(), st_linestring(), st_geometrycollection()) st_dimension(x) st_dimension(x, FALSE) ls = st_linestring(rbind(c(0,0), c(1,1), c(1,0), c(0,1))) st_is_simple(st_sfc(ls, st_point(c(0,0)))) ls = st_linestring(rbind(c(0,0), c(1,1), c(1,0), c(0,1))) st_is_empty(st_sfc(ls, st_point(), st_linestring())) </pre> <hr /><div style="text-align: center;">[Package <em>sf</em> version 0.9-5 <a href="00Index.html">Index</a>]</div> </body></html>