Skip to content

Commit

Permalink
FIx for GetAllVintageSeriesResult.to_pd_data_frame (#67)
Browse files Browse the repository at this point in the history
  • Loading branch information
mb-jp authored Aug 16, 2024
1 parent bde34f6 commit 9c2ae57
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from dataclasses import dataclass
from itertools import chain

from typing import TYPE_CHECKING, Any, Dict, Sequence, overload, List

Expand Down Expand Up @@ -36,9 +37,12 @@ def to_pd_data_frame(self) -> "DataFrame":
"""
import pandas # pylint: disable=import-outside-toplevel

dates = list(set(chain.from_iterable((x.dates for x in self.series))))
dates.sort()

df = pandas.DataFrame(
{
**{"date": self.series[len(self.series) - 1].dates},
**{"date": dates},
}
)

Expand Down

0 comments on commit 9c2ae57

Please sign in to comment.