首页 \ 问答 \ 如何根据位置接近度平均值(How to average values based on location proximity)

如何根据位置接近度平均值(How to average values based on location proximity)

我有一个带有地理标记值(经度,纬度,值)的SQL表。 该表快速累积,有数千个条目。 因此,在表中查询某些区域中的值会返回非常大的数据集。

我想知道平均值与近距离接近一个值的方法,这里是一个例子:

表:

Long            lat           value
10.123001       53.567001      10
10.123002       53.567002      12
10.123003       53.567003      18
10.124003       53.568003      13

比方说我目前的位置是10.123004,53.567004。 如果我在查询附近的值,我会得到值为10,12,18和13的四个原始数据。如果数据集相对较小,则可以使用。 如果数据很大我想查询sql的舍入位置(10.123,53.567)并需要sql来返回类似的东西

Long            lat           value
10.123       53.567      10 (this is the average of 10, 12, and 18)
10.124       53.568      13

这可能吗? 我们如何根据位置平均大数据集?

sql数据库首先是正确的选择吗?


I have an SQL table with geo-tagged values (Longitude, Latitude, value). The table is accumulated quickly and has thousands entries. Therefore, querying the table for values in some area return very large data-set.

I would like to know the way to average value with close location proximity to one value, here is an illustration:

Table:

Long            lat           value
10.123001       53.567001      10
10.123002       53.567002      12
10.123003       53.567003      18
10.124003       53.568003      13

lets say my current location is 10.123004, 53.567004. If I am querying for the values near by I will get the four raws with values 10, 12, 18, and 13. This works if the data-set is relatively small. If the data is large I would like to query sql for rounded location (10.123, 53.567) and need sql to return something like

Long            lat           value
10.123       53.567      10 (this is the average of 10, 12, and 18)
10.124       53.568      13

Is this possible? how we can average large data set based on locations?

Is sql database is the right choice in the first place?


原文:https://stackoverflow.com/questions/10384076
更新时间:2024-03-26 18:03

最满意答案

最后我可以使用我的苹果ID登录。 我从应用商店获得更新,所以我更新了软件(现在的版本是OS X El Capitan版本10.11.6)。 现在我可以登录了。 希望这对其他人有所帮助


Finally i am able to login using my apple id. I got update from app store so i have updated the software(Now version is OS X El Capitan version 10.11.6 ). Now i am able to login. Hope this will help to others

相关问答

更多
  • 我不知道这是新的预期行为还是只是一个错误。 但对我来说,上传只有当我注册为苹果开发者和itunesconnect用户具有相同的AppleId时工作。 这个答案XCode6 GoldMaster提交构建失败 ,克里斯帮助我的错误 ,但不幸的是没有做到这一切。 我是我的单一AppleId的不同开发者团队的成员。 上传应用程序只适用于我在itunesconnect中使用相同appleId注册的团队(不幸的是,您可以成为不同开发人员团队的成员,但只能是具有一个Apple ID的单个itunesconnect用户)。 ...
  • 虽然这是不可能的(我认为合法的方式)。 这不是我们正在谈论的社交网站,所以我认为Apple不会允许这样做。 如果你在这里问你的问题会更好: - Apple支持社区 希望你从那里得到一些帮助:).... Though this is not possible (the legal way I think). This is not a social networking site we are talking about, So I do not think Apple would allow this. I ...
  • 您可以使用Mac OS X的Keychain Access应用程序更改Xcode已关联的Apple Developer ID: 退出Xcode 打开应用程序>实用程序>钥匙串访问 找到名为“daw2.apple.com([您的Apple ID])的种类互联网密码的钥匙串条目 删除该钥匙串条目,并通过重新输入凭据重新输入Xcode中的下载,或者双击该条目并更新“帐户和密码”字段 打开Xcode并重试内容下载 You can change the Apple Developer ID that Xcode ha ...
  • 假设您遇到错误的问题 要更新此应用程序,请登录您以前购买的帐户。 在App Store应用程序中,转到商店 - >退出 然后做这里建议的东西 请从Beartech查看此修复程序https://discussions.apple.com/thread/2794280?start=15&tstart=0 App Store以某种方式使用Spotlight。 我的修复是将整个高清添加到Spotlight System prefs窗格中的“隐私”选项卡中,关闭prefs并等待30秒,然后从“隐私”选项卡重新打开和删 ...
  • 我可能找到了答案。 尝试使用Apple ID登录时挂起 我的macbook是二手的,我不知道它为什么没有序列号。 在El Capital(Mac OS X 10.11)下使用Apple Id登录时,系统会尝试检查序列号,然后我的mac挂起。 这不仅是Xcode问题,而且AppStore和其他地方需要在系统中使用Apple Id登录。 我有两个选择来解决这个问题。 一个是将系统恢复到10.10,另一个是去苹果商店修复它。 I probably find the answer. Hangs when tryin ...
  • 您需要为Apple ID启用双因素身份验证 在这里阅读如何做到这一点 Actually this was an issue from Apple. I have contacted them over mail and they have fixed the issue in 24 hours.
  • 那个苹果ID是下拉列表。 单击它后,您将能够选择第二个。 如果它没有显示其他人,您需要在帐户中添加新的苹果ID。 如果您使用了正确的软件包ID,证书和配置,它将自动选择apple id。 如果仍然没有,请转到查看帐户/帐户/添加Apple ID(+) 这也可以访问xcode / Preferences / Accounts。 That apple id is drop down list. Once you click it, you will be able to select second one. I ...
  • 您需要成为Apple Developer Program的一部分才能使用App Groups ... You need to be a part of the Apple Developer Program in order to make use of App Groups...
  • 我遇到了同样的问题,但在更新到Xcode 9.3.1时已解决。 I had the same issue, but it was resolved when updating to Xcode 9.3.1.
  • 最后我可以使用我的苹果ID登录。 我从应用商店获得更新,所以我更新了软件(现在的版本是OS X El Capitan版本10.11.6)。 现在我可以登录了。 希望这对其他人有所帮助 Finally i am able to login using my apple id. I got update from app store so i have updated the software(Now version is OS X El Capitan version 10.11.6 ). Now i am ...

