How can I write a code that shows me the indexes of Newdate within Setups. I want to get the index value for each of the date values, so for the first output;'2017-12-22T03:31:00.000000000' date value in Newdate comes 6th from the beginning from Setups the output will be 5.How would I be able to get the Expected Output.
Code:
import numpy as np
Setups= np.array(['2017-09-15T07:11:00.000000000','2017-09-15T11:25:00.000000000',
'2017-09-15T12:11:00.000000000', '2017-12-22T03:14:00.000000000',
'2017-12-22T03:26:00.000000000', '2017-12-22T03:31:00.000000000',
'2017-12-22T03:56:00.000000000'],dtype="datetime64[ns]")
Newdate = np.array(['2017-09-15T07:11:00.000000000', '2017-12-22T03:31:00.000000000','2017-09-15T11:25:00.000000000', '2017-12-22T03:56:00.000000000'],dtype="datetime64[ns]")
Expected Output:
[0, 5, 1, 6]