add library/require in r code to segplot