I need to know if a point is in a polygon or not, in my rails app, in order to to that I wan to use rgeo gem.
To install this geme i folowed the instructions on rgeo git
Then I'm sure that GEOS and Proj4 are properly installed.
I also added this…
I'm trying to deploy a Rails app (ruby 2.3.0, rails 4.2.6) to Heroku that uses the RGeo gem, but I'm having no luck installing the underlying GEOS library upon which the RGeo gem relies (See https://github.com/rgeo/rgeo#dependencies).
According to…
I'm writing an app which I am attempting to integrate some general geolocation functionality including saving some lat/lon coordinates as a point in a database. The intention of this is to allow the user to either use their location (provided by…
First of all, apologies if this is really simple, but I just can't seem to figure it out. I am using RGeo to convert between UTM and lat/long, like this;
srs_database = RGeo::CoordSys::SRSDatabase::ActiveRecordTable.new
# create the coordinate…
I'm looking for a way to check if 2 polygons (set of lat/lon coordinates) overlap in ruby. So for example if I have a points for the USA and points for California, I should be able to tell that they overlap.
I looked into rgeo, but apparently it…
Problem
90% sure it's a setup error on my end, but I can't do self.factory and trying to access lonlat gives me an exception "undefined method `point' for nil:NilClass"
I can
Set lonlat using:
mfactory =…
I'm trying to do some spatial operations in Ruby with the RGeo gem. Unfortunately, a lot of operations require the GEOS library and I can't find any documentation showing how to integrate this in Windows (I am using Windows 7 64bit).
I tried…
What I'm trying to do is to sort mongoid geo_near(or within_circle) max_distance results by distance because I don't know why but it doesn't do that by default.
I have mongoid_geospatial, mongoid_spacial and rgeo in my Rails gem file. I know…
we have troubles in installing the GEOS library on heroku cedar stack.
We followed this guide: https://devcenter.spacialdb.com/Heroku.html and it didn't work.
We noticed that the path (/app/tmp/geos) stored in the provided geos binaries was wrong,…
I'm developing a Rails app (3.2.8) that will use the activerecord-postgis-adapter and activerecord-spatialite-adapater gems and various rgeo plugins.
I would like to use the Rails unit and functional tests in the traditional way, but this sort of…
Given a list of event locations:
event.coords <- data.frame(
event.id = letters[1:5],
lats = c(43.155, 37.804, 26.71, 35.466, 40.783),
lons = c(-77.616,-122.271, -80.064, -97.513, -73.966))
and the centroids of locales (which happen to…
Trying to get the rgeo gem to recognise geos on an ubuntu 16.04 system.
I have the following packages installed:-
libgeos-dev, libgeos++-dev and libgeos-3.7.1
geos-config --version
3.7.1
I have a symlink in /usr/lib which points to the location of…
After upgrading the rgeo gem from 0.6.0 to 2.1.1, we've started to get 'LinearRing failed ring test' on certain geometries that never caused us problems before. (The geometry data is generated from external sources outside of our control, and stored…
I'm using the rgeo gem which gives me troubles on the production server, although it works on my local machine.
This outputs are same on both local MacOS and Ubuntu 16.04 production machine:
psql --version -> (PostgreSQL) 9.6.15
geos-config…
Some geographical regions are areas that surround a major metropolitain city, where each is a distinct administrative area. This is the case of the capitals of Switzerland (de facto) and…