yltsrc / geocalc Goto Github PK
View Code? Open in Web Editor NEWGeographic calculations for Elixir
License: MIT License
Geographic calculations for Elixir
License: MIT License
hi guys,
first of all, thank you so much for this library!
its amazing !
i just wanted to make a suggestion, it would be great if we could
calculate the bounding box coordinates of a given point at its center along with a radius.
use case:
assuming, having bunch of points saved in the database (longitudes an latitudes),
this could help us find records that are within X miles / kms of a given point.
here is an example of ruby implementation:
https://github.com/alexreisner/geocoder/blob/master/lib/geocoder/calculations.rb#L212
again,
thanks for all the hard work :)
Sorry if this is suppose to be obvious but without clear documentation...people can make mistakes
It would be nice if Decimal.t()
were an accepted input format. I guess they'll be converted to floats if performance depends on floating point arithmetic, but I like to store geo points using Decimals for precision.
Would it be possible to have a Triangle shape to go along with the existing Circle, Rectangle, and Ellipse?
Hi. thank you for this amazing library. I would like to know how I can use this library to find a bounding box between 2 pairs of coordinates. Ex I have the input [{lat1, long1}, {lat2,long2}] and would like the bounding box between them as output.
I'm getting a compilation error for the type Geocalc.DMS.t() on Elixir 1.10:
== Compilation error in file lib/geocalc/dms.ex ==
** (CompileError) lib/geocalc/dms.ex:18: type t/0 undefined (no such type in Geocalc.DMS)
(elixir 1.10.0) lib/kernel/typespec.ex:898: Kernel.Typespec.compile_error/2
(stdlib 3.11.2) lists.erl:1354: :lists.mapfoldl/3
(elixir 1.10.0) lib/kernel/typespec.ex:950: Kernel.Typespec.fn_args/5
(elixir 1.10.0) lib/kernel/typespec.ex:936: Kernel.Typespec.fn_args/6
(elixir 1.10.0) lib/kernel/typespec.ex:377: Kernel.Typespec.translate_spec/8
(stdlib 3.11.2) lists.erl:1354: :lists.mapfoldl/3
(elixir 1.10.0) lib/kernel/typespec.ex:229: Kernel.Typespec.translate_typespecs_for_module/2
I see it's already been updated on the master branch. Can we get this into the hex packages? v0.7.1 is the most recent version that will compile for me.
Thanks
Hi,
Is there any particular reason this library is implemented as an OTP app with a supervision tree and not a plain module just exposing calc functions?
Thanks!
I added the ability to go from point/radius -> bounding box before. Was thinking it'd be good to be able to determine whether a point exists in a bounding box as well. (I'll work on the PR for this)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.