Skip to content

Commit b4d13ea

Browse files
committed
Started work on valuation.py file
1 parent 734935e commit b4d13ea

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import asyncio
2+
import polars as pl
3+
from stock_valuation_app.data.fmp_client import FMPClient
4+
5+
6+
7+
async def extract_source_data(ticker: str):
8+
source_data = await FMPClient().fetch_data(ticker)
9+
return source_data
10+
11+
if __name__ == "__main__":
12+
raw_data = asyncio.run(extract_source_data('PAYS'))
13+
14+
profile_df = pl.DataFrame(raw_data["profile"])
15+
rating_df = pl.DataFrame(raw_data["rating"])
16+
metric_df = pl.DataFrame(raw_data["key_metrics"])
17+
growth_df = pl.DataFrame(raw_data["growth"])
18+
19+
print(profile_df.head())
20+
print(rating_df.head())
21+
print(metric_df.head())
22+
print(growth_df.head())

0 commit comments

Comments
 (0)