如何从二进制文件中将数据提取为栅格

时间:2020-02-18 07:43:06

标签: r binary binaryfiles grib ncdf4

我有二进制文件,并且其控制文件在图Control File中提供。我想提取经纬度的雨作为r中的栅格。有人可以帮忙吗?

    library(weathercan)
    library(rNOMADS)
    library(rgdal)
    library(raster)
    library(ncdf4)
    library(fields)
    library(sp)
    library(sf)
    library(gdalUtilities)
    library(rgdal)      
    library(tiff)
    library(ncdf4)
    library(gdalUtils)
    library(maps)
    library(maptools)
    library(ncdf.tools)
    library(ncdfgeom)
    library(rgl)
    library(rlas)
    library(AnnotationDbi)
    library(SDMTools)

    zz <- file("C:/Users/Administrator/Desktop/PRCP_CU_GAUGE_V1.0GLB_0.50deg.lnx.20090101.RT", "rb")
    zz
    summary(zz)

输出为

zz <-file("C:/Users/Administrator/Desktop/PRCP_CU_GAUGE_V1.0GLB_0.50deg.lnx.20090101", "rb")
zz
A connection with                                                                                       
description "C:/Users/Administrator/Desktop/PRCP_CU_GAUGE_V1.0GLB_0.50deg.lnx.20090101"
class       "file"                                                                     
mode        "rb"                                                                       
text        "binary"                                                                   
opened      "opened"                                                                   
can read    "yes"                                                                      
can write   "no"                                                                       

1 个答案:

答案 0 :(得分:0)