Musical judgment is essential when selecting a substitution for a particular musical setting.
When playing the melody make sure that a chord substitution does not clash with the melody notes.
With improvisations you have more freedom with substitutions, but include appropriate scales in your scale progression for improvisation. You can also use certain substitutions in one chorus, and others (or none) in the next.