Changed sample code to use tsk package