genDummy function

Create dummy variables from a factor or integer variable