split: logical. If TRUE each layer of x is treated as a sub-dataset
atts: character. A vector of additional global attributes to write. The must be formatted like c("x=a value", "y=abc")
gridmap: character. The crs is always written to the file in standard formats. With this argument you can also write the format commonly used in netcdf files. Something like c("grid_mapping_name=lambert_azimuthal_equal_area","longitude_of_projection_origin=10","latitude_of_projection_origin=52", "false_easting=4321000","false_northing=3210000")
overwrite: logical. If TRUE, filename is overwritten
zname: character. The name of the "time" dimension
prec: character. One of "double", "float", "integer", "short", "byte" or "char"
compression: Can be set to an integer between 1 (least compression) and 9 (most compression)
missval: numeric, the number used to indicate missing values
...: additional arguments passed on to the SpatRasterDataset method, and from there possibly to ncvar_def