Added plotForWord function