init
This commit is contained in:
@@ -150,6 +150,7 @@ if week in (0, 1, 2, 3, 4): # 0:월, 1:화, 2:수, 3:목, 4:금, 5:토, 6:일
|
||||
|
||||
|
||||
|
||||
|
||||
ERROR_COUNT = 0
|
||||
while ERROR_COUNT < 3:
|
||||
try:
|
||||
@@ -165,6 +166,7 @@ if week in (0, 1, 2, 3, 4): # 0:월, 1:화, 2:수, 3:목, 4:금, 5:토, 6:일
|
||||
|
||||
|
||||
|
||||
|
||||
ERROR_COUNT = 0
|
||||
while ERROR_COUNT < 3:
|
||||
try:
|
||||
@@ -180,6 +182,7 @@ if week in (0, 1, 2, 3, 4): # 0:월, 1:화, 2:수, 3:목, 4:금, 5:토, 6:일
|
||||
|
||||
|
||||
|
||||
|
||||
inFileName = PROJECT_HOME + '/resources/stock.db'
|
||||
analyzerSqlite = AnalyzerSqlite(stockFileName)
|
||||
|
||||
@@ -232,5 +235,6 @@ if week in (0, 1, 2, 3, 4): # 0:월, 1:화, 2:수, 3:목, 4:금, 5:토, 6:일
|
||||
|
||||
|
||||
|
||||
|
||||
print("time : %6.2f 초", (time.time() - start))
|
||||
print ("done...")
|
||||
|
||||
@@ -228,12 +228,20 @@ if __name__ == "__main__":
|
||||
stockFileName = os.path.join(RESOURCE_PATH, 'stock.db')
|
||||
|
||||
stockPriceDirectionAnalyzer = StockPriceDirectionAnalyzer(stockFileName)
|
||||
|
||||
"""
|
||||
corr_scores = stockPriceDirectionAnalyzer.analyze(master_code='122630')
|
||||
corr_scores_list = sorted(corr_scores.items(), key=lambda item: item[1], reverse=True)
|
||||
for item in corr_scores_list:
|
||||
if item[1] > 0.8:
|
||||
print("%s %4.3f" % (item[0], item[1]))
|
||||
"""
|
||||
|
||||
corr_scores = stockPriceDirectionAnalyzer.analyze(master_code='252670')
|
||||
corr_scores_list = sorted(corr_scores.items(), key=lambda item: item[1], reverse=True)
|
||||
for item in corr_scores_list:
|
||||
print("%s %4.3f" % (item[0], item[1]))
|
||||
|
||||
|
||||
print('done...')
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user