0

Python Futurewarning: How would i reconoiter this to get rid of futurewarning??

for symbol in symbol_string.split(','):
    hqm_dataframe = hqm_dataframe.append(
                                    pd.Series([symbol,
                                               data[symbol]['quote']['latestPrice'],
                                               'N/A',
                                               data[symbol]['stats']['year1ChangePercent'],
                                               'N/A',
                                               data[symbol]['stats']['month6ChangePercent'],
                                               'N/A',
                                               data[symbol]['stats']['month3ChangePercent'],
                                               'N/A',
                                               data[symbol]['stats']['month1ChangePercent'],
                                               'N/A',
                                               'N/A'
                                               ],
                                              index = hqm_columns),
                                    ignore_index = True)

C:\Users\actor\PycharmProjects\pythonProject\momentum strategy.py:60: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead. hqm_dataframe = hqm_dataframe.append(

actorcat
  • 1
  • 2
  • 2
    to remove the warnings, you can use `import warnings warnings.filterwarnings('ignore')` but I would suggest you to use pd.concat in stead – Himanshu Poddar Jul 30 '22 at 18:26
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Jul 30 '22 at 23:18

0 Answers0