myview, altered code + cleaned up some code, also related to #218

myview, altered code + cleaned up some code, also related to #218