How to read file geodatabase with Binary field in R?
Short version: how can I get into R the dataset available at this link? (you need to log in to download, but registration is free)
The dataset that is downloadable at that link expands to a directory; as pointed out in the comments, this is an ESRI file geodatabase, and the important stuff is in a subdirectory. The format was reverse engineered and is readable by GDAL:
$ ogrinfo eschscholzia_minutiflora_twisselmannii/data/v93/tempgdb.gdb Had to open data source read-only. INFO: Open of 'eschscholzia_minutiflora_twisselmannii/data/v93/tempgdb.gdb' using driver 'OpenFileGDB' successful. 1: Eschscholzia_minutiflora_ssp_twisselmannii (Multi Polygon)
However, reading this into R results in:
x <-readOGR('eschscholzia_minutiflora_twisselmannii/data/v93/tempgdb.gdb', 'Eschscholzia_minutiflora_ssp_twisselmannii')
Error in readOGR("eschscholzia_minutiflora_twisselmannii/data/v93/tempgdb.gdb", : Unsupported field type: Binary
Another tack, using
ogr2ogr, produces a shapefile:
$ ogr2ogr --mapFieldType Binary=Integer test_output eschscholzia_minutiflora_twisselmannii/data/v93/tempgdb.gdb/ Warning 6: Normalized/laundered field name: 'FOOTPRINT_Length' to 'FOOTPRINT_' Warning 6: Normalized/laundered field name: 'FOOTPRINT_Area' to 'FOOTPRIN_1' Warning 1: Value 121687920 of field FOOTPRINT_ of feature 0 not successfully written. Possibly due to too larger number with respect to field width Warning 1: Value 925496867120400 of field FOOTPRIN_1 of feature 0 not successfully written. Possibly due to too larger number with respect to field width
but the resulting shapefile doesn't seem to have the information in it. Or, maybe I don't know the right way to read it into R?
Those data are rasters, and sadly (as of December 2015) it seems there's no way to read file geodatabase rasters with open source tools. The nice folk(s) who reverse-engineered the format haven't done rasters, and as described in this question, ESRI isn't helping. =(