Generating a travel time to health facilities raster surface using R - r

I am trying to generate a Travel time to health facilities in r using the
gdistancepackage in R. I have already implemented this in ArcGIS 10.1 using the path Distance algorithm that is able to account for differences in land cover and elevation (while including Tobler's hiking function). Does anyone know if it can be implemented and how?

Related

Doing nearest neighbor analysis using road distance in R

I am trying to do nearest neighbor analysis using road distance in R. (For example, looking at nursing homes nationwide and trying to identify the five closest hospitals to each one.) I had used Euclidean distance before using st_nn but I am now interested in trying to replicate the analysis using road distance. I know that if I had any two points I could use a number of packages to define road distance between them (e.g. googleway), but not sure if that is available for k-nearest neighbor approaches.
I was recommended to try spatstat.linnet::distfun.lpp:
https://gis.stackexchange.com/questions/451410/doing-nearest-neighbors-accounting-for-road-distance-in-r/451416?noredirect=1#comment737625_451416)
I am having trouble however trying to figure out how to take a grid like open street maps and coverting it to linnet format, as that program would require. Does anyone have any ideas/alternatives?

Plot coastline and calculate distances (marmap and ggmap)

I am working on a research project in marine ecology, using R, and I would like to create a map of a small and precise part of the French Mediterranean coast. From this map I would like to add the different fish collection sites in order to calculate the distances between these sites, taking into account the topology of the coast (the sites being very close to the coast). I have used the marmap package to do this, however due to the size of the map I wish to create, the resolution is very poor and the map is unworkable.
data <- getNOAA.bathy(lon1 =2.97,lon2 =3.53,lat1 =41.9,lat2 =42.3,resolution = 1)
I would like to know if there is an alternative, such as using the ggmap package to get a map with a good resolution, then import the GPS points of the sites and calculate the distances between them using marmap ? Are the two packages compatible?
Do you have any other ideas?
I'd recommend using leaflet for mapping and geosphere to find the Haversine (as the crow flies` distance betwen points.

Edge detection for 3d point clouds/meshes with R

The detection of edges in 3d objects may be the first step for the automatic processing of particular characteristics and landmarks.
Thus, I'm looking for a method to identify such edges for some of my 3d-scanned objects.
However, with all my ideas (Hough transformation, angles threshold for neighboring vertices) I didn't succeed.
Thus, I'd be quite happy if someone could point me to a solution to the edge-finding-problem for 3d point clouds which can be applied using R.
There is a nice paper from last year about this topic.
Basically, you need to compute several features, for each point, based on it's neighbors.
I usually prefer Python over R so I'm not aware of any point-cloud processing package un R. But the implementation of that paper in R should be easy.
If you can translate Python-R, you can take a look at this library that I wrote as it has already implemented the computation of all the features mentioned on that paper.
If that helps you, in this answer you can find example code on how to add the curvature for each point. You just have to replace the word curvature with the other names of features.

The unit of area in R package {UScensus2010}

I am using the {UScensus2010} package in R and trying to get the area for each county. I found the areaPoly() in the package. Does anyone know the unit of the area? Is it square mile?
Thank you.
Assuming you are using US Census data, this is from the explanation of the dataset that UScensus2010 links to:
Land area measurement in square meters. The accuracy of the area
measurement is limited by the inaccuracy inherent in the mapping of
the various boundary features in the Census Bureau’s geographic
database. Land area includes areas classified as intermittent water,
swamps, and glaciers, which appear on census maps and in the Census
Bureau’s geographic database as hydrographic features. Square miles
can be derived by dividing square meters by 2,589,988. See Appendix A,
“Geographic Terms and Concepts,” for definition of this field.
http://www.census.gov/prod/cen2010/doc/sf1.pdf
If you are still unsure, pick your home county and check it against the area that wikipedia or the official county website claims.

How do you find the closest point to line on a geometric network in VBA?

I work in GIS with VBA. I have a geometric network that contains 2 layer River (polyline) and Hydrometry station (Point). I want to find the closest Point to the selected River, but I want that distance to be measured on the network, not the direct distance.
How can I code this in VBA?
It's hard to answer your question because you don't describe your "geometric network" in any detail, but the Floyd–Warshall algorithm will find all distances in the network between points on the river and points at hydrometry stations.
Wikipedia has links to implementations in many languages; there should be no difficulty in adapting one to VBA.

Resources