-
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
design & structure #1
Comments
I'd like to generate some of these in {wk} from WKB and WKT...I think you'll need a tiny bit of attribute info. The required info (from the WKB/WKT perspective) is:
I know this botches the "no attributes" thing, but if you can't represent this info then reading EWKB/EWKT will require modifying your spec, which think you don't want. A few other thoughts from the WKX perspective:
|
I think these points highlight my intention of this library. I don't want to constrain anyone to use a matrix for a linestring, or list of matrices for a polygon. I only want to provide tools to build these structures, then each user can define what they mean. So if you want to use a List of one-row matrices for a multipoint you can. Someone else might want to represent this as a completely different type. I've only listed the "conventional" structures as a starting point only. |
maybe "geometries" isn't the right name for the package. |
I came back to add that "this seems like a super powered
The two key steps in silicate are 1) splitting a data frame (into paths or segments or triangles) 2) densifying the coordinates (finding duplicates in x/y, and identifying them by splitting other columns out - this is a part of I see split for a data frame to list of matrices here, and I'd want to add split data frame or matrix to list of df as well (I reckon you've got that on the todo?). |
It's not currently a TODO. What is the requirement/benefit/use-case for having a data.frame inside the lists as opposed to matrices? |
I'll add - the use for |
A fast |
regarding 'split', I've made the |
thanks! Getting into this now - the geometries.Rmd needs an update fwiw, do you want micro feedback like this? lines 112:122 cppFunction(
depends = "geometries"
, includes = '#include "geometries/geometries.hpp"'
, code = '
SEXP my_shape( DataFrame x, IntegerVector ids, IntegerVector geometry_cols, List attributes) {
return geometries::make_geometries( x, ids, geometry_cols, attributes);
}
'
)
my_shape( df, c(0,1), c(2,3), list())
|
oh yeah - all the .Rmds are now out of date. I need to re-write them all. But thanks for pointing it out. |
sorry for that - I was a bit lost, out of the C++ groove for a while. Gee this is nice, split() but blazing fast - it's nice being able to keep or discard identifying or "geometry" columns completely indepenedently. Super general! |
Conventinoal Geometric Structures
But this library is not limiting which geometry you assign to which structure
The text was updated successfully, but these errors were encountered: