Finished functions and added some example code to readme