コード例 #1
0
ファイル: LPClasses.py プロジェクト: Slacanch/EVE_industry
    def calcVolumeRatio(self):
        """"""
        returnDict = {}
        BPOList = open("allBPOs.txt")
        for i in BPOList:
            i = i.strip()
            CopySize, manufSize, minMarketSize = StaticData.marketSize(
                StaticData.idName(i))

            a = self.esi.getMarketHistory(
                StaticData.productID(StaticData.idName(i)))
            daysPerManuf = manufSize / a.medianVolume(90)

            returnDict[StaticData.idName(i)] = 10 / daysPerManuf  #/

        return returnDict
コード例 #2
0
ファイル: LPClasses.py プロジェクト: Slacanch/EVE_industry
    def calculate(self):
        """"""
        totMats = {}
        ratios = self.calcVolumeRatio()
        BPOList = open("allBPOs.txt")

        for i in BPOList:
            i = i.strip()
            CopySize, manufSize, minMarketSize = StaticData.marketSize(
                StaticData.idName(i))
            a = StaticData.baseManufacturingCost(StaticData.idName(i))

            for mat in a:
                if mat in totMats:
                    totMats[mat] += a[mat] * manufSize * ratios[
                        StaticData.idName(i)]
                else:
                    totMats[mat] = a[mat] * manufSize * ratios[
                        StaticData.idName(i)]

        return totMats