change rope sampling, more plotting code