({{, (RefLink[DataRange, paclet:ref/DataRange]) 
is an option for functions such as (RefLink[ListPlot, paclet:ref/ListPlot]) and (RefLink[ListDensityPlot, paclet:ref/ListDensityPlot]) that specifies what range of actual coordinates the data should be assumed to occupy. }})

OpenersNotesSection(Spacer1)Details

For 1D data, a typical setting is (RefLink[DataRange, paclet:ref/DataRange])->{(Subscript[x, min]),(Subscript[x, max])}.

For 2D and higher-dimensional data, a typical setting is {{(Subscript[x, min]),(Subscript[x, max])},{(Subscript[y, min]),(Subscript[y, max])},…}.

For (RefLink[ArrayPlot, paclet:ref/ArrayPlot]), the settings for (RefLink[DataRange, paclet:ref/DataRange]) refer to the coordinates of the centers of each cell.

OpenersPrimaryExamplesSection(Spacer1)Examples  (2)

OpenersExampleSection0(Spacer1)Basic Examples  (2)

By default lists of y values are assumed to have integer x values:

data=Table[Sin[x],{x,0,10,0.1}];

ListPlot[data]

Use (RefLink[DataRange, paclet:ref/DataRange]) to specify a different range of x values:

ListPlot[data,DataRange->{0,10}]

Specify the x,y coordinate range for tabular data:

data=Table[Sin[x+y^2],{x,-2,2,0.1},{y,-2,2,0.1}];

ListPlot3D[data,DataRange->{{-2,2},{-2,2}}]

ListContourPlot[data,DataRange->{{-2,2},{-2,2}}]

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[Full, paclet:ref/Full])  ▪  (RefLink[PlotRange, paclet:ref/PlotRange])  ▪  (RefLink[DataReversed, paclet:ref/DataReversed])  ▪  (RefLink[LayerSizeFunction, paclet:ref/LayerSizeFunction])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Plotting and Image Regions, paclet:guide/PlottingAndImageRegions])}, {▪(RefLinkPlain[Plotting Options, paclet:guide/PlottingOptions])}, {▪(RefLinkPlain[Graphics Coordinates, paclet:guide/GraphicsCoordinates])}})}})