I see, I would go about this as follows: if you have your data in the IDTxl data object, you can retrieve the realisations for variables with specific lags via the get_realisations() function (see also the
docs).
s = 0 # to make up a source and target index in your data
t = 1
lag = 2 # took this from your analysis setup
current_value = (t, lag) # this is the absolute index of the first entry in the target time series that we can use as a realisation/sample for estimation, while allowing to also look at source time series with the desired lag
ind_source_past = [(s, 0)] # list of variables, where each variable is a tuple (<source index>, <sample index>), here the time/sample index is current_value[1] - lag
ind_target_past = [(t, 1)] # assuming, the relevant target past has a lag of 1
source_realisations = data.get_realisations(current_value, ind_source_past)[0]
target_realisations = data.get_realisations(current_value, [current_value])[0]
conditional_realisations = data.get_realisations(current_value, ind_target_past)[0]
est = JidtKraskovCMI()
cmi = est.estimate(source_realisations, target_realisations, conditional_realisations)
print(cmi)
Of course, you can make this a conditional TE by adding further source variables to the list when retrieving the
conditional_realisation. Also, if your target past state comprises more past variables, you can add those there. Also, if your source past state consists of multiple past variables, you may extend the list of indices when creating
source_realisations.