search for: datacarpentri

Displaying 7 results from an estimated 7 matches for "datacarpentri".

Did you mean: datacarpentry
2018 Jan 15
0
Steps to create spatial plots
You will need to coerce your data into a "spatial" kind, as implemented in `sp` or as of late, `sf` packages. You might want to give the vignettes a whirl before you proceed. Roughly, you will have to coerce the data to Spatial* (you could go for a point, raster or grid type, I think) and also specify the projection. Once you have that, plotting should be handled by packages. Here are a
2018 Jan 15
4
Steps to create spatial plots
Hi users, I have no clear clue about plotting spatial data. For example, I just have a table with attribute values of each grid cell, such as elevation. Then I have coordinates of the upper left corner in UTM, the number of rows and columns, and grid cell size. How to create spatial plot of elevations for the grid cells, in color ramp? Should I create a spatial grid layer with all the polygons
2018 Jan 16
3
Steps to create spatial plots
Hi Roman, Thanks for your reply. For the spatial coordinates layer, I just have coordinates of the upper left corner, numbers of rows and columns of the spatial map, and grid cell size. How to create a spatial layer of coordinates from this data? Thanks. On Mon, Jan 15, 2018 at 3:26 PM, Roman Lu?trik <roman.lustrik at gmail.com> wrote: > You will need to coerce your data into a
2018 Jan 16
0
Steps to create spatial plots
>From your description, I am **guessing** that you may not want a "spatial map" (including projections) at all, but rather something like a level plot. See ?levelplot in the lattice package for details. Both I am sure ggplot2 has something similar. Apologies if I havemisunderstood your intent/specifications. Cheers, Bert Bert Gunter "The trouble with having an open mind is
2018 Jan 16
2
Steps to create spatial plots
Hi Bert, I think you are correct that I can use levelplot, but I have a question about converting data. For example, the statement: levelplot(Z~X*Y), Z is row-wise from the lower left corner to the upper right corner. My dataset just have gridded Z data as a txt file (or can be called matrix?), how to convert them to the vector in order for levelplot to use? Thanks. On Mon, Jan 15, 2018 at 6:04
2018 Jan 16
0
Steps to create spatial plots
Sorry for the emails, I just wanted to have an example. layer$z 1 1 3 4 6 2 2 3 4 1 2 9 1 4 5 2 1 8 How to convert the matrix to layer$z = c(1, 4, 5, 2, 1, 8, 2, 3, 4, 1, 2, 9, 1, 1, 3, 4, 6, 2)? I think this vector is the order that levelplot can use. Thanks again. On Mon, Jan 15, 2018 at 10:58 PM, lily li <chocold12 at gmail.com> wrote: > Hi Bert, > > I think
2018 Jan 16
1
Steps to create spatial plots
If layer$z is a matrix and you want to reverse the order of the rows, you can do: n <- nrow(layer$z) layer$z <- layer$z[ n:1, ] HTH, Eric On Tue, Jan 16, 2018 at 8:43 AM, lily li <chocold12 at gmail.com> wrote: > Sorry for the emails, I just wanted to have an example. > layer$z > > 1 1 3 4 6 2 > 2 3 4 1 2 9 > 1 4 5 2 1 8 > > How to convert