| | |
| | | # self.filtered_stocks = [stock for stock in self.all_stocks if |
| | | # stock.startswith('SHSE.60') or (stock.startswith('SZSE.00'))] |
| | | self.filtered_stocks = [stock['symbol'] for stock in self.all_stocks if |
| | | isinstance(stock.get('symbol'), str) and ( |
| | | stock['symbol'].startswith('SHSE.60') or stock['symbol'].startswith( |
| | | 'SZSE.00'))] |
| | | isinstance(stock.get('symbol'), str) and (stock['symbol'].startswith('SHSE.60') or stock['symbol'].startswith('SZSE.00'))] |
| | | # self.filtered_stocks = self.filtered_stocks[:10] |
| | | print(f"过滤后上证A股和深证A股数量filtered_stocks:{len(self.filtered_stocks)}") |
| | | # 声明一下需要拉取K线的列表 |