Questions tagged [raster]

A rectangular array of pixels. A Raster defines values for pixels occupying a particular rectangular area of the plane, not necessarily including (0, 0).

A rectangular array of pixels. A Raster defines values for pixels occupying a particular rectangular area of the plane, not necessarily including (0, 0).

3658 questions
1
vote
1 answer

Using R to map seedling locations using set reference points

I'm looking for some guidance on the approach I should take to mapping some points with R. Earlier this year I went off to a forest to map the spatial distribution of some seedlings. I created a grid—every two meters I set down a flag with a…
1
vote
0 answers

QGIS How do I set the spatial resolution of a raster?

I have some files that started out as .hdf files and I have converted them to TIFFs after some destriping. These images have no spatial reference and have been defaulted to 1 pixel = 1 degree. This comes out to 111,319.419 meters per pixel. Can I…
Eric
  • 45
  • 5
1
vote
1 answer

How to create BufferedImage with a separate alpha raster

Motivation: My goal is to convert AWT BufferedImage to SWT ImageData in the most efficient way. Typical answer to this question is pixel by pixel conversion of the whole picture, that is O(n^2) complexity. Much more efficient would be if they could…
Espinosa
  • 2,491
  • 24
  • 28
1
vote
1 answer

Gettin values based on longitude on latitude from a SpatialPixelsDataFrame in R

I have several locations in longitude and latitude coordinates and I need to get an estimate of solar radiation for each location. I found data from NASA that has exactly this information in a 1 degree x 1 degree resolution. nasafile <-…
GabrielMontenegro
  • 683
  • 1
  • 6
  • 21
1
vote
1 answer

Iterating over a function to combine many raster stacks into one

Been stuck on this for a while now. Looked everywhere for an answer, but I can't seem to find anything on Stack. Any help you all can give that would be very appreciated. My main issue is that I need to import many, many netcdf4 files, create…
nate-m
  • 557
  • 3
  • 14
1
vote
1 answer

R How to multiply the values of the raster pixels with the true surfaces of these pixels?

I want to multiply the precipitation values (mm) of each pixel of a raster by the area corresponding to each of these pixels under R. At first, I directly multiplied the raster by the average pixel area (Total area / number of pixels). But if we…
tazrart
  • 167
  • 1
  • 15
1
vote
1 answer

Crop, change values, and merge rasters with overlapping extent

I am trying to take a raster of soils data for one state, crop it by county, change the cell values in each county (to the county fips code), and then re-merge the county rasters back into the state raster. Here I read in the state soils raster…
Kevin W
  • 33
  • 5
1
vote
2 answers

easiest way to rotate a PNG file 90 degrees within R

what's the most painless way to programmatically open a PNG file on my computer, rotate it 90 degrees, then save it as another PNG file - with no loss of quality and no other changes? it's a five-second task in microsoft paint but all of the…
Anthony Damico
  • 5,779
  • 7
  • 46
  • 77
1
vote
1 answer

How to download and unzip a raster zipped file directly in r from github

I am trying to download 'Landsat.rar` file (included 6 Landsat bands) and unzip it directly in r, but It doesn't work as I expected. Thank you for your…
Tuyen
  • 977
  • 1
  • 8
  • 23
1
vote
1 answer

Expand a netCDF Variable into an additional Dimension or multiple Variables

I am working with a very large netCDF file in three dimensions (lat/lon/time). The resolution is 300 meters and the time variable has 25 steps, which leads to 64800x129600x25 cells. The one variable contained in the file is an integer (ranging from…
1
vote
1 answer

Create and display a raster for Leaflet in R

I've been reading through the documentation, but not getting anywhere with this question. I have a data frame with three columns. The first two are gps coordinates, [such as 42.06, -70.19 for (Provincetown, Massachusetts, USA)], and the third column…
Heliornis
  • 391
  • 5
  • 18
1
vote
1 answer

Intersect grid with circles

I have the following problem. I have data from a canton of CH (Fribourg) and I would like to intersect 3 circles with a grid cell created in this area. Here is some code to generate the map attached and the polygon: data file…
Akis
  • 130
  • 1
  • 8
1
vote
2 answers

Remove assign value for NO data when calculating mean in raster stack

I have a time series of raster images read as a raster stack using raster package in R where each raster has the calculated value ranges from 0 - 100. However, when there is cloud cover those pixels are coded as 255. I want to calculate mean of the…
user2807119
  • 333
  • 3
  • 4
  • 11
1
vote
1 answer

Arrange odd number of plots using rasterVis and gridExtra

I am trying to plot a panel with seven rasters using the levelplot function of the rasterVis package, combined with gridExtra's grid.arrange. I almost get what I need by using the following code: # load required…
thiagoveloso
  • 2,537
  • 3
  • 28
  • 57
1
vote
0 answers

using wux for ensemble climate data

I am very new to R, and I am working with New England climate data. I am currently attempting to use the package WUX to find ensemble averages for each year of the mean, minimum, and maximum temperatures across all 29 climate models. In the end for…
M. Bow
  • 41
  • 5