Select to view content in your preferred language

Raster into .tif format to use in R

1155
2
Jump to solution
05-23-2022 05:46 AM
Labels (2)
Deepa
by
Occasional Contributor

Hi,

 

I am using ArcMap 10.8 version. I exported raster into .tif format to work on it further in the R studio. The raster values ranges from 0 to 1 and there are no data in parts of the area outside county borders. It is a single band raster.

After importing the .tif file into R studio and plotting the raster shows that the values ranges from 0 to 255. Why is it like that? Also the Nodata values outside the county border also shows some high values. 

 

What did i do wrong and how can i fix this?

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
Deepa
by
Occasional Contributor

Yes Jeff, it was due to the way i exported the file as tiff format. I used the option under file  to export as tiff and the color mode options were only 4. So instead i used the export of the raster file directly from table of contents and then it worked well for me. The exported image had the same scale and no changes in color modes. Thanks for the suggestions here. 

View solution in original post

0 Kudos
2 Replies
JeffHouser
Frequent Contributor

This does not answer your question, but maybe it could be helpful info.  Also, I do not know if your observation is due to the raster itself or from the import into R-Studio.  Using two colors—In a binary image, each cell has a value of 0 or 1 and is often displayed using black and white. This type of display is often used for displaying scanned maps with simple line work, such as parcel maps.
Grayscale—In a grayscale image, each cell has a value from 0 to another number, such as 255 or 65535. These are often used for black-and-white aerial photographs.  

Above info: "https://desktop.arcgis.com/en/arcmap/latest/manage-data/raster-and-images/raster-bands.htm"

Again, only providing this as information.  I wish I could help more.

Jeff 

Deepa
by
Occasional Contributor

Yes Jeff, it was due to the way i exported the file as tiff format. I used the option under file  to export as tiff and the color mode options were only 4. So instead i used the export of the raster file directly from table of contents and then it worked well for me. The exported image had the same scale and no changes in color modes. Thanks for the suggestions here. 

0 Kudos