[R] extract function extracting only NA values
fabe at dmu.dk
Wed Apr 24 16:30:18 CEST 2013
ok so i imported the raster as a dataframe and everything is fine
so it's something with values lower than -9999 that are interpreted as
NA by the raster function
On 4/24/2013 13:52, Fabio Berzaghi wrote:
> So I think I might have found what is causing this problem. The values
> I have in this raster
> > summary(ps0011yme)
> Min. -9458.911
> 1st Qu. 1955256.000
> Median 10618870.000
> 3rd Qu. 79577730.000
> Max. 167780500.000
> NA's 0.000
> From ArcMap though I get different values
> min -69826224 and max 167780496
> So maybe when I am importing the rest are in R something goes wrong
> and all the values below a certain threshold are considered NA. Is
> this a bug or do I get to use a specific parameter for the raster
> On 4/24/2013 13:10, Fabio Berzaghi wrote:
>> I have five raster files in ASCII format. With four of them I have no
>> problem extracting values based on a set of X and Y coordinates.
>> Unfortunately with one of the files all I managed to extract is NA
>> values. To verify the problem I have opened the raster with ArcMap
>> and there are no NA values where I am extracting. I have also plotted
>> the spatial point class on top of the raster in R and it does
>> correspond to the correct locations.
>> These are some of the commands I am using, and as I already pointed
>> out that works perfectly with other raster files.
>> Can anyone help? At this point I am rather clueless about this.
>> R-help at r-project.org mailing list
>> PLEASE do read the posting guide
>> and provide commented, minimal, self-contained, reproducible code.
> R-help at r-project.org mailing list
> PLEASE do read the posting guide
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help