diff --git a/README.md b/README.md index 48af736..3199616 100644 --- a/README.md +++ b/README.md @@ -28,15 +28,16 @@ which will read the variable called "Radiation" from the file "myfile.nc". Gener which gives an overview of the dimensions, variables and attributes stored in the file. - filename = "myfile.nc" - varname = "var1" - attribs = {"units" => "mm/d", - "data_min" => 0.0, - "data_max" => 87.0} + filename = "myfile.nc" + varname = "var1" + attribs = Dict("units" => "mm/d", + "data_min" => 0.0, + "data_max" => 87.0) + Creating variables and files is done by using the nccreate command: - nccreate(filename, varname, "x1", 11:20, "t", 20, {"units"=>"s"}, atts=attribs) + nccreate(filename, varname, "x1", collect(11:20), "t", 20, Dict("units"=>"s"), atts=attribs) This will create the variable called var1 in the file myfile.nc. The attributes defined in the Dict attribs are written to the file and are associated with the newly created variable. The dimensions "x1" and "t" of the variable are called "x1" and "t" in this example. If the dimensions do not exist yet in the file,