I have 2 series with different indexes but the same length of 638.
series fc
's output is
1888 4.899912
1889 4.900162
1890 4.900141
1891 4.900142
1892 4.900142
...
2521 4.900142
2522 4.900142
2523 4.900142
2524 4.900142
2525 4.900142
Name: predicted_mean, Length: 638, dtype: float64
and series fc_series
's output is
Date
2020-12-16 NaN
2020-12-17 NaN
2020-12-18 NaN
2020-12-21 NaN
2020-12-22 NaN
..
2023-06-26 NaN
2023-06-27 NaN
2023-06-28 NaN
2023-06-29 NaN
2023-06-30 NaN
Name: predicted_mean, Length: 638, dtype: float64
I tried using this code line
fc_series = pd.Series(fc, index=test_data.index)
I want fc
's values in place of the NaN values in fc_series
. I am struggling with the indexing part of this and would really appreciate the help.