Skip to content

findstr

legacy · scripts/legacy/findstr.m

: k = findstr (s1, s2)
: k = findstr (s1, s2, overlap)

Return the start positions of the shorter of the two strings inside the longer one. When both have the same length s1 is the text that is searched. The comparison is case sensitive.

With overlap true (the default) occurrences may overlap; with overlap false they may not.

This function is obsolete; use strfind instead. The first call issues warning ("nexus:deprecated:findstr", …).