相关文章

更多

最新问答

更多
  • Runnable上的NetworkOnMainThreadException(NetworkOnMainThreadException on Runnable)
  • C ++ 11 + SDL2 + Windows:多线程程序在任何输入事件后挂起(C++11 + SDL2 + Windows: Multithreaded program hangs after any input event)
  • AccessViolationException未处理[VB.Net] [Emgucv](AccessViolationException was unhandled [VB.Net] [Emgucv])
  • 计算时间和日期差异(Calculating Time and Date difference)
  • 以编程方式标签NSMutableAttributedString swift 4(Label NSMutableAttributedString programmatically swift 4)
  • C#对象和代码示例(C# objects and code examples)
  • 在python中是否有数学nCr函数?(Is there a math nCr function in python? [duplicate])
  • 检索R中列的最大值和第二个最大值的行名(Retrieve row names of maximum and second maximum values of a column in R)
  • 给定md5哈希时如何查找特定文件(How to find specific file when given md5 Hash)
  • Python字典因某些原因引发KeyError(Python Dictionary Throwing KeyError for Some Reason)
  • 如何让Joomla停止打开新标签中的每个链接?(How do I get Joomla to stop opening every link in a new tab?)
  • DNS服务器上的NS记录不匹配(Mismatched NS records at DNS server)
  • Python屏幕捕获错误(Python screen capture error)
  • 如何在帧集上放置div叠加?(How to put a div overlay over framesets?)
  • 页面刷新后是否可以保留表单(html)内容数据?(Is it possible to retain the form(html) content data after page refreshed?)
  • 使用iTeardownMyAppFrame和iStartMyAppInAFrame在OPA5测试中重新启动应用程序超时(Restart app within OPA5 test using iTeardownMyAppFrame and iStartMyAppInAFrame timed out)
  • 自动拆分文本内容到列(Automatically splitting text content into even columns)
  • 在r中的循环中将模型名称分配给gbm.step(assigning model names to gbm.step in loop in r)
  • 昆明哪里有电脑等级考试二级C培训?
  • C ++模板实例化,究竟是什么意思?(C++ template instantiation, what exactly does it mean?)
  • 帮助渲染来自fields_for的部分内容(Help to render a partial from fields_for)
  • 将url.action作为json对象返回mvc(return url.action as json object mvc)
  • 使用.BAT中的.application文件类型运行ac#Console App(Run a c# Console App with .application file type from a .BAT)
  • 将bindingRedirect添加到.Net标准库(Adding a bindingRedirect to a .Net Standard library)
  • Laravel版本升级会影响您的控制器吗?(Laravel version upgrade affects your controller?)
  • imaplib.error:命令SEARCH在状态AUTH中非法,只允许在SELECTED状态(imaplib.error: command SEARCH illegal in state AUTH, only allowed in states SELECTED)
  • 如何在eclipse debug impala前端
  • 如何通过Ajax API处理多个请求?(How to handle multiple requests through an Ajax API? [closed])
  • 使用Datetime索引来分析数据框数据(Using Datetime indexing to analyse dataframe data)
  • JS 实现一个菜单效果