Make OPeNDAP Raster Layer (Multidimension)

Summary

Creates a raster layer from data stored on an OPeNDAP server.

Usage

  • The performance of this tool depends on the speed of the remote OPeNDAP server and the robustness of the Internet connection between the machine executing the tool and the remote server.

  • To create a raster layer, the spacing of the x-coordinates must be equal and the spacing between the y-coordinates of the remote data must be equal. This is often referred to as regularly gridded data.

  • Use the Cell registration parameter (cell_registration in Python) to determine how the extent of the netCDF raster layer is computed from the X Dimension and Y Dimension values. The cell size, number of rows, number of columns, and the width and height of the output raster remain the same, regardless of the option used.

Syntax

MakeOPeNDAPRasterLayer(in_opendap_URL, variable, x_dimension, y_dimension, out_raster_layer, {extent}, {dimension_values}, {value_selection_method}, {cell_registration})
ParameterExplanationData Type
in_opendap_URL

The URL that references the remote OPeNDAP dataset. The URL should resolve to the dataset level (for example, file name), not a directory name.

File; String
variable

The variable from the OPeNDAP dataset that will be used to create the raster layer.

String
x_dimension

The dimension of the OPeNDAP dataset used to define the x, or longitude, coordinates of the output raster layer.

String
y_dimension

The dimension of the OPeNDAP dataset used to define the y, or latitude, coordinates of the output raster layer.

String
out_raster_layer

The name of the output raster layer.

Raster Layer
extent
(Optional)

The output extent of the raster layer. Specify the extent coordinates in the units of the OPeNDAP data source (these could be latitude-longitude, projected coordinates, or some arbitrary grid coordinates). The purpose of this parameter is to allow subsetting to an area of interest or to reduce the size of the data that is transferred.

Envelope
dimension_values
[[dimension, {start_value}, {end_value}],...]
(Optional)

The starting and ending values of the dimensions or dimensions used to constrain which data will be extracted from the remote OPeNDAP server. By default, the minimum and maximum values of the dimension or dimensions will be used.

  • dimension—A netCDF dimension.
  • {start_value}—The start value to use for the specified dimension.
  • {end_value}—The end value to use.
Value Table
value_selection_method
(Optional)

Specifies the dimension value selection method.

  • BY_VALUEThe input value is matched with the actual dimension value.
  • BY_INDEXThe input value is matched with the position or index of a dimension value. The index is 0 based; that is, the position starts at 0.
String
cell_registration
(Optional)

Specifies how the cells will be registered with respect to the XY coordinate.

  • CENTERThe XY coordinate represents the center of the cell. This is the default.
  • LOWER_LEFTThe XY coordinate represents the lower left of the cell.
  • UPPER_LEFTThe XY coordinate represents the upper left of the cell.
String

Code sample

MakeOPeNDAPRasterLayer example 1 (Python window)

Creates an OPeNDAP raster layer.

import arcpy
arcpy.md.MakeOPeNDAPRasterLayer("http://cida.usgs.gov/thredds/dodsC/new_gmo", 
				"pr", "longitude", "latitude", "pr_Layer", 
				"-124.6875 25.1875 -67.0625 52.8125", 
				"time '01/01/1949 12:00:00 AM' '12/31/2010 12:00:00 AM'", "BY_VALUE")
MakeOPeNDAPRasterLayer example 2 (stand-alone script)

Creates an OPeNDAP raster layer.

# Name: MakeOPeNDAPRasterLayer_Ex_02.py
# Description: Create an OPeNDAP raster layer from a netCDF file.
# Requirements: None

# Import system modules
import arcpy


# Set local variables
in_opendap_URL = "http://cida.usgs.gov/thredds/dodsC/new_gmo"
variable = "pr"
XDimension = "longitude"
YDimension = "latitude"
outRasterLayer = "pr_Layer"
extent = "-124.6875 25.1875 -67.0625 52.8125"
dimensionValues = "time '01/01/1949 12:00:00 AM' '12/31/2010 12:00:00 AM'"
valueSelectionMethod = "BY_VALUE"
cellRegistration = ""

# Execute MakeNetCDFRasterLayer
arcpy.MakeOPeNDAPRasterLayer_md(in_opendap_URL, variable, XDimension, YDimension,
                               outRasterLayer, extent, dimensionValues, 
                               valueSelectionMethod, cellRegistration)

Environments

This tool does not use any geoprocessing environments.

Licensing information

  • Basic: Yes
  • Standard: Yes
  • Advanced: Yes

Related topics