I want to use slide window to check if the word in the 'document' is matched with the word in the 'lexicon'. My question is: which main function is doing this kind of thing? I saw several sliding window example and it seems that they are not what I want.
document=['hello','my','world','love'], lexicon=['questions','hello','shift',.....]
If I use slide window with size set to 3. Does that mean I will get
('hello','my','world') and ('my','world','love')
For each, I wanna test if
'hello','my','world'
are in the lexicon separately, and then test if
'hello my','my world', 'hello world'
are in the lexicon separately, and test if
'hello my world'
is in the lexicon.