Update sequence.R

Trying to recode a portion of the get_sequences function