add more rules to screener

This commit is contained in:
MuslemRahimi 2024-10-01 23:47:42 +02:00
parent 080aa7534d
commit 699594cb64
2 changed files with 41 additions and 1 deletions

View File

@ -354,6 +354,25 @@ data = {
'operatingCashFlowPerShare': {
'text': 'Operating Cash Flow Per Share measures the amount of cash generated from operations per share of stock. It reflects the companys ability to generate cash from its core business activities relative to the number of shares outstanding.',
},
'revenuePerShare': {
'text': 'Revenue Per Share measures the amount of revenue generated by a company per share of its stock.',
},
'netIncomePerShare': {
'text': 'Net Income Per Share shows the profit available to each outstanding share of stock, reflecting a companys profitability and earnings potential.',
},
'shareholdersEquityPerShare': {
'text': 'Shareholders Equity Per Share measures the equity available to shareholders per share, indicating the company net asset value and investment potential.',
},
'interestDebtPerShare': {
'text': 'Interest Debt Per Share measures the interest expense allocated to each share of stock, indicating the company debt burden relative to its share count.',
},
'capexPerShare': {
'text': 'CapEx Per Share measures capital expenditures allocated to each share, reflecting a company investment in growth and long-term assets relative to its share count.',
},
'grahamNumber': {
'text': 'The Graham Number is a measure of a stock maximum fair value based on its earnings and book value. An ideal Graham Number indicates the stock maximum fair value; if the current share price is below this number, it may be a good buying opportunity, while a price above suggests it might be overvalued and a candidate for selling.',
'equation': 'Graham Number = √(22.5 × Earnings Per Share × Book Value Per Share)'
},
'cashFlowToDebtRatio': {
'text': 'The Cash Flow / Debt Ratio measures a companys ability to cover its total debt with its operating cash flow. It provides insight into the companys financial health and its capacity to manage debt obligations using cash generated from operations.',
},

View File

@ -533,7 +533,28 @@ async def get_stock_screener(con):
item['institutionalOwnership'] = round(res['ownershipPercent'],2)
except Exception as e:
item['institutionalOwnership'] = None
try:
with open(f"json/financial-statements/key-metrics/annual/{symbol}.json", 'r') as file:
res = orjson.loads(file.read())[0]
item['revenuePerShare'] = round(res['revenuePerShare'],2)
item['netIncomePerShare'] = round(res['netIncomePerShare'],2)
item['shareholdersEquityPerShare'] = round(res['shareholdersEquityPerShare'],2)
item['interestDebtPerShare'] = round(res['interestDebtPerShare'],2)
item['capexPerShare'] = round(res['capexPerShare'],2)
item['tangibleAssetValue'] = round(res['tangibleAssetValue'],2)
item['returnOnTangibleAssets'] = round(res['returnOnTangibleAssets'],2)
item['grahamNumber'] = round(res['grahamNumber'],2)
except:
item['revenuePerShare'] = None
item['netIncomePerShare'] = None
item['shareholdersEquityPerShare'] = None
item['interestDebtPerShare'] = None
item['capexPerShare'] = None
item['tangibleAssetValue'] = None
item['returnOnTangibleAssets'] = None
item['grahamNumber'] = None
try:
with open(f"json/trend-analysis/{symbol}.json", 'r') as file: