本文整理汇总了Python中SSUtilities.assignClassAttr方法的典型用法代码示例。如果您正苦于以下问题:Python SSUtilities.assignClassAttr方法的具体用法?Python SSUtilities.assignClassAttr怎么用?Python SSUtilities.assignClassAttr使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SSUtilities
的用法示例。
在下文中一共展示了SSUtilities.assignClassAttr方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, varName, outputFC, wType,
weightsFile = None, concept = "EUCLIDEAN",
rowStandard = True, threshold = None,
exponent = 1.0, permutations = None,
applyFDR = False):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Assess Whether SWM File Being Used ####
self.swmFileBool = False
if weightsFile:
weightSuffix = weightsFile.split(".")[-1].lower()
self.swmFileBool = (weightSuffix == "swm")
#### Warn Inverse Distance if Geographic Coord System ####
#if wType in [0, 7]:
# WU.checkGeographicCoord(self.ssdo.spatialRefType,
# WU.wTypeDispatch[wType])
#### Create Shape File Boolean for NULL Values ####
self.outShapeFileBool = UTILS.isShapeFile(outputFC)
#### Initialize Data ####
self.initialize()
#### Construct Based on SWM File or On The Fly ####
self.construct()
示例2: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, allVarNames, numChoose, ssdo,
weightMatrix, weightsType = "SWM",
minR2 = .5, maxCoef = .01, maxVIF = 5.0,
minJB = .1, minMI = .1, silent = False):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Set Label ####
self.numVars = len(self.allVarNames)
self.label = ARCPY.GetIDMessage(84283).format(numChoose, self.numVars)
if numChoose <= 2:
self.eachAppears = 1
else:
self.eachAppears = nChooseK(self.numVars - 2, numChoose - 2)
#### Set Result Structures ####
self.varSignDict = {}
self.signDict = {}
self.vifDict = {}
for varName in self.allVarNames:
self.varSignDict[varName] = [0, 0]
self.signDict[varName] = [0, 0]
self.vifDict[varName] = [0, []]
self.olsResults = {}
self.bestR2Vals = []
self.bestR2Res = []
self.passTable = []
self.passBools = []
self.r2Residuals = NUM.empty((self.ssdo.numObs, 3), dtype = float)
self.allJBPass = UTILS.compareFloat(0.0, self.minJB, rTol = .00000001)
self.allMIPass = UTILS.compareFloat(0.0, self.minMI, rTol = .00000001)
self.miVals = []
示例3: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, weightsFile):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
self.wPath, self.wName = OS.path.split(weightsFile)
name, ext = OS.path.splitext(weightsFile.upper())
self.wExt = ext.strip(".")
self.setWeights()
示例4: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, depVarName, indVarNames, patW, useHAC = True):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Initialize Data ####
self.initialize()
#### Calculate Statistic ####
self.calculate()
示例5: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, concept = "EUCLIDEAN", studyArea = None):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Set Study Area ####
self.setStudyArea()
#### Calculate ####
self.calculate()
示例6: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdoBase, ssdoCand, fieldNames,
similarType = 'MOST_SIMILAR',
matchMethod = 'ATTRIBUTE_VALUES',
numResults = 10, appendFields = []):
UTILS.assignClassAttr(self, locals())
self.k = len(self.fieldNames)
self.validateNumResults()
self.initialize()
self.solve()
示例7: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, y, weightsMatrix, weightsType = "SWM",
silent = True):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Construct Based on SWM File or On The Fly ####
self.construct()
#### Calculate Moran's I ####
self.calculate()
示例8: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, inputFC, outputFile, kernelType, neighborNum, idField):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Set Object for Weights Creation ####
self.ssdo = None
self.weightObj = None
self.outputExt = AUTILS.returnWeightFileType(outputFile)
#### Initialize Data ####
self.initialize()
#### Build Weights ####
self.buildWeights()
示例9: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, varName, nIncrements = 10,
begDist = None, dIncrement = None,
concept = "EUCLIDEAN", rowStandard = True,
stdDeviations = 0, includeCoincident = True,
silent = False, stopMax = None):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
self.idsWarn = []
self.idsMax = []
#### Initialize Data ####
self.initialize()
#### Construct Based on SWM File or On The Fly ####
self.construct()
示例10: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, inputFC, outputFile, idField, distanceType, threshold,\
knnNum, inverseDist):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Set Object for Weights Creation ####
self.ssdo = None
self.weightObj = None
self.outputExt = AUTILS.returnWeightFileType(outputFile)
#### Initialize Data ####
self.initialize()
#### Build Weights ####
self.buildWeights()
示例11: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, depVarName, indVarNames):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
self.warnedTProb = False
#### Initialize Data ####
self.initialize()
#### Calculate Statistic ####
self.calculate()
#### Create Reports ####
self.createCoefficientReport()
self.createDiagnosticReport()
self.createInterpretReport()
示例12: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, ssdo, depVarName, indVarNames, patW, patKW,
pValue = 0.01, useCombo = False):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Initialize Data ####
self.initialize()
#### Variables for Output ####
self.oPredy = None
self.oResid = None
self.oPredy_e= None
self.oE_Predy= None
#### Calculate Statistic ####
self.calculate()
示例13: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, inputFC, outputFile, idField, weightType, weightOrder,\
isLowOrder=False):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Set Object for Weights Creation ####
self.ssdo = None
self.weightObj = None
self.polyNeighborDict = None
self.outputExt = AUTILS.returnWeightFileType(outputFile)
#### Initialize Data ####
self.initialize()
#### Build Weights ####
self.buildWeights()
示例14: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, inputFile, outputFile, inputFC, inputIDField, \
inputExt, outputExt):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Set Object for Weights Creation ####
self.ssdo = None
self.weightObj = None
self.needFCandID = False
self.fileIDField = None
#### Initialize Data ####
self.initialize()
#### Convert Weights ####
self.loadWeights()
示例15: __init__
# 需要导入模块: import SSUtilities [as 别名]
# 或者: from SSUtilities import assignClassAttr [as 别名]
def __init__(self, inputFC, outputTable = None, nIncrements = 10,
permutations = 0, weightField = None, begDist = None,
dIncrement = None, edgeCorrection = None,
studyAreaMethod = 0, studyAreaFC = None):
#### Set Initial Attributes ####
UTILS.assignClassAttr(self, locals())
#### Create a Spatial Stats Data Object (SSDO) ####
self.ssdo = SSDO.SSDataObject(inputFC, useChordal = False)
#### Must Be Projected For Now ####
if self.ssdo.spatialRefType == "GEOGRAPHIC":
ARCPY.AddIDMessage("ERROR", 1606)
raise SystemExit()
#### Edge Correction Bools ####
self.simulate = self.edgeCorrection == "Simulate"
self.ripley = self.edgeCorrection == "Ripley"
self.reduce = self.edgeCorrection == "Reduce"
self.noEdge = self.edgeCorrection == None
#### Set Seed if Env Var Given ####
if self.permutations:
UTILS.setRandomSeed()
#### Initialize Data ####
self.initialize()
#### Get Near Info and Remove Outside Points ####
self.setOriginalTable()
#### Choose Weighted or Unweighted Version ####
if self.weightField:
self.weightedCalc()
else:
self.unweightedCalc()
#### Clean Up ####
self.cleanUp()