From kent3737 at gmail.com Tue Dec 1 04:04:09 2015 From: kent3737 at gmail.com (Kent Johnson) Date: Mon, 30 Nov 2015 22:04:09 -0500 Subject: [Rspatial-devel] SpatialLinesDataFrame with z-axis In-Reply-To: References: Message-ID: On Mon, Nov 30, 2015 at 2:44 AM, Roger Bivand wrote: > On Mon, 30 Nov 2015, Kent Johnson wrote: > > Hi, >> >> I am working with spatial line data which has three axes - lat, lon and >> altitude and metadata for each line. I would love to have something like a >> SpatialLines3DDataFrame. >> > > Why? Love isn't appropriate here - you need a use case. OK. I would find it helpful to have a data structure to represent tracks in three dimensions with associated metadata. My data is airplane tracks from KML files and direct recording of flight data. Some useful operations: - Plot the tracks on a map using leaflet. - Find distance from each point in the track to a fixed point on the ground - Plot distance from a fixed point vs altitude - Find the point of closest approach to a fixed point on the ground - Find the altitude at point of closest approach - Associate attributes with each track such as flight number, departure time, nearest waypoint, etc. All of the above using collections of 200-300 tracks. Have you looked at SpatialMultiPoints (as altitude could be an attribute at > a line segent end point, or a coordinate)? SpatialMultiPointsDataFrame looks promising, thanks for the pointer. > > Please use R-sig-geo for all contact - this list is only used by > developers. > OK I will use that list in the future. Kent > > Roger > > >> Thanks, >> Kent Johnson >> >> > -- > Roger Bivand > Department of Economics, Norwegian School of Economics, > Helleveien 30, N-5045 Bergen, Norway. > voice: +47 55 95 93 55; fax +47 55 95 91 00 > e-mail: Roger.Bivand at nhh.no > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From edzer.pebesma at uni-muenster.de Tue Dec 1 09:20:59 2015 From: edzer.pebesma at uni-muenster.de (Edzer Pebesma) Date: Tue, 1 Dec 2015 09:20:59 +0100 Subject: [Rspatial-devel] SpatialLinesDataFrame with z-axis In-Reply-To: References: Message-ID: <565D586B.20704@uni-muenster.de> On 01/12/15 04:04, Kent Johnson wrote: > On Mon, Nov 30, 2015 at 2:44 AM, Roger Bivand > wrote: > > On Mon, 30 Nov 2015, Kent Johnson wrote: > > Hi, > > I am working with spatial line data which has three axes - lat, > lon and > altitude and metadata for each line. I would love to have > something like a > SpatialLines3DDataFrame. > > > Why? Love isn't appropriate here - you need a use case. > > > OK. I would find it helpful to have a data structure to represent tracks > in three dimensions with associated metadata. My data is airplane tracks > from KML files and direct recording of flight data. Some useful operations: > - Plot the tracks on a map using leaflet. > - Find distance from each point in the track to a fixed point on the ground > - Plot distance from a fixed point vs altitude > - Find the point of closest approach to a fixed point on the ground > - Find the altitude at point of closest approach > - Associate attributes with each track such as flight number, departure > time, nearest waypoint, etc. > All of the above using collections of 200-300 tracks. It may be worth looking at package trajectories, as it has the concept of a track (trip), tracks (a track set, e.g. for one plane), and trackscollection (a set of tracks, e.g. multiple planes). In principle, sp SpatialPoints can cope with more than two dimensions, so trajectories can do that too. There are however currently no functions that compute distances in 3D where x and y are long/lat; I'd be interested to add those. Leaflet plotting could be obtained by coercing (and projecting) TracksCollection to 2d SpatialLinesDataFrames; this is already there. CRAN is a bit behind my devel version at github.com/edzer/trajectories/ > > Have you looked at SpatialMultiPoints (as altitude could be an > attribute at a line segent end point, or a coordinate)? > > > SpatialMultiPointsDataFrame looks promising, thanks for the pointer. > > > Please use R-sig-geo for all contact - this list is only used by > developers. > > > OK I will use that list in the future. > > Kent > > > Roger > > > Thanks, > Kent Johnson > > > -- > Roger Bivand > Department of Economics, Norwegian School of Economics, > Helleveien 30, N-5045 Bergen, Norway. > voice: +47 55 95 93 55 ; fax +47 55 > 95 91 00 > e-mail: Roger.Bivand at nhh.no > > > > > _______________________________________________ > Rspatial-devel mailing list > Rspatial-devel at lists.r-forge.r-project.org > https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rspatial-devel > -- Edzer Pebesma Institute for Geoinformatics (ifgi), University of M?nster, Heisenbergstra?e 2, 48149 M?nster, Germany; +49 251 83 33081 Journal of Statistical Software: http://www.jstatsoft.org/ Computers & Geosciences: http://elsevier.com/locate/cageo/ Spatial Statistics Society http://www.spatialstatistics.info -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 490 bytes Desc: OpenPGP digital signature URL: From kent3737 at gmail.com Mon Dec 7 17:57:59 2015 From: kent3737 at gmail.com (Kent Johnson) Date: Mon, 7 Dec 2015 11:57:59 -0500 Subject: [Rspatial-devel] SpatialLinesDataFrame with z-axis In-Reply-To: References: Message-ID: One last post to follow up - I am using SpatialMultiPointsDataFrame and it is working; actually, it is pretty much what I was hoping to find. I posted a small patch to R-sig-geo which Edzer checked in. I also have a patch to the R leaflet package to make it work with SMPDF; I have given that to the leaflet devs. Thanks for your help and apologies for butting in here. Kent On Mon, Nov 30, 2015 at 10:04 PM, Kent Johnson wrote: > On Mon, Nov 30, 2015 at 2:44 AM, Roger Bivand wrote: > >> On Mon, 30 Nov 2015, Kent Johnson wrote: >> >> Hi, >>> >>> I am working with spatial line data which has three axes - lat, lon and >>> altitude and metadata for each line. I would love to have something like >>> a >>> SpatialLines3DDataFrame. >>> >> >> Why? Love isn't appropriate here - you need a use case. > > > OK. I would find it helpful to have a data structure to represent tracks > in three dimensions with associated metadata. My data is airplane tracks > from KML files and direct recording of flight data. Some useful operations: > - Plot the tracks on a map using leaflet. > - Find distance from each point in the track to a fixed point on the ground > - Plot distance from a fixed point vs altitude > - Find the point of closest approach to a fixed point on the ground > - Find the altitude at point of closest approach > - Associate attributes with each track such as flight number, departure > time, nearest waypoint, etc. > All of the above using collections of 200-300 tracks. > > Have you looked at SpatialMultiPoints (as altitude could be an attribute >> at a line segent end point, or a coordinate)? > > > SpatialMultiPointsDataFrame looks promising, thanks for the pointer. > >> >> Please use R-sig-geo for all contact - this list is only used by >> developers. >> > > OK I will use that list in the future. > > Kent > >> >> Roger >> >> >>> Thanks, >>> Kent Johnson >>> >>> >> -- >> Roger Bivand >> Department of Economics, Norwegian School of Economics, >> Helleveien 30, N-5045 Bergen, Norway. >> voice: +47 55 95 93 55; fax +47 55 95 91 00 >> e-mail: Roger.Bivand at nhh.no >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: