There is Dataframe as following:
id year month y sinx 1 2019 1 0 1 1 2019 2 0 2 1 2019 3 1 3 1 2019 4 0 4 1 2019 5 0