【问题标题】:Visualize accuracy in a longitude latitude plot在经度纬度图中可视化精度
【发布时间】:2020-04-18 18:01:37
【问题描述】:

我使用 ggplot 库来绘制我的数据(移动设备的经度、纬度、指南针方向和 gps 精度):

data = st_as_sf(data, coords=c("longitude","latitude"), crs=2163)

ggplot(data) + 
      geom_sf(aes(size=accuracy), alpha=0.02) +
      geom_sf(aes(color=compass), size=.5)

我正在寻找有关精度的解决方案:精度值以米为单位。它描述了与玩家位置的可能偏差(长纬度数据通过 gps 测量)。我想要一个圆圈来覆盖可能偏差的确切区域(以 m 为单位)。

【问题讨论】:

    标签: r ggplot2 plot


    【解决方案1】:

    如果该地区在美国,您可以将数据转换为投影的 CRS,例如 st_transform(data,2163)。然后使用st_buffer 计算每个点周围的圆。 dist 参数应该是半径,以米为单位。

    【讨论】:

    • 这个:buffer <- st_buffer (data, data$accuracy) 不起作用...
    • 要确定原因,您需要发布一个可重现的示例,其中包含示例data...
    猜你喜欢
    • 2015-08-31
    • 1970-01-01
    • 2012-03-01
    • 1970-01-01
    • 2013-10-09
    • 2012-03-03
    • 2014-08-15
    • 1970-01-01
    • 2013-09-09
    相关资源
    最近更新 更多