Learn R Programming

GriegSmith (version 1.0)

addem: addem

Description

Used by GriegSmith function

Usage

addem(startingvals, xmatlen, ymatlen, data)

Arguments

startingvals
xmatlen
ymatlen
data

Value

    Examples

    Run this code
    ## The function is currently defined as
    function(startingvals,xmatlen,ymatlen,data){
    
    	x<-startingvals[1];
    	y<-startingvals[2];
    
    
    	#print("here");
    	#print(data[x:(x+xmatlen-1),y:(y+ymatlen-1)]);
    
    	sum(data[x:(x+xmatlen-1),y:(y+ymatlen-1)])^2;
    
    
    
    
      }

    Run the code above in your browser using DataLab