spacial analysis

Upload: kelik-s

Post on 01-Mar-2018

223 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/26/2019 Spacial Analysis

    1/36

    EXTRACTION

  • 7/26/2019 Spacial Analysis

    2/36

    An overview of the Extraction tools

    The Extraction tools allow you to extract a subset of cells from a raster byeither the cells attributes or their spatial location. You can also obtain thecell values for specic locations as an attribute in a point feature class oras a table.The tools that extract cell values based on their attribute or location to anew raster include the following:

    Extracting cells by attribute value (Extract by ttributes! isaccomplished through a

    where clause. "or example# your analysis may re$uire an extraction ofcells higher

    than %&& meters in elevation from an elevation raster.Extracting cells by the geometry of their spatial location re$uires thatgroups of cells

    meeting a criteria of falling within or outside a specied geometricshape (Extract by

    'ircle# Extract by olygon# Extract by )ectangle!.Extracting cells by specic locations re$uires that you identify thoselocations either

    by their x#y point locations (Extract by oints! or through cellsidentied using a

    mas* raster (Extract by +as*!.

  • 7/26/2019 Spacial Analysis

    3/36

    The tools that allow you to specify the locations for which to extract cellvalues to an attribute table or a regular table include the following:

    'ell values identied by a point feature class can be recorded as anattribute of a new output feature class (Extract ,alues to oints!. This will only extract thevalues fromone input raster.'ell values identied by a point feature class can be appended to the

    attribute table

    of that feature class (Extract +ulti ,alues to oints!. 'ell values frommultiplerasters can also be identied.The cell values for identied locations (both raster and feature! can be

    recorded in atable (-ample!.

  • 7/26/2019 Spacial Analysis

    4/36

    The following table lists the available Extraction tools and provides abrief description of each.

    Tool Description

    Extract byAttributes Extracts the cells of a raster based on a logical query.

    Extract by Circle Extracts the cells of a raster based on a circle.

    Extract by Mask Extracts the cells of a raster that correspond to the areas defined by a mask.

    Extract by Points Extracts the cells of a raster based on a set of coordinate points.

    Extract byPolygon

    Extracts the cells of a raster based on a polygon.

    Extract byRectangle

    Extracts the cells of a raster based on a rectangle.

    Extract MultiValues to Points Extracts cell alues at locations specified in a point feature class from one or morerasters! and records the alues to the attribute table of the point feature class.

    Extract Values toPoints

    Extracts the cell alues of a raster based on a set of point features andrecords the alues in the attribute table of an output feature class.

    "ampleCreates a table that sho#s the alues of cells from a raster! or set ofrasters! for defined locations. $he locations are defined by raster cellsor by a set of points.

  • 7/26/2019 Spacial Analysis

    5/36

    Extracting cell values to point features

    The cell values from raster data can be extracted directly to the

    attributes of point feature data. This can be done in two wayseither bycreating a new feature output or by appending the values to the existingpoint feature class.

    Extracting cell values to a new point feature dataset

    /ith the Extract ,alues to oints tool# you can use a point feature datasetto dene the

    locations for which you want to extract the cell values from a singleraster. These values will be recorded to the attribute table of the featuredataset.Appending cell values from rasters to a existing point feature dataset

    /ith the Extract +ulti ,alues to oints tool# you can use a point featuredataset to dene the locations from one or many rasters you want to

    extract the cell values from.

  • 7/26/2019 Spacial Analysis

    6/36

    The di0erences between this tool and Extract ,alues to oints are thefollowing:

    This tool 1ust appends the cell values to the attribute table of theinput feature

    dataset. 2t does not create a new feature dataset.This tool 1ust appends the cell values to the attribute table of theinput feature

    dataset. 2t does not create a new feature dataset.-upports multi3band raster dataset input.

    Related Topics

    n overview of the Extraction toolsExtract +ulti ,alues to ointsExtract ,alues to oints

  • 7/26/2019 Spacial Analysis

    7/36

    Extraction ! attriute" shape" or location

    subset of cells can be extracted into a new raster in several waysby aselecting an attribute or a dened shape or by using another raster.

    Extraction ! attriute

    'ells that meet a specied attribute $uery can be extracted to a newoutput raster with the Extract by ttributes tool.

    Examples of applications for this tool include the extraction of all cells

    that have a slopegreater than %& percent or the extraction of all cells attributed with4oning for commercial development. ll cells that meet the $uery willreturn# for the cell location# the original value that was $ueried.The cells that meet the specied $uery do not have to be contiguous.

    Extraction ! shapesYou can extract cells based on a specied shape. You have the option toextract only the cells that fall inside or outside the shape. You canextract by a circle# rectangle# or polygon.

  • 7/26/2019 Spacial Analysis

    8/36

    ircular area extraction

    To perform a circular extraction# use the Extract by'ircle tool.The location of the center of the circle and the radius must be specied.

    2n the image below# all cells (cell centers! that fall within the circleare extracted:

    ectangular area extraction

    To perform a rectangular extraction# use the Extract by )ectangle tool.

    The lower left and upper right corners of the rectangle must be identied.

    2n the image below# the cells inside the specied rectangular shape wereextracted.

  • 7/26/2019 Spacial Analysis

    9/36

    olygonal area extraction

    To perform an extraction based on a polygonal shape# use the Extract byolygon tool.The location of the vertices of the polygon must be

    input.2n the image below# an extraction polygon was identied# but aparameter was specied to extract the cells outside rather than insidethe polygon.

    Extraction ! location

    'ells can be extracted based on their spatial location. The cells toextract can be determined by individual point locations or from a groupof locations of any si4e or shape as identied by a mas*.

  • 7/26/2019 Spacial Analysis

    10/36

    Point location extraction

    You can extract particular cells from a raster by dening a list of thecoordinate points you are interested in.

    To perform an extraction based on points# use the Extract by oints tool.The points must be identied by their x#y coordinatelocations.

    xtractions with a mask

    nother dataset# the mas*# can be used to identify the cells that will be

    extracted to a new raster. The mas* can be either a raster or a featuredataset.To perform this type of extraction# use the Extract by+as* tool.There are a number of ways to create a mas* raster using various rc52--patial nalyst tools.

    2n the extraction tool# as demonstrated in the image below# thoselocations that are not6o7ata in a mas* raster will retain the value assigned to that location inthe Input raster.

  • 7/26/2019 Spacial Analysis

    11/36

    feature dataset can be used for the mas*. 8nly cells that fall withinthe specied shape of the feature data will receive the values of theInput raster on the output raster.

  • 7/26/2019 Spacial Analysis

    12/36

    #ENERA$I%ATION

  • 7/26/2019 Spacial Analysis

    13/36

    Altering the resolution of a raster

    There are tools available that alter the resolution of an existing raster. 2fyou have one raster at a ner resolution than other rasters# you may

    want to resample the ner resolution raster to the same resolution of thecoarser ones# ma*ing all the raster datasets the same resolution. Thisspeeds up processing and reduces data si4e. 9nli*e the 'ell si4e settingin the analysis environment# the resolution altering tools are applied onlyto the resultant raster. The top graphic shows a raster of an area at a neresolution# while the graphic immediately below it shows a raster of the

    same area with a coarser resolution.

    Raster of an area at a ne resolution Raster of an area at a coarse resolution

    The two principal ways to determine resulting values when changing theresolution of a raster dataset are interpolation and aggregation.

  • 7/26/2019 Spacial Analysis

    14/36

    Interpolation

    The interpolation method is used by the )esample tool in the )astertoolset of the 7ata +anagement toolbox. 2t uses either the nearestneighbor# bilinear# cubic interpolation# or ma1ority resampling methods

    on the values of the input raster.

    Aggregation

    The aggregation method uses a specied statistical aggregation methodwithin aneighborhood to derive values in the output raster at the di0erent

    resolution. This method is used by the ggregate and loc* -tatistics-patial nalyst tools. ggregate/ith this tool# -patial nalyst aggregates a group ofcells to the same

    value to produce a single# coarser resolution cell. The types ofstatistics available

    to aggregate the input values are -um# +in# +ax# +ean# and

    +edian.

    loc* -tatistics/ith this tool# -patial nalyst calculates a speciedstatistic within

    non3overlapping neighborhoods.The main di0erence between them is that there is no concept of aneighborhood inggregate as there is in loc* -tatistics# since the would3beneighborhood and output bloc*s are always s$uare# and the si4e of thewould3be neighborhood is a function of the aggregation of cells that is

    necessary to obtain the desired resolution.

  • 7/26/2019 Spacial Analysis

    15/36

    An overview of the #enerali&ation toolset

    The generali4ation analysis tools are used to either clean up smallerroneous data in the raster or generali4e the data to get rid of

    unnecessary detail for a more general analysis.There are several common sources for the erroneous data# such as thefollowing: 'lassied satellite imagery may contain many small areas ofmisclassied cells. 2mages that are scanned paper maps may contain unnecessary linesor text. 'onversion issues from rasters in di0erent formats# resolutions# or

    pro1ections mayexist.

    The generali4ation tools help you identify such areas and automate theassignment of more reliable values to the cells that ma*e up the areas.

    The generali4ation tools are divided into three general categories:

    Those that generali4e on 4ones. (6ibble# -hrin*# Expand# )egion 5roup# and Thin!

    Those that smooth 4one edges. (oundary 'lean and +a1ority "ilter!

    Those that alter the resolution of the data. (ggregate!

  • 7/26/2019 Spacial Analysis

    16/36

    The following table lists the available 5enerali4ation tools# and provides abrief description of each.

    Tool Description

    Aggregate%enerates a reduced&resolution ersion of a raster. Each output cell containsthe "um! Minimum! Maximum! Mean! or Median of the input cells that areencompassed by the extent of that cell.

    'oundaryClean

    "moothes the boundary bet#een (ones by expanding and shrinking it.

    Expand Expands specified (ones of a raster by a specified number of cells.

    Ma)ority*ilter

    Replaces cells in a raster based on the ma)ority of their contiguousneighboring cells.

    +ibbleReplaces cells of a raster corresponding to a mask #ith the alues of thenearest neighbors.

    Region%roup *or each cell in the output! the identity of the connected region to #hichthat cell belongs is recorded. A unique number is assigned to each region.

    "hrink"hrinks the selected (ones by a specified number of cells by replacing them

    #ith the alue of the cell that is most frequent in its neighborhood.

    $hin$hins rasteri(ed linear features by reducing the number of cells representingthe #idth of the features.

  • 7/26/2019 Spacial Analysis

    17/36

    Creating individual &ones with Region #roup 4one is composed of all cells in a raster with the same value. )egionsare a contiguous set of cells of the same 4one type. ;ones can consist ofseveral disconnected regions. /hen the regions need to be processedseparately# each must be identied as a separate entity. The )egion5roup tool assigns a new value to each region in a raster. The values areassigned by the scanning process# which starts in the upper3left corner ofthe raster and moves left to right# top to bottom. s each new region isencountered# a uni$ue value is assigned to it. The process continues until

    all regions have been assigned a value.

    Several disconnected regionsexist within

    zones before Region Group.

    Each region (disconnectedzone) isassigned a unique zone valueafterRegion Group.

    2n the output raster

  • 7/26/2019 Spacial Analysis

    18/36

    #enerali&ation of classified raster imager!8ne of the most common applications of the 5enerali4ation tools is theprocess of cleaning up a classied image that was derived from remote3sensing software. The classication process often results in many

    isolated small 4ones of data that are either misclassied or irrelevant tothe analysis.

    Creating a generalized land-use map from asatellite image

    The following example demonstrates a typical se$uence of applying the

    generali4ation tools to produce a raster layer that is more suitable forpresentation or subse$uent analysis.

    Each tool can be used alone or in combination with other data cleanuptools for various applications.

  • 7/26/2019 Spacial Analysis

    19/36

    tarting with a raw satellite scene

    The image below shows the raw satellite image that will be classied./hile the classication process will not be explicitly described# thefollowing section will detail some of the reasons that the direct result

    typically needs some further processing to be generally useful.

    Raw iage to be generalized

  • 7/26/2019 Spacial Analysis

    20/36

    Image result after classi!cation

    satellite image. The training samples are ta*en in di0erent land usesto identify water# residential# hardwoods# conifers# and so on. "romthese training samples# all other cell locations in the image are

    allocated to one of these *nown land types or uses. -ometimes land3use signatures (statistics derived from the training samples! aresimilar# ma*ing it di>cult to distinguish between two classes. "orexample# with the existing training samples# the software may not beable to distinguish between an alder swamp and a wetland withhardwoods. This may be due to an inade$uate number of trainingsamples or the fact that certain land uses were never sampled at all.These limitations# as well as others# can lead to the misclassicationof certain locations.s a result# a single or a small group of cells may be misclassied asan entity di0erent from the sea of cells surrounding it# when inreality# the entity belongs to the group of cells that surrounds it.nother typical area of misclassication is the boundaries between

    di0erent land uses. 8ften# what results is a 1agged# unrealisticrepresentation of the boundary that can be smoothed with thegenerali4ation tools.elow is the classication of the satellite image. 6otice there aremany small# isolated single cells or groups of cells throughout theimage.

  • 7/26/2019 Spacial Analysis

    21/36

    The following sections demonstrate how the generali4ation tools can beapplied to produce a nal classied raster.

  • 7/26/2019 Spacial Analysis

    22/36

    Remo"ing misclassi!ed cells with #a$ority %ilter

    To remove the single# misclassied cells in the classied image# the+a1ority "ilter tool is applied. The results are displayed in the imagebelow. 6otice that many of the smaller groups of cells have

    disappeared.

    Raster after !a"orit# $ilter applied

  • 7/26/2019 Spacial Analysis

    23/36

    moothing zones with &oundaryCleanTo smooth the boundaries between 4ones# the oundary 'lean tool

    can be implemented. y expanding and shrin*ing the boundaries# thelarger 4ones will invade smaller 4ones# as is the case in the image

    below. gain# notice that even more of the smaller and thinnergroups of cells have disappeared.

    Raster after %oundar# &lean applied

  • 7/26/2019 Spacial Analysis

    24/36

    Identifying clusters with Region'roup

    The +a1ority "ilter and oundary 'lean tools will only process out thesingle or very small clusters of a few misclassied cells by assigningthem to the value that appears most fre$uently in the immediateneighborhood. -uppose# however# that there is a certain si4ethreshold below which individual groupings of li*e cells are consideredtoo small to be meaningful in the ensuing analysis. These clustersshould instead be dissolved into the surrounding groups. "or example#any contiguous clusters of the same land3use category that are

    smaller than ?#@&& s$uare meters in si4e are deemed not signicantto the analysis. Aowever# these isolated regions cannot be individuallyprocessed# since they have the same land3use value as the entire4one.To resolve this issue# the )egion 5roup tool is applied. This tool willassign a uni$ueidentier to each region in the input raster (the classied image!.

    region is any contiguous group of cells of the same value. 'onsider asingle 4one composed of two regions that are not connected. )egion5roup will divide this 4one into two new 4ones# each having a uni$ueidentication (4one! value. The original 4one value is maintained as a=26B eld in the output attribute table. The resulting raster is shownbelow and displays the many di0erent output 4ones.

  • 7/26/2019 Spacial Analysis

    25/36

    Raster after Region Group applied

  • 7/26/2019 Spacial Analysis

    26/36

    Remo"e areas smaller than threshold

    6ext# using a selection tool# such as the Extract by ttributes tool inthe Extraction toolbox# an output raster is created where regionssmaller than the area threshold have been removed.

    'er# s all regions selected and reoved to use as a!as

  • 7/26/2019 Spacial Analysis

    27/36

    liminating small regions with (i))le

    9sing the 6ibble tool on the resultant raster from the extraction tool(identifying the regions to eliminate! and with the values from theclassied image raster# the tool visits each cell location to eliminate

    and replaces it with the closest cell with a value on the classiedraster.

    Sall regions identied in the as eliinated withibble

  • 7/26/2019 Spacial Analysis

    28/36

    %inal generalized land-use map

    9sing the lin* item from the results of the )egion 5roup tool# theoriginal 4one values from the classied image are reassigned to theindividual regions created from the )egion 5roup tool.

    $inal generalized land*use ap

    The result is a more generali4ed land3use map# which can be used in

    subse$uent analyses.

  • 7/26/2019 Spacial Analysis

    29/36

    #enerali&ing &ones with Nile" 'hrin(" and Expand-patial nalyst tools that generali4e 4ones include 6ibble# -hrin*#and Expand.

    (i))leThe 6ibble tool allows selected areas of a raster to be assigned thevalue of their nearest neighbor. This is useful for editing areas of araster where the data is *nown to be erroneous.

    "irst# the algorithm determines all areas from the mas* raster with the

    value 6o7ata. The corresponding areas on the input raster will benibbled. -econd# an internal Euclidean allocation is performed toallocate values to the mas*ed cells based on Euclidean distance.

    The value of the cells from the input raster that correspond to the cellsof 6o7ata from the mas* raster are nibbled and replaced by the valueof the nearest neighbor according to Euclidean distance.

  • 7/26/2019 Spacial Analysis

    30/36

    2n the following image# 6ibble was applied to the input and mas*rasters. 6ibble will only be applied to the 6o7ata values in the mas*raster. 6otice all non36o7ata cells on the mas* raster receive the valuefrom the input raster. These cell values and their locations will be usedto assign values to the 6o7ata locations identied on the mas* raster.The 6o7ata locations will receive the value of the cell in the inputraster that is identied as the closest non36o7ata cell on the mas*raster.

    +utRas , ibble(-nRas/ !as0Ras)

    hrink

    The -hrin* tool shrin*s specied 4ones by replacing them with thevalue of the cell that is most fre$uent in its neighborhood. 2n -hrin*#the values of spurious cells along 4onal boundaries are changed to thevalue of their highest fre$uency neighbor. ny cells that are notinternal cells (those that cannot be viewed as a center to eight nearest

    neighbors of the same value! may be replaced.

  • 7/26/2019 Spacial Analysis

    31/36

    "or example# a region that is @ cells wide and %& cells long will beremoved# since it will shrin* by one cell from two di0erentdirections. 2f you shrin* by two cells# the smallest si4e region thatcan be retained is a C3by3C bloc* of cells.

    /hen you shrin* by more than one cell# conceptually# it is li*erunning the tool as many times as the number of cells to shrin* withthe results of the previous run being the input to the subse$uentiteration."or example# if you shrin* by two cells# conceptually# it is li*erunning -hrin* by one cell on the input raster and shrin*ing the

    identied 4ones and using the output of the rst shrin* as the inputfor the second shrin*ing.

    2n the image below# -hrin* is applied to the input raster# so 4one Cshrin*s by one cell. ;one C is no more than two cells wide in anyareaD therefore# all cells containing C are replaced with the value ofhighest fre$uency in its neighborhood. 6o7ata invades two locations

    at the bottom right# since it is the value of highest fre$uency to thetwo locations.

  • 7/26/2019 Spacial Analysis

    32/36

    +utRas , Shrin(-nRas/ / 123)

    2n the image below# -hrin* is applied to the input raster# so 4ones and F shrin* by one cell. 2n the upper left corner# a value remains#

    since it is deeper than one cell.

    +utRas , Shrin(-nRas/ / 123)

  • 7/26/2019 Spacial Analysis

    33/36

    Expand

    /ith the Expand tool# certain 4ones can expand into other 4ones.'onceptually# selected values can be viewed as foreground 4ones#

    while others remain bac*ground 4ones. The foreground 4ones canexpand into the bac*ground 4ones.2n the image below# the Expand tool is applied to the input rasterwith 4one C expanding one cell. 6otice that 4one C expanded intothe 6o7ata values in the lower right.

    +utRas , Expand(-nRas/ / 123)

    ) A t (

  • 7/26/2019 Spacial Analysis

    34/36

    )ow Aggregate wor(s

    The ggregate tool resamples an input raster to a coarser resolutionbased on a specied aggregation strategy (-um# +in# +ax# +ean# or+edian!.

    'onceptually# the tool wor*s as follows:

    %. 2t multiplies the cell resolution of the input raster by the factorspecied by the cell factor parameter. The resulting valuecorresponds to the cell resolution of the output raster.

    @. 2t maps the spatial extent of the output cells onto the input

    raster.

    4he coarser output cells apped onto the input raster

  • 7/26/2019 Spacial Analysis

    35/36

    G. 2t identies the cells on which to perform the aggregationcalculations. 'ell

    locations from the input raster that fall within the extent of anoutput cell are

    included in the calculations for determining that cell

  • 7/26/2019 Spacial Analysis

    36/36

    4he input raster 4he coarser output cells cover a larger extent thanthe inputcells.

    +utput with the Expand option set +utput with the 4runcate option set