我想在 Ubuntu 中使用 R 包 RNetCDF 和 ncdf。
当我尝试install.packages('RNetCDF')
orinstall.packages('ncdf')
时,我收到类似的错误:
...
ncdf.c:3:20: fatal error: netcdf.h: No such file or directory
compilation terminated.
make: *** [ncdf.o] Error 1
ERROR: compilation failed for package ‘ncdf’
...
Warning message:
In install.packages("ncdf") :
installation of package ‘ncdf’ had non-zero exit status
安装包libnetcdf6
和netcdf-bin
来自 Ubuntu 存储库。我需要做其他事情吗